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

Unified Diff: cc/resources/bitmap_content_layer_updater.cc

Issue 146103003: Merge 236625 "Use SkBitmap backing instead of GDI backed platfor..." (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1700/src/
Patch Set: Created 6 years, 11 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 | « cc/resources/bitmap_content_layer_updater.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resources/bitmap_content_layer_updater.cc
===================================================================
--- cc/resources/bitmap_content_layer_updater.cc (revision 246699)
+++ cc/resources/bitmap_content_layer_updater.cc (working copy)
@@ -65,8 +65,12 @@
devtools_instrumentation::ScopedLayerTask paint_setup(
devtools_instrumentation::kPaintSetup, layer_id_);
canvas_size_ = content_rect.size();
- canvas_ = skia::AdoptRef(skia::CreateBitmapCanvas(
- canvas_size_.width(), canvas_size_.height(), layer_is_opaque_));
+ bitmap_backing_.setConfig(
+ SkBitmap::kARGB_8888_Config,
+ canvas_size_.width(), canvas_size_.height(),
+ 0, layer_is_opaque_ ? kOpaque_SkAlphaType : kPremul_SkAlphaType);
+ bitmap_backing_.allocPixels();
+ canvas_ = skia::AdoptRef(new SkCanvas(bitmap_backing_));
}
base::TimeTicks start_time =
« no previous file with comments | « cc/resources/bitmap_content_layer_updater.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698