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 "SkBmpCodec.h" | 8 #include "SkBmpCodec.h" |
9 #include "SkColorTable.h" | 9 #include "SkColorTable.h" |
10 #include "SkImageInfo.h" | 10 #include "SkImageInfo.h" |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 bool createColorTable(SkAlphaType alphaType, int* colorCount); | 71 bool createColorTable(SkAlphaType alphaType, int* colorCount); |
72 | 72 |
73 bool initializeSwizzler(const SkImageInfo& dstInfo, const Options& opts); | 73 bool initializeSwizzler(const SkImageInfo& dstInfo, const Options& opts); |
74 | 74 |
75 int decodeRows(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes, | 75 int decodeRows(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes, |
76 const Options& opts) override; | 76 const Options& opts) override; |
77 | 77 |
78 Result decodeIcoMask(const SkImageInfo& dstInfo, void* dst, size_t dstRowByt
es); | 78 Result decodeIcoMask(const SkImageInfo& dstInfo, void* dst, size_t dstRowByt
es); |
79 | 79 |
80 SkAutoTUnref<SkColorTable> fColorTable; // owned | 80 SkAutoTUnref<SkColorTable> fColorTable; // owned |
| 81 // fNumColors is the number specified in the header, or 0 if not present in
the header. |
81 const uint32_t fNumColors; | 82 const uint32_t fNumColors; |
82 const uint32_t fBytesPerColor; | 83 const uint32_t fBytesPerColor; |
83 const uint32_t fOffset; | 84 const uint32_t fOffset; |
84 SkAutoTDelete<SkSwizzler> fSwizzler; | 85 SkAutoTDelete<SkSwizzler> fSwizzler; |
85 const size_t fSrcRowBytes; | 86 const size_t fSrcRowBytes; |
86 SkAutoTDeleteArray<uint8_t> fSrcBuffer; | 87 SkAutoTDeleteArray<uint8_t> fSrcBuffer; |
87 const bool fInIco; | 88 const bool fInIco; |
88 | 89 |
89 typedef SkBmpCodec INHERITED; | 90 typedef SkBmpCodec INHERITED; |
90 }; | 91 }; |
OLD | NEW |