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

Unified Diff: skia/ext/platform_canvas.h

Issue 6783023: Eliminate skia::PlatformCanvas - Step 1 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/renderer/webplugin_delegate_proxy.cc ('k') | skia/ext/platform_canvas.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: skia/ext/platform_canvas.h
===================================================================
--- skia/ext/platform_canvas.h (revision 80714)
+++ skia/ext/platform_canvas.h (working copy)
@@ -114,6 +114,23 @@
PlatformCanvas& operator=(const PlatformCanvas&);
};
+// Creates a canvas with raster bitmap backing.
+// Set is_opaque if you are going to erase the bitmap and not use
+// transparency: this will enable some optimizations.
+SK_API SkCanvas* CreateBitmapCanvas(int width, int height, bool is_opaque);
gwright 2011/04/07 15:28:12 Do we want an is_offscreen parameter here as well?
alokp 2011/04/07 15:57:36 May be. The one I am replacing in webkit does not
+
+// These calls should surround calls to platform drawing routines, the
+// surface returned here can be used with the native platform routines.
+//
+// Call EndPlatformPaint when you are done and want to use skia operations
+// after calling the platform-specific BeginPlatformPaint; this will
+// synchronize the bitmap to OS if necessary.
+//
+// Note: These functions will eventually replace
+// PlatformCanvas::beginPlatformPaint and PlatformCanvas::endPlatformPaint.
+SK_API PlatformDevice::PlatformSurface BeginPlatformPaint(SkCanvas* canvas);
+SK_API void EndPlatformPaint(SkCanvas* canvas);
+
} // namespace skia
#endif // SKIA_EXT_PLATFORM_CANVAS_H_
« no previous file with comments | « content/renderer/webplugin_delegate_proxy.cc ('k') | skia/ext/platform_canvas.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698