summaryrefslogtreecommitdiffstats
path: root/WebCore/platform/image-decoders/jpeg
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/platform/image-decoders/jpeg')
-rw-r--r--WebCore/platform/image-decoders/jpeg/JPEGImageDecoder.cpp11
-rw-r--r--WebCore/platform/image-decoders/jpeg/JPEGImageDecoder.h2
2 files changed, 4 insertions, 9 deletions
diff --git a/WebCore/platform/image-decoders/jpeg/JPEGImageDecoder.cpp b/WebCore/platform/image-decoders/jpeg/JPEGImageDecoder.cpp
index 855ba24..632d428 100644
--- a/WebCore/platform/image-decoders/jpeg/JPEGImageDecoder.cpp
+++ b/WebCore/platform/image-decoders/jpeg/JPEGImageDecoder.cpp
@@ -222,12 +222,6 @@ public:
// jpeglib cannot convert these to rgb, but it can convert ycck
// to cmyk.
m_info.out_color_space = JCS_CMYK;
-
- // Same as with grayscale images, we convert CMYK images to RGBA
- // ones. When we keep the color profiles of these CMYK images,
- // CoreGraphics will convert their colors again. So, we discard
- // their color profiles to prevent color corruption.
- m_decoder->setIgnoreGammaAndColorProfile(true);
break;
default:
return m_decoder->setFailed();
@@ -404,8 +398,9 @@ void term_source(j_decompress_ptr jd)
src->decoder->decoder()->jpegComplete();
}
-JPEGImageDecoder::JPEGImageDecoder(bool premultiplyAlpha, bool ignoreGammaAndColorProfile)
- : ImageDecoder(premultiplyAlpha, ignoreGammaAndColorProfile)
+JPEGImageDecoder::JPEGImageDecoder(ImageSource::AlphaOption alphaOption,
+ ImageSource::GammaAndColorProfileOption gammaAndColorProfileOption)
+ : ImageDecoder(alphaOption, gammaAndColorProfileOption)
{
}
diff --git a/WebCore/platform/image-decoders/jpeg/JPEGImageDecoder.h b/WebCore/platform/image-decoders/jpeg/JPEGImageDecoder.h
index a60b387..63f29ab 100644
--- a/WebCore/platform/image-decoders/jpeg/JPEGImageDecoder.h
+++ b/WebCore/platform/image-decoders/jpeg/JPEGImageDecoder.h
@@ -37,7 +37,7 @@ namespace WebCore {
// This class decodes the JPEG image format.
class JPEGImageDecoder : public ImageDecoder {
public:
- JPEGImageDecoder(bool premultiplyAlpha, bool ignoreGammaAndColorProfile);
+ JPEGImageDecoder(ImageSource::AlphaOption, ImageSource::GammaAndColorProfileOption);
virtual ~JPEGImageDecoder();
// ImageDecoder