diff options
author | mike@reedtribe.org <mike@reedtribe.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2014-02-13 14:41:43 +0000 |
---|---|---|
committer | mike@reedtribe.org <mike@reedtribe.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2014-02-13 14:41:43 +0000 |
commit | deee496cd30070e52556dcb538c2e5eb39b66b81 (patch) | |
tree | 80f0326a191c966bc34057e4011bdb3233bc2a50 /tests/PathUtilsTest.cpp | |
parent | b720ffd20829953c9595980422969520f5e33c76 (diff) |
replace setConfig+allocPixels with single call
BUG=skia:
Review URL: https://codereview.chromium.org/162643002
git-svn-id: http://skia.googlecode.com/svn/trunk@13426 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'tests/PathUtilsTest.cpp')
-rw-r--r-- | tests/PathUtilsTest.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/tests/PathUtilsTest.cpp b/tests/PathUtilsTest.cpp index 872af0b363..4dfeda467c 100644 --- a/tests/PathUtilsTest.cpp +++ b/tests/PathUtilsTest.cpp @@ -60,8 +60,7 @@ static void print_bmp( SkBitmap* bmp, int w, int h){ static void binary_to_skbitmap(const char* bin_bmp, SkBitmap* sk_bmp, int w, int h, int rowBytes){ //init the SkBitmap - sk_bmp->setConfig(SkBitmap::kARGB_8888_Config, w, h); - sk_bmp->allocPixels(); + sk_bmp->allocN32Pixels(w, h); for (int y = 0; y < h; ++y) { // for every row @@ -98,8 +97,7 @@ static void test_path_eq(skiatest::Reporter* reporter, const SkPath* path, // make bmp SkBitmap bmp; - bmp.setConfig(SkBitmap::kARGB_8888_Config, w, h); - bmp.allocPixels(); + bmp.allocN32Pixels(w, h); SkCanvas canvas(bmp); canvas.clear(SK_ColorWHITE); canvas.drawPath(*path, bmpPaint); |