Avoid pretending to support CMYK color xforms in SkJpegCodec
BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4439 Change-Id: I274930fd947585e7b2a4716c5c51aef267574ddd Reviewed-on: https://skia-review.googlesource.com/4439 Reviewed-by: Leon Scroggins <scroggo@google.com> Commit-Queue: Matt Sarett <msarett@google.com>
This commit is contained in:
parent
a4a4488a4c
commit
fba1420715
@ -368,6 +368,9 @@ bool SkJpegCodec::setOutputColorSpace(const SkImageInfo& dstInfo) {
|
||||
// we must do it ourselves.
|
||||
J_COLOR_SPACE encodedColorType = fDecoderMgr->dinfo()->jpeg_color_space;
|
||||
bool isCMYK = (JCS_CMYK == encodedColorType || JCS_YCCK == encodedColorType);
|
||||
if (isCMYK && this->colorXform()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Check for valid color types and set the output color space
|
||||
switch (dstInfo.colorType()) {
|
||||
|
Loading…
Reference in New Issue
Block a user