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

Unified Diff: include/core/SkBitmapDevice.h

Issue 926843003: Move canvas->surface association to the device subclasses (Closed) Base URL: https://skia.googlesource.com/skia.git@skimage-filters-03-sksurface-set-root-device-simple
Patch Set: Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | include/core/SkCanvas.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkBitmapDevice.h
diff --git a/include/core/SkBitmapDevice.h b/include/core/SkBitmapDevice.h
index a801420584a0f50d263dfa99ce5662ea53753ced..3593699a476199372e84fa4d2d5c914cc556fb3d 100644
--- a/include/core/SkBitmapDevice.h
+++ b/include/core/SkBitmapDevice.h
@@ -133,6 +133,11 @@ protected:
void lockPixels() SK_OVERRIDE;
void unlockPixels() SK_OVERRIDE;
+
+ /** Creates a backend bitmap for a new bitmap device.
+ * returns true on success, with compatible bitmap in \target.
+ */
+ static bool CreateBackendBitmap(const SkImageInfo& origInfo, SkBitmap* target);
private:
friend class SkCanvas;
friend struct DeviceCM; //for setMatrixClip
@@ -142,11 +147,12 @@ private:
friend class SkDeviceImageFilterProxy;
friend class SkSurface_Raster;
+ friend class SkRasterDevice;
// used to change the backend's pixels (and possibly config/rowbytes)
// but cannot change the width/height, so there should be no change to
// any clip information.
- void replaceBitmapBackendForRasterSurface(const SkBitmap&) SK_OVERRIDE;
+ void replaceBitmapBackend(const SkBitmap&) SK_OVERRIDE;
SkBaseDevice* onCreateCompatibleDevice(const CreateInfo&) SK_OVERRIDE;
« no previous file with comments | « no previous file | include/core/SkCanvas.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698