Index: gm/bitmapshader.cpp |
diff --git a/gm/bitmapshader.cpp b/gm/bitmapshader.cpp |
index 4fd68ee77f5ab4690f4507cbfe7f9d41a6628c54..d1915c9c90632dabf31671cd92f35b3dff33d5bb 100644 |
--- a/gm/bitmapshader.cpp |
+++ b/gm/bitmapshader.cpp |
@@ -17,8 +17,7 @@ static void draw_bm(SkBitmap* bm) { |
SkPaint bluePaint; |
bluePaint.setColor(SK_ColorBLUE); |
- bm->setConfig(SkBitmap::kARGB_8888_Config, 20, 20); |
- bm->allocPixels(); |
+ bm->allocN32Pixels(20, 20); |
bm->eraseColor(SK_ColorRED); |
SkCanvas canvas(*bm); |
@@ -29,8 +28,7 @@ static void draw_mask(SkBitmap* bm) { |
SkPaint circlePaint; |
circlePaint.setColor(SK_ColorBLACK); |
- bm->setConfig(SkBitmap::kA8_Config, 20, 20); |
- bm->allocPixels(); |
+ bm->allocConfigPixels(SkBitmap::kA8_Config, 20, 20); |
bm->eraseColor(SK_ColorTRANSPARENT); |
SkCanvas canvas(*bm); |