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

Unified Diff: third_party/WebKit/Source/platform/image-decoders/ImageDecoder.h

Issue 2787053004: Respect colorSpace in DecodingImageGenerator::onGetPixels() (Closed)
Patch Set: Rebase Created 3 years, 8 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: third_party/WebKit/Source/platform/image-decoders/ImageDecoder.h
diff --git a/third_party/WebKit/Source/platform/image-decoders/ImageDecoder.h b/third_party/WebKit/Source/platform/image-decoders/ImageDecoder.h
index 8ad824902e14b471d8abb796132adcb51c6371c8..bf81950db69cf8a3c599f667841b3b3caf813acc 100644
--- a/third_party/WebKit/Source/platform/image-decoders/ImageDecoder.h
+++ b/third_party/WebKit/Source/platform/image-decoders/ImageDecoder.h
@@ -226,6 +226,10 @@ class PLATFORM_EXPORT ImageDecoder {
// Transformation from embedded color space to target color space.
SkColorSpaceXform* ColorTransform();
+ AlphaOption GetAlphaOption() const {
+ return premultiply_alpha_ ? kAlphaPremultiplied : kAlphaNotPremultiplied;
+ }
+
// Sets the "decode failure" flag. For caller convenience (since so
// many callers want to return false after calling this), returns false
// to enable easy tailcalling. Subclasses may override this to also

Powered by Google App Engine
This is Rietveld 408576698