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

Unified Diff: tests/DeferredCanvasTest.cpp

Issue 25275004: store SkAlphaType inside SkBitmap, on road to support unpremul (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 years, 2 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
Index: tests/DeferredCanvasTest.cpp
diff --git a/tests/DeferredCanvasTest.cpp b/tests/DeferredCanvasTest.cpp
index e8075bd68fb10daf9f2ac6ed1fbcf0563284079e..537a810aa9175ef478053ef700303bca5f029805 100644
--- a/tests/DeferredCanvasTest.cpp
+++ b/tests/DeferredCanvasTest.cpp
@@ -333,7 +333,7 @@ static void TestDeferredCanvasFreshFrame(skiatest::Reporter* reporter) {
paint.setStyle(SkPaint::kFill_Style);
SkBitmap bmp;
create(&bmp, SkBitmap::kARGB_8888_Config, 0xFFFFFFFF);
- bmp.setIsOpaque(true);
+ bmp.setAlphaType(kOpaque_SkAlphaType);
SkShader* shader = SkShader::CreateBitmapShader(bmp,
SkShader::kClamp_TileMode, SkShader::kClamp_TileMode);
paint.setShader(shader)->unref();
@@ -371,7 +371,7 @@ static void TestDeferredCanvasFreshFrame(skiatest::Reporter* reporter) {
paint.setStyle(SkPaint::kFill_Style);
SkBitmap bmp;
create(&bmp, SkBitmap::kARGB_8888_Config, 0xFFFFFFFF);
- bmp.setIsOpaque(false);
+ bmp.setAlphaType(kPremul_SkAlphaType);
SkShader* shader = SkShader::CreateBitmapShader(bmp,
SkShader::kClamp_TileMode, SkShader::kClamp_TileMode);
paint.setShader(shader)->unref();

Powered by Google App Engine
This is Rietveld 408576698