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

Unified Diff: src/core/SkBitmapDevice.cpp

Issue 143073008: add installPixels (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: rebase 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 | « src/core/SkBitmap.cpp ('k') | src/core/SkDevice.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkBitmapDevice.cpp
diff --git a/src/core/SkBitmapDevice.cpp b/src/core/SkBitmapDevice.cpp
index 0570fd9afdec7cf2890aae728f9c28fcac192aaa..4b4f45317f5ee78d68cfde34f88273184b6144a5 100644
--- a/src/core/SkBitmapDevice.cpp
+++ b/src/core/SkBitmapDevice.cpp
@@ -164,10 +164,8 @@ void SkBitmapDevice::writePixels(const SkBitmap& bitmap,
drawSprite = false;
} else {
// we convert to a temporary bitmap and draw that as a sprite
- dstBmp.setConfig(SkBitmap::kARGB_8888_Config,
- spriteRect.width(),
- spriteRect.height());
- if (!dstBmp.allocPixels()) {
+ if (!dstBmp.allocPixels(SkImageInfo::MakeN32Premul(spriteRect.width(),
+ spriteRect.height()))) {
return;
}
drawSprite = true;
« no previous file with comments | « src/core/SkBitmap.cpp ('k') | src/core/SkDevice.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698