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

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

Issue 2161233002: pre-land special methods on device (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 5 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 | « no previous file | include/core/SkDevice.h » ('j') | src/pdf/SkPDFDevice.cpp » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2013 Google Inc. 3 * Copyright 2013 Google Inc.
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 #ifndef SkBitmapDevice_DEFINED 9 #ifndef SkBitmapDevice_DEFINED
10 #define SkBitmapDevice_DEFINED 10 #define SkBitmapDevice_DEFINED
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 const SkScalar pos[], int scalarsPerPos, 115 const SkScalar pos[], int scalarsPerPos,
116 const SkPoint& offset, const SkPaint& paint) overri de; 116 const SkPoint& offset, const SkPaint& paint) overri de;
117 virtual void drawVertices(const SkDraw&, SkCanvas::VertexMode, int vertexCou nt, 117 virtual void drawVertices(const SkDraw&, SkCanvas::VertexMode, int vertexCou nt,
118 const SkPoint verts[], const SkPoint texs[], 118 const SkPoint verts[], const SkPoint texs[],
119 const SkColor colors[], SkXfermode* xmode, 119 const SkColor colors[], SkXfermode* xmode,
120 const uint16_t indices[], int indexCount, 120 const uint16_t indices[], int indexCount,
121 const SkPaint& paint) override; 121 const SkPaint& paint) override;
122 virtual void drawDevice(const SkDraw&, SkBaseDevice*, int x, int y, const Sk Paint&) override; 122 virtual void drawDevice(const SkDraw&, SkBaseDevice*, int x, int y, const Sk Paint&) override;
123 123
124 /////////////////////////////////////////////////////////////////////////// 124 ///////////////////////////////////////////////////////////////////////////
125
126 void drawSpecial(const SkDraw&, SkSpecialImage*, int x, int y, const SkPaint &) override;
127 sk_sp<SkSpecialImage> makeSpecial(const SkBitmap&) override;
128 sk_sp<SkSpecialImage> makeSpecial(const SkImage*) override;
129 sk_sp<SkSpecialImage> snapSpecial() override;
130
131 ///////////////////////////////////////////////////////////////////////////
125 132
126 /** Update as needed the pixel value in the bitmap, so that the caller can 133 /** Update as needed the pixel value in the bitmap, so that the caller can
127 access the pixels directly. Note: only the pixels field should be 134 access the pixels directly. Note: only the pixels field should be
128 altered. The config/width/height/rowbytes must remain unchanged. 135 altered. The config/width/height/rowbytes must remain unchanged.
129 @return the device contents as a bitmap 136 @return the device contents as a bitmap
130 */ 137 */
131 const SkBitmap& onAccessBitmap() override; 138 const SkBitmap& onAccessBitmap() override;
132 139
133 SkPixelRef* getPixelRef() const { return fBitmap.pixelRef(); } 140 SkPixelRef* getPixelRef() const { return fBitmap.pixelRef(); }
134 // just for subclasses, to assign a custom pixelref 141 // just for subclasses, to assign a custom pixelref
(...skipping 30 matching lines...) Expand all
165 SkImageFilterCache* getImageFilterCache() override; 172 SkImageFilterCache* getImageFilterCache() override;
166 173
167 SkBitmap fBitmap; 174 SkBitmap fBitmap;
168 175
169 void setNewSize(const SkISize&); // Used by SkCanvas for resetForNextPictur e(). 176 void setNewSize(const SkISize&); // Used by SkCanvas for resetForNextPictur e().
170 177
171 typedef SkBaseDevice INHERITED; 178 typedef SkBaseDevice INHERITED;
172 }; 179 };
173 180
174 #endif // SkBitmapDevice_DEFINED 181 #endif // SkBitmapDevice_DEFINED
OLDNEW
« no previous file with comments | « no previous file | include/core/SkDevice.h » ('j') | src/pdf/SkPDFDevice.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698