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

Side by Side Diff: src/gpu/SkGpuDevice.h

Issue 2309483002: WIP RasterCanvasLayerAllocator experiment 2
Patch Set: vend smart pointers to SkCanvas Created 4 years, 2 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/SkRasterCanvasLayerAllocator.cpp ('k') | src/gpu/SkGpuDevice.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 * Copyright 2010 Google Inc. 2 * Copyright 2010 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef SkGpuDevice_DEFINED 8 #ifndef SkGpuDevice_DEFINED
9 #define SkGpuDevice_DEFINED 9 #define SkGpuDevice_DEFINED
10 10
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
143 enum Flags { 143 enum Flags {
144 kNeedClear_Flag = 1 << 0, //!< Surface requires an initial clear 144 kNeedClear_Flag = 1 << 0, //!< Surface requires an initial clear
145 kIsOpaque_Flag = 1 << 1, //!< Hint from client that rendering to this device will be 145 kIsOpaque_Flag = 1 << 1, //!< Hint from client that rendering to this device will be
146 // opaque even if the config supports alpha . 146 // opaque even if the config supports alpha .
147 }; 147 };
148 static bool CheckAlphaTypeAndGetFlags(const SkImageInfo* info, InitContents init, 148 static bool CheckAlphaTypeAndGetFlags(const SkImageInfo* info, InitContents init,
149 unsigned* flags); 149 unsigned* flags);
150 150
151 SkGpuDevice(sk_sp<GrDrawContext>, int width, int height, unsigned flags); 151 SkGpuDevice(sk_sp<GrDrawContext>, int width, int height, unsigned flags);
152 152
153 SkBaseDevice* onCreateDevice(const CreateInfo&, const SkPaint*) override; 153 SkBaseDevice* onCreateDevice(const CreateInfo&, const SkPaint*,
154 SkRasterCanvasLayerAllocator*) override;
154 155
155 sk_sp<SkSurface> makeSurface(const SkImageInfo&, const SkSurfaceProps&) over ride; 156 sk_sp<SkSurface> makeSurface(const SkImageInfo&, const SkSurfaceProps&) over ride;
156 157
157 SkImageFilterCache* getImageFilterCache() override; 158 SkImageFilterCache* getImageFilterCache() override;
158 159
159 bool forceConservativeRasterClip() const override { return true; } 160 bool forceConservativeRasterClip() const override { return true; }
160 161
161 // sets the render target and clip on context 162 // sets the render target and clip on context
162 void prepareDraw(const SkDraw&); 163 void prepareDraw(const SkDraw&);
163 164
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 int sampleCount, 246 int sampleCount,
246 GrSurfaceOrigin, 247 GrSurfaceOrigin,
247 const SkSurfaceProps*); 248 const SkSurfaceProps*);
248 249
249 friend class GrAtlasTextContext; 250 friend class GrAtlasTextContext;
250 friend class SkSurface_Gpu; // for access to surfaceProps 251 friend class SkSurface_Gpu; // for access to surfaceProps
251 typedef SkBaseDevice INHERITED; 252 typedef SkBaseDevice INHERITED;
252 }; 253 };
253 254
254 #endif 255 #endif
OLDNEW
« no previous file with comments | « src/core/SkRasterCanvasLayerAllocator.cpp ('k') | src/gpu/SkGpuDevice.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698