| OLD | NEW |
| 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 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 | 56 |
| 57 ~SkGpuDevice() override {} | 57 ~SkGpuDevice() override {} |
| 58 | 58 |
| 59 SkGpuDevice* cloneDevice(const SkSurfaceProps& props) { | 59 SkGpuDevice* cloneDevice(const SkSurfaceProps& props) { |
| 60 SkBaseDevice* dev = this->onCreateDevice(CreateInfo(this->imageInfo(), k
Possible_TileUsage, | 60 SkBaseDevice* dev = this->onCreateDevice(CreateInfo(this->imageInfo(), k
Possible_TileUsage, |
| 61 props.pixelGeometry(
)), | 61 props.pixelGeometry(
)), |
| 62 nullptr); | 62 nullptr); |
| 63 return static_cast<SkGpuDevice*>(dev); | 63 return static_cast<SkGpuDevice*>(dev); |
| 64 } | 64 } |
| 65 | 65 |
| 66 GrContext* context() const { return fContext; } | 66 GrContext* context() const override { return fContext; } |
| 67 | 67 |
| 68 // set all pixels to 0 | 68 // set all pixels to 0 |
| 69 void clearAll(); | 69 void clearAll(); |
| 70 | 70 |
| 71 void replaceRenderTarget(bool shouldRetainContent); | 71 void replaceRenderTarget(bool shouldRetainContent); |
| 72 | 72 |
| 73 GrRenderTarget* accessRenderTarget() override; | 73 GrRenderTarget* accessRenderTarget() override; |
| 74 | 74 |
| 75 SkImageInfo imageInfo() const override { | 75 SkImageInfo imageInfo() const override { |
| 76 return fLegacyBitmap.info(); | 76 return fLegacyBitmap.info(); |
| (...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 251 | 251 |
| 252 void drawSpriteWithFilter(const SkDraw&, const SkBitmap&, int x, int y, | 252 void drawSpriteWithFilter(const SkDraw&, const SkBitmap&, int x, int y, |
| 253 const SkPaint&) override; | 253 const SkPaint&) override; |
| 254 | 254 |
| 255 friend class GrAtlasTextContext; | 255 friend class GrAtlasTextContext; |
| 256 friend class SkSurface_Gpu; // for access to surfaceProps | 256 friend class SkSurface_Gpu; // for access to surfaceProps |
| 257 typedef SkBaseDevice INHERITED; | 257 typedef SkBaseDevice INHERITED; |
| 258 }; | 258 }; |
| 259 | 259 |
| 260 #endif | 260 #endif |
| OLD | NEW |