Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(323)

Side by Side Diff: include/core/SkMaskFilter.h

Issue 395603002: Simplify flattening to just write enough to call the factory (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « include/core/SkImageFilter.h ('k') | include/core/SkPathEffect.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2006 The Android Open Source Project 3 * Copyright 2006 The Android Open Source Project
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 9
10 #ifndef SkMaskFilter_DEFINED 10 #ifndef SkMaskFilter_DEFINED
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 * provided BlurRec parameter. If this effect cannot be represented as a Bl urRec, return false 148 * provided BlurRec parameter. If this effect cannot be represented as a Bl urRec, return false
149 * and ignore the BlurRec parameter. 149 * and ignore the BlurRec parameter.
150 */ 150 */
151 virtual bool asABlur(BlurRec*) const; 151 virtual bool asABlur(BlurRec*) const;
152 152
153 SK_TO_STRING_PUREVIRT() 153 SK_TO_STRING_PUREVIRT()
154 SK_DEFINE_FLATTENABLE_TYPE(SkMaskFilter) 154 SK_DEFINE_FLATTENABLE_TYPE(SkMaskFilter)
155 155
156 protected: 156 protected:
157 SkMaskFilter() {} 157 SkMaskFilter() {}
158 #ifdef SK_SUPPORT_LEGACY_DEEPFLATTENING
158 // empty for now, but lets get our subclass to remember to init us for the f uture 159 // empty for now, but lets get our subclass to remember to init us for the f uture
159 SkMaskFilter(SkReadBuffer& buffer) : INHERITED(buffer) {} 160 SkMaskFilter(SkReadBuffer& buffer) : INHERITED(buffer) {}
161 #endif
160 162
161 enum FilterReturn { 163 enum FilterReturn {
162 kFalse_FilterReturn, 164 kFalse_FilterReturn,
163 kTrue_FilterReturn, 165 kTrue_FilterReturn,
164 kUnimplemented_FilterReturn 166 kUnimplemented_FilterReturn
165 }; 167 };
166 168
167 struct NinePatch { 169 struct NinePatch {
168 SkMask fMask; // fBounds must have [0,0] in its top-left 170 SkMask fMask; // fBounds must have [0,0] in its top-left
169 SkIRect fOuterRect; // width/height must be >= fMask.fBounds' 171 SkIRect fOuterRect; // width/height must be >= fMask.fBounds'
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 mask and then call filterMask(). If this returns true, the specified blitte r will be called 213 mask and then call filterMask(). If this returns true, the specified blitte r will be called
212 to render that mask. Returns false if filterMask() returned false. 214 to render that mask. Returns false if filterMask() returned false.
213 */ 215 */
214 bool filterRRect(const SkRRect& devRRect, const SkMatrix& ctm, const SkRaste rClip&, 216 bool filterRRect(const SkRRect& devRRect, const SkMatrix& ctm, const SkRaste rClip&,
215 SkBlitter*, SkPaint::Style style) const; 217 SkBlitter*, SkPaint::Style style) const;
216 218
217 typedef SkFlattenable INHERITED; 219 typedef SkFlattenable INHERITED;
218 }; 220 };
219 221
220 #endif 222 #endif
OLDNEW
« no previous file with comments | « include/core/SkImageFilter.h ('k') | include/core/SkPathEffect.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698