From 4edb5d219eb99aa1e8fbe5e37260d3b34314e54b Mon Sep 17 00:00:00 2001 From: Mike Reed Date: Mon, 17 Apr 2017 11:02:51 -0400 Subject: hide lockpixels api behind flag guarded by SK_SUPPORT_OBSOLETE_LOCKPIXELS needs https://codereview.chromium.org/2820873002/# to land first Bug: skia:6481 Change-Id: I1c39902cbf6fe99f622adfa8192733b95f7fea09 Change-Id: I1c39902cbf6fe99f622adfa8192733b95f7fea09 Reviewed-on: https://skia-review.googlesource.com/13580 Reviewed-by: Florin Malita Reviewed-by: Leon Scroggins Commit-Queue: Mike Reed --- tools/picture_utils.cpp | 3 --- 1 file changed, 3 deletions(-) (limited to 'tools/picture_utils.cpp') diff --git a/tools/picture_utils.cpp b/tools/picture_utils.cpp index b0fd224a94..27e91ccdeb 100644 --- a/tools/picture_utils.cpp +++ b/tools/picture_utils.cpp @@ -26,7 +26,6 @@ namespace sk_tools { return; } - SkAutoLockPixels lock(bitmap); for (int y = 0; y < bitmap.height(); y++) { for (int x = 0; x < bitmap.width(); x++) { *bitmap.getAddr32(x, y) |= (SK_A32_MASK << SK_A32_SHIFT); @@ -87,7 +86,6 @@ namespace sk_tools { bitmap.colorSpace() == srgbColorSpace.get()) { // These are premul sRGB 8-bit pixels in SkPMColor order. // We want unpremul sRGB 8-bit pixels in RGBA order. We'll get there via floats. - bitmap.lockPixels(); auto px = (const uint32_t*)bitmap.getPixels(); if (!px) { return nullptr; @@ -105,7 +103,6 @@ namespace sk_tools { } else if (bitmap.colorType() == kRGBA_F16_SkColorType) { // These are premul linear half-float pixels in RGBA order. // We want unpremul sRGB 8-bit pixels in RGBA order. We'll get there via floats. - bitmap.lockPixels(); auto px = (const uint64_t*)bitmap.getPixels(); if (!px) { return nullptr; -- cgit v1.2.3