| 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 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 protected: | 42 protected: |
| 43 | 43 |
| 44 Result onGetPixels(const SkImageInfo& dstInfo, void* dst, | 44 Result onGetPixels(const SkImageInfo& dstInfo, void* dst, |
| 45 size_t dstRowBytes, const Options&, SkPMColor*, | 45 size_t dstRowBytes, const Options&, SkPMColor*, |
| 46 int*) override; | 46 int*) override; |
| 47 | 47 |
| 48 private: | 48 private: |
| 49 | 49 |
| 50 /* | 50 /* |
| 51 * Creates the color table | 51 * Creates the color table |
| 52 * Sets colorCount to the new color count if it is non-NULL | 52 * Sets colorCount to the new color count if it is non-nullptr |
| 53 */ | 53 */ |
| 54 bool createColorTable(int* colorCount); | 54 bool createColorTable(int* colorCount); |
| 55 | 55 |
| 56 bool initializeStreamBuffer(); | 56 bool initializeStreamBuffer(); |
| 57 | 57 |
| 58 /* | 58 /* |
| 59 * Before signalling kIncompleteInput, we should attempt to load the | 59 * Before signalling kIncompleteInput, we should attempt to load the |
| 60 * stream buffer with additional data. | 60 * stream buffer with additional data. |
| 61 * | 61 * |
| 62 * @return the number of bytes remaining in the stream buffer after | 62 * @return the number of bytes remaining in the stream buffer after |
| (...skipping 23 matching lines...) Expand all Loading... |
| 86 SkAutoTUnref<SkColorTable> fColorTable; // owned | 86 SkAutoTUnref<SkColorTable> fColorTable; // owned |
| 87 const uint32_t fNumColors; | 87 const uint32_t fNumColors; |
| 88 const uint32_t fBytesPerColor; | 88 const uint32_t fBytesPerColor; |
| 89 const uint32_t fOffset; | 89 const uint32_t fOffset; |
| 90 SkAutoTDeleteArray<uint8_t> fStreamBuffer; | 90 SkAutoTDeleteArray<uint8_t> fStreamBuffer; |
| 91 size_t fRLEBytes; | 91 size_t fRLEBytes; |
| 92 uint32_t fCurrRLEByte; | 92 uint32_t fCurrRLEByte; |
| 93 | 93 |
| 94 typedef SkBmpCodec INHERITED; | 94 typedef SkBmpCodec INHERITED; |
| 95 }; | 95 }; |
| OLD | NEW |