OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2015 Google Inc. | 2 * Copyright 2015 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #include "SkCodec.h" | 8 #include "SkCodec.h" |
9 #include "SkColorTable.h" | 9 #include "SkColorTable.h" |
10 #include "SkEncodedFormat.h" | 10 #include "SkEncodedFormat.h" |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 | 46 |
47 SkSwizzler::SrcConfig fSrcConfig; | 47 SkSwizzler::SrcConfig fSrcConfig; |
48 int fNumberPasses; | 48 int fNumberPasses; |
49 bool fReallyHasAlpha; | 49 bool fReallyHasAlpha; |
50 int fBitDepth; | 50 int fBitDepth; |
51 | 51 |
52 SkPngCodec(const SkImageInfo&, SkStream*, png_structp, png_infop, int); | 52 SkPngCodec(const SkImageInfo&, SkStream*, png_structp, png_infop, int); |
53 | 53 |
54 | 54 |
55 // Helper to set up swizzler and color table. Also calls png_read_update_inf
o. | 55 // Helper to set up swizzler and color table. Also calls png_read_update_inf
o. |
56 Result initializeSwizzler(const SkImageInfo& requestedInfo, void* dst, | 56 Result initializeSwizzler(const SkImageInfo& requestedInfo, const Options&, |
57 size_t rowBytes, const Options&, SkPMColor*, int*
ctableCount); | 57 SkPMColor*, int* ctableCount); |
58 | 58 |
59 // Calls rewindIfNeeded and returns true if the decoder can continue. | 59 // Calls rewindIfNeeded and returns true if the decoder can continue. |
60 bool handleRewind(); | 60 bool handleRewind(); |
61 bool decodePalette(bool premultiply, int* ctableCount); | 61 bool decodePalette(bool premultiply, int* ctableCount); |
62 void destroyReadStruct(); | 62 void destroyReadStruct(); |
63 | 63 |
64 friend class SkPngScanlineDecoder; | 64 friend class SkPngScanlineDecoder; |
65 friend class SkPngInterlacedScanlineDecoder; | 65 friend class SkPngInterlacedScanlineDecoder; |
66 | 66 |
67 typedef SkCodec INHERITED; | 67 typedef SkCodec INHERITED; |
68 }; | 68 }; |
OLD | NEW |