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

Unified Diff: samplecode/SampleWritePixels.cpp

Issue 169063002: use SkColorType instead of SkBitmap::Config in samplecode (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 6 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 | « samplecode/SampleVertices.cpp ('k') | samplecode/SampleXfermodesBlur.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samplecode/SampleWritePixels.cpp
diff --git a/samplecode/SampleWritePixels.cpp b/samplecode/SampleWritePixels.cpp
index 04f34840e1821be5a510a230993789bbfb95d438..f7829eaada5bdd17745ab87238a68d470daf1954 100644
--- a/samplecode/SampleWritePixels.cpp
+++ b/samplecode/SampleWritePixels.cpp
@@ -19,8 +19,7 @@
static void create_bitmap(SkBitmap* bitmap) {
const int W = 100;
const int H = 100;
- bitmap->setConfig(SkBitmap::kARGB_8888_Config, W, H);
- bitmap->allocPixels();
+ bitmap->allocN32Pixels(W, H);
SkCanvas canvas(*bitmap);
canvas.drawColor(SK_ColorRED);
« no previous file with comments | « samplecode/SampleVertices.cpp ('k') | samplecode/SampleXfermodesBlur.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698