aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/codec/SkCodec_libpng.h
diff options
context:
space:
mode:
authorGravatar msarett <msarett@google.com>2015-04-29 07:38:43 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-04-29 07:38:43 -0700
commit9e43cabaa1ff26167e990f0bcb9a5c20d662d52c (patch)
treeeabfffdde1d3f2fbdbf34ec8ba5fe6ea74d21046 /src/codec/SkCodec_libpng.h
parent385e88cc16ed872ece98471513764c8e7ca1a26c (diff)
Requires a minor API change to pass the color table to getScanlineDecoder, as we do with getPixels().
Diffstat (limited to 'src/codec/SkCodec_libpng.h')
-rw-r--r--src/codec/SkCodec_libpng.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/codec/SkCodec_libpng.h b/src/codec/SkCodec_libpng.h
index e9bcd043b4..3146331764 100644
--- a/src/codec/SkCodec_libpng.h
+++ b/src/codec/SkCodec_libpng.h
@@ -30,7 +30,8 @@ protected:
Result onGetPixels(const SkImageInfo&, void*, size_t, const Options&, SkPMColor*, int*)
override;
SkEncodedFormat onGetEncodedFormat() const override { return kPNG_SkEncodedFormat; }
- SkScanlineDecoder* onGetScanlineDecoder(const SkImageInfo& dstInfo) override;
+ SkScanlineDecoder* onGetScanlineDecoder(const SkImageInfo& dstInfo, const Options& options,
+ SkPMColor ctable[], int* ctableCount) override;
bool onReallyHasAlpha() const override { return fReallyHasAlpha; }
private:
png_structp fPng_ptr;
@@ -49,7 +50,7 @@ private:
// Helper to set up swizzler and color table. Also calls png_read_update_info.
Result initializeSwizzler(const SkImageInfo& requestedInfo, void* dst,
- size_t rowBytes, const Options&, int* ctableCount);
+ size_t rowBytes, const Options&, SkPMColor*, int* ctableCount);
// Calls rewindIfNeeded, and returns true if the decoder can continue.
bool handleRewind();
bool decodePalette(bool premultiply, int bitDepth, int* ctableCount);