| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2012 Google Inc. | 3 * Copyright 2012 Google Inc. |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 | 9 |
| 10 #ifndef SkColorTable_DEFINED | 10 #ifndef SkColorTable_DEFINED |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 68 Also, unlike lockColors(), the returned array here cannot be modified. | 68 Also, unlike lockColors(), the returned array here cannot be modified. |
| 69 */ | 69 */ |
| 70 const uint16_t* lock16BitCache(); | 70 const uint16_t* lock16BitCache(); |
| 71 /** Balancing call to lock16BitCache(). | 71 /** Balancing call to lock16BitCache(). |
| 72 */ | 72 */ |
| 73 void unlock16BitCache() { | 73 void unlock16BitCache() { |
| 74 SkASSERT(f16BitCacheLockCount > 0); | 74 SkASSERT(f16BitCacheLockCount > 0); |
| 75 SkDEBUGCODE(f16BitCacheLockCount -= 1); | 75 SkDEBUGCODE(f16BitCacheLockCount -= 1); |
| 76 } | 76 } |
| 77 | 77 |
| 78 explicit SkColorTable(SkFlattenableReadBuffer&); | 78 explicit SkColorTable(SkReadBuffer&); |
| 79 void writeToBuffer(SkFlattenableWriteBuffer&) const; | 79 void writeToBuffer(SkWriteBuffer&) const; |
| 80 | 80 |
| 81 private: | 81 private: |
| 82 SkPMColor* fColors; | 82 SkPMColor* fColors; |
| 83 uint16_t* f16BitCache; | 83 uint16_t* f16BitCache; |
| 84 uint16_t fCount; | 84 uint16_t fCount; |
| 85 uint8_t fAlphaType; | 85 uint8_t fAlphaType; |
| 86 SkDEBUGCODE(int fColorLockCount;) | 86 SkDEBUGCODE(int fColorLockCount;) |
| 87 SkDEBUGCODE(int f16BitCacheLockCount;) | 87 SkDEBUGCODE(int f16BitCacheLockCount;) |
| 88 | 88 |
| 89 void inval16BitCache(); | 89 void inval16BitCache(); |
| 90 | 90 |
| 91 typedef SkRefCnt INHERITED; | 91 typedef SkRefCnt INHERITED; |
| 92 }; | 92 }; |
| 93 | 93 |
| 94 #endif | 94 #endif |
| OLD | NEW |