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

Side by Side Diff: src/core/SkBlitter.h

Issue 246403013: Revert of Revert of Extract most of the mutable state of SkShader into a separate Context object. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 8 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 | « src/core/SkBitmapProcState.cpp ('k') | src/core/SkBlitter.cpp » ('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 SkBlitter_DEFINED 10 #ifndef SkBlitter_DEFINED
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 */ 54 */
55 virtual const SkBitmap* justAnOpaqueColor(uint32_t* value); 55 virtual const SkBitmap* justAnOpaqueColor(uint32_t* value);
56 56
57 /** 57 /**
58 * Special method just to identify the null blitter, which is returned 58 * Special method just to identify the null blitter, which is returned
59 * from Choose() if the request cannot be fulfilled. Default impl 59 * from Choose() if the request cannot be fulfilled. Default impl
60 * returns false. 60 * returns false.
61 */ 61 */
62 virtual bool isNullBlitter() const; 62 virtual bool isNullBlitter() const;
63 63
64 /**
65 * Special methods for SkShaderBlitter. On all other classes this is a no-o p.
66 */
67 virtual bool resetShaderContext(const SkBitmap& device, const SkPaint& paint ,
68 const SkMatrix& matrix);
69 virtual SkShader::Context* getShaderContext() const;
70
64 ///@name non-virtual helpers 71 ///@name non-virtual helpers
65 void blitMaskRegion(const SkMask& mask, const SkRegion& clip); 72 void blitMaskRegion(const SkMask& mask, const SkRegion& clip);
66 void blitRectRegion(const SkIRect& rect, const SkRegion& clip); 73 void blitRectRegion(const SkIRect& rect, const SkRegion& clip);
67 void blitRegion(const SkRegion& clip); 74 void blitRegion(const SkRegion& clip);
68 ///@} 75 ///@}
69 76
70 /** @name Factories 77 /** @name Factories
71 Return the correct blitter to use given the specified context. 78 Return the correct blitter to use given the specified context.
72 */ 79 */
73 static SkBlitter* Choose(const SkBitmap& device, 80 static SkBlitter* Choose(const SkBitmap& device,
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 SkBlitter* apply(SkBlitter* blitter, const SkRegion* clip, 170 SkBlitter* apply(SkBlitter* blitter, const SkRegion* clip,
164 const SkIRect* bounds = NULL); 171 const SkIRect* bounds = NULL);
165 172
166 private: 173 private:
167 SkNullBlitter fNullBlitter; 174 SkNullBlitter fNullBlitter;
168 SkRectClipBlitter fRectBlitter; 175 SkRectClipBlitter fRectBlitter;
169 SkRgnClipBlitter fRgnBlitter; 176 SkRgnClipBlitter fRgnBlitter;
170 }; 177 };
171 178
172 #endif 179 #endif
OLDNEW
« no previous file with comments | « src/core/SkBitmapProcState.cpp ('k') | src/core/SkBlitter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698