diff options
author | msarett <msarett@google.com> | 2016-09-08 10:14:04 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-09-08 10:14:05 -0700 |
commit | 7a9900d6d34e437bb24beb5524a1f6488ae138c9 (patch) | |
tree | 3b81bb6369d1cb9a6d9bbf2282f730cdf8482bff /src/codec/SkBmpCodec.cpp | |
parent | 971cd496b9e25f87f3a75a0015c203322907136a (diff) |
Checking for valid colorType, alphaType, colorSpace in SkCodec
* Refactor to share code between SkPngCodec and SkWebpCodec
* Didn't end up sharing with SkJpegCodec but did refactor
that code a bit
* Disallow conversions to F16 with non-linear color spaces
* Fail to decode if we fail to create a SkColorSpaceXform
(should be an assert soon). We used to fallback on a
legacy decode if we failed to create the transform.
* A bunch of name changes
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2319293003
Review-Url: https://codereview.chromium.org/2319293003
Diffstat (limited to 'src/codec/SkBmpCodec.cpp')
-rw-r--r-- | src/codec/SkBmpCodec.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/codec/SkBmpCodec.cpp b/src/codec/SkBmpCodec.cpp index 1c999eba3c..2f796ad667 100644 --- a/src/codec/SkBmpCodec.cpp +++ b/src/codec/SkBmpCodec.cpp @@ -603,7 +603,7 @@ int32_t SkBmpCodec::getDstRow(int32_t y, int32_t height) const { SkCodec::Result SkBmpCodec::onStartScanlineDecode(const SkImageInfo& dstInfo, const SkCodec::Options& options, SkPMColor inputColorPtr[], int* inputColorCount) { - if (!conversion_possible(dstInfo, this->getInfo())) { + if (!conversion_possible_ignore_color_space(dstInfo, this->getInfo())) { SkCodecPrintf("Error: cannot convert input type to output type.\n"); return kInvalidConversion; } |