diff options
author | 2017-07-10 11:51:37 -0400 | |
---|---|---|
committer | 2017-07-10 17:06:48 +0000 | |
commit | 742a3e298fda669006147e4a305bab8452369b1f (patch) | |
tree | 6b5ceb03ecdfbc3f3e86f16357207a67e82acb99 /src/codec/SkIcoCodec.cpp | |
parent | da1893fe3a654b551516ce706a363eebf8471511 (diff) |
Remove support for decoding to kIndex_8
Fix up callsites, and remove tests that no longer make sense.
Bug: skia:6828
Change-Id: I2548c4b7528b7b1be7412563156f27b52c9d4295
Reviewed-on: https://skia-review.googlesource.com/21664
Reviewed-by: Derek Sollenberger <djsollen@google.com>
Commit-Queue: Leon Scroggins <scroggo@google.com>
Diffstat (limited to 'src/codec/SkIcoCodec.cpp')
-rw-r--r-- | src/codec/SkIcoCodec.cpp | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/src/codec/SkIcoCodec.cpp b/src/codec/SkIcoCodec.cpp index cde233a1bd..d1cbed0377 100644 --- a/src/codec/SkIcoCodec.cpp +++ b/src/codec/SkIcoCodec.cpp @@ -255,8 +255,8 @@ bool SkIcoCodec::onDimensionsSupported(const SkISize& dim) { */ SkCodec::Result SkIcoCodec::onGetPixels(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes, - const Options& opts, SkPMColor* colorTable, - int* colorCount, int* rowsDecoded) { + const Options& opts, + int* rowsDecoded) { if (opts.fSubset) { // Subsets are not supported. return kUnimplemented; @@ -271,7 +271,7 @@ SkCodec::Result SkIcoCodec::onGetPixels(const SkImageInfo& dstInfo, } SkCodec* embeddedCodec = fEmbeddedCodecs->operator[](index).get(); - result = embeddedCodec->getPixels(dstInfo, dst, dstRowBytes, &opts, colorTable, colorCount); + result = embeddedCodec->getPixels(dstInfo, dst, dstRowBytes, &opts); switch (result) { case kSuccess: case kIncompleteInput: @@ -292,7 +292,7 @@ SkCodec::Result SkIcoCodec::onGetPixels(const SkImageInfo& dstInfo, } SkCodec::Result SkIcoCodec::onStartScanlineDecode(const SkImageInfo& dstInfo, - const SkCodec::Options& options, SkPMColor colorTable[], int* colorCount) { + const SkCodec::Options& options) { int index = 0; SkCodec::Result result = kInvalidScale; while (true) { @@ -302,7 +302,7 @@ SkCodec::Result SkIcoCodec::onStartScanlineDecode(const SkImageInfo& dstInfo, } SkCodec* embeddedCodec = fEmbeddedCodecs->operator[](index).get(); - result = embeddedCodec->startScanlineDecode(dstInfo, &options, colorTable, colorCount); + result = embeddedCodec->startScanlineDecode(dstInfo, &options); if (kSuccess == result) { fCurrScanlineCodec = embeddedCodec; fCurrIncrementalCodec = nullptr; @@ -327,8 +327,7 @@ bool SkIcoCodec::onSkipScanlines(int count) { } SkCodec::Result SkIcoCodec::onStartIncrementalDecode(const SkImageInfo& dstInfo, - void* pixels, size_t rowBytes, const SkCodec::Options& options, - SkPMColor* colorTable, int* colorCount) { + void* pixels, size_t rowBytes, const SkCodec::Options& options) { int index = 0; while (true) { index = this->chooseCodec(dstInfo.dimensions(), index); @@ -338,7 +337,7 @@ SkCodec::Result SkIcoCodec::onStartIncrementalDecode(const SkImageInfo& dstInfo, SkCodec* embeddedCodec = fEmbeddedCodecs->operator[](index).get(); switch (embeddedCodec->startIncrementalDecode(dstInfo, - pixels, rowBytes, &options, colorTable, colorCount)) { + pixels, rowBytes, &options)) { case kSuccess: fCurrIncrementalCodec = embeddedCodec; fCurrScanlineCodec = nullptr; @@ -356,8 +355,7 @@ SkCodec::Result SkIcoCodec::onStartIncrementalDecode(const SkImageInfo& dstInfo, // valid for scanline decoding. // Once BMP supports incremental decoding this workaround can go // away. - if (embeddedCodec->startScanlineDecode(dstInfo, nullptr, - colorTable, colorCount) == kSuccess) { + if (embeddedCodec->startScanlineDecode(dstInfo) == kSuccess) { return kUnimplemented; } // Move on to the next embedded codec. |