| 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 "SkImageInfo.h" | 10 #include "SkImageInfo.h" |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 93 /* | 93 /* |
| 94 * | 94 * |
| 95 * Creates a bmp decoder | 95 * Creates a bmp decoder |
| 96 * Reads enough of the stream to determine the image format | 96 * Reads enough of the stream to determine the image format |
| 97 * | 97 * |
| 98 */ | 98 */ |
| 99 static SkCodec* NewFromStream(SkStream*, bool isIco); | 99 static SkCodec* NewFromStream(SkStream*, bool isIco); |
| 100 | 100 |
| 101 /* | 101 /* |
| 102 * | 102 * |
| 103 * Read enough of the stream to initialize the SkBmpCodec. Returns a bool |
| 104 * representing success or failure. If it returned true, and codecOut was |
| 105 * not NULL, it will be set to a new SkBmpCodec. |
| 106 * |
| 107 */ |
| 108 static bool ReadHeader(SkStream*, bool isIco, SkCodec** codecOut); |
| 109 |
| 110 /* |
| 111 * |
| 103 * Performs the bitmap decoding for bit masks input format | 112 * Performs the bitmap decoding for bit masks input format |
| 104 * | 113 * |
| 105 */ | 114 */ |
| 106 Result decodeMask(const SkImageInfo& dstInfo, void* dst, | 115 Result decodeMask(const SkImageInfo& dstInfo, void* dst, |
| 107 size_t dstRowBytes); | 116 size_t dstRowBytes); |
| 108 | 117 |
| 109 /* | 118 /* |
| 110 * | 119 * |
| 111 * Set an RLE pixel using the color table | 120 * Set an RLE pixel using the color table |
| 112 * | 121 * |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 174 SkAutoTDelete<SkColorTable> fColorTable; // owned | 183 SkAutoTDelete<SkColorTable> fColorTable; // owned |
| 175 uint32_t fNumColors; | 184 uint32_t fNumColors; |
| 176 const uint32_t fBytesPerColor; | 185 const uint32_t fBytesPerColor; |
| 177 const uint32_t fOffset; | 186 const uint32_t fOffset; |
| 178 const RowOrder fRowOrder; | 187 const RowOrder fRowOrder; |
| 179 const size_t fRLEBytes; | 188 const size_t fRLEBytes; |
| 180 const bool fIsIco; | 189 const bool fIsIco; |
| 181 | 190 |
| 182 typedef SkCodec INHERITED; | 191 typedef SkCodec INHERITED; |
| 183 }; | 192 }; |
| OLD | NEW |