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

Unified Diff: third_party/WebKit/Source/platform/graphics/DeferredImageDecoder.cpp

Issue 2454123002: Refactor image decoders to use 'colorSpace' instead of 'colorProfile' (Closed)
Patch Set: Fix legacy ImageFrame Created 4 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: third_party/WebKit/Source/platform/graphics/DeferredImageDecoder.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/DeferredImageDecoder.cpp b/third_party/WebKit/Source/platform/graphics/DeferredImageDecoder.cpp
index f537818dff763662ffd2626a2e65aaead7bcadd2..c791aa4197a8ce6fff89446fc06da839a49c9a1e 100644
--- a/third_party/WebKit/Source/platform/graphics/DeferredImageDecoder.cpp
+++ b/third_party/WebKit/Source/platform/graphics/DeferredImageDecoder.cpp
@@ -61,7 +61,7 @@ std::unique_ptr<DeferredImageDecoder> DeferredImageDecoder::create(
PassRefPtr<SharedBuffer> passData,
bool dataComplete,
ImageDecoder::AlphaOption alphaOption,
- ImageDecoder::GammaAndColorProfileOption colorOptions) {
+ ImageDecoder::ColorSpaceOption colorOptions) {
RefPtr<SharedBuffer> data = passData;
std::unique_ptr<ImageDecoder> actualDecoder =
@@ -90,7 +90,7 @@ DeferredImageDecoder::DeferredImageDecoder(
: m_allDataReceived(false),
m_actualDecoder(std::move(actualDecoder)),
m_repetitionCount(cAnimationNone),
- m_hasColorProfile(false),
+ m_hasColorSpace(false),
m_canYUVDecode(false),
m_hasHotSpot(false) {}
@@ -179,9 +179,8 @@ bool DeferredImageDecoder::isSizeAvailable() {
return m_actualDecoder ? m_actualDecoder->isSizeAvailable() : true;
}
-bool DeferredImageDecoder::hasColorProfile() const {
- return m_actualDecoder ? m_actualDecoder->hasColorProfile()
- : m_hasColorProfile;
+bool DeferredImageDecoder::hasColorSpace() const {
+ return m_actualDecoder ? m_actualDecoder->hasColorSpace() : m_hasColorSpace;
}
IntSize DeferredImageDecoder::size() const {
@@ -267,7 +266,7 @@ void DeferredImageDecoder::activateLazyDecoding() {
// future.)
m_canYUVDecode = RuntimeEnabledFeatures::decodeToYUVEnabled() &&
(m_filenameExtension == "jpg");
- m_hasColorProfile = m_actualDecoder->hasColorProfile();
+ m_hasColorSpace = m_actualDecoder->hasColorSpace();
const bool isSingleFrame =
m_actualDecoder->repetitionCount() == cAnimationNone ||

Powered by Google App Engine
This is Rietveld 408576698