diff options
author | Mike Reed <reed@google.com> | 2017-07-21 14:24:29 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-07-21 18:49:05 +0000 |
commit | f19421961c59ceabfb88a5c5cdf7c7e31a95b015 (patch) | |
tree | 5908b47d389465242a24c1439c115db57295f883 /tests/ImageNewShaderTest.cpp | |
parent | ce98801bbb5ac251b374f8b565445add43017aaa (diff) |
don't rely on canvas->readPixels
Bug: skia:3216
Change-Id: I01a8d0083c79c0fe71fbc4d8cfdde4fa6e48b636
Reviewed-on: https://skia-review.googlesource.com/25741
Commit-Queue: Mike Reed <reed@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Diffstat (limited to 'tests/ImageNewShaderTest.cpp')
-rw-r--r-- | tests/ImageNewShaderTest.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/ImageNewShaderTest.cpp b/tests/ImageNewShaderTest.cpp index fe01f04c94..638fa078f0 100644 --- a/tests/ImageNewShaderTest.cpp +++ b/tests/ImageNewShaderTest.cpp @@ -56,12 +56,12 @@ static void run_shader_test(skiatest::Reporter* reporter, SkSurface* sourceSurfa SkBitmap bmOrig; bmOrig.allocN32Pixels(info.width(), info.height()); - sourceSurface->getCanvas()->readPixels(bmOrig, 0, 0); + sourceSurface->readPixels(bmOrig, 0, 0); SkBitmap bm; bm.allocN32Pixels(info.width(), info.height()); - destinationCanvas->readPixels(bm, 0, 0); + destinationSurface->readPixels(bm, 0, 0); test_bitmap_equality(reporter, bmOrig, bm); @@ -83,7 +83,7 @@ static void run_shader_test(skiatest::Reporter* reporter, SkSurface* sourceSurfa SkBitmap bmt; bmt.allocN32Pixels(info.width(), info.height()); - destinationCanvas->readPixels(bmt, 0, 0); + destinationSurface->readPixels(bmt, 0, 0); // Test correctness { |