| 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 #ifndef GrAtlasTextContext_DEFINED | 8 #ifndef GrAtlasTextContext_DEFINED |
| 9 #define GrAtlasTextContext_DEFINED | 9 #define GrAtlasTextContext_DEFINED |
| 10 | 10 |
| 11 #include "GrTextContext.h" | 11 #include "GrTextContext.h" |
| 12 | 12 |
| 13 #include "GrBatchAtlas.h" |
| 13 #include "GrGeometryProcessor.h" | 14 #include "GrGeometryProcessor.h" |
| 14 #include "SkDescriptor.h" | 15 #include "SkDescriptor.h" |
| 15 #include "SkTextBlob.h" | 16 #include "SkTextBlob.h" |
| 16 #include "SkTHash.h" | 17 #include "SkTHash.h" |
| 17 | 18 |
| 18 class GrBatchTextStrike; | 19 class GrBatchTextStrike; |
| 19 class GrPipelineBuilder; | 20 class GrPipelineBuilder; |
| 20 | 21 |
| 21 /* | 22 /* |
| 22 * This class implements GrTextContext using standard bitmap fonts, and can also
process textblobs. | 23 * This class implements GrTextContext using standard bitmap fonts, and can also
process textblobs. |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 , fGlyphStartIndex(0) | 97 , fGlyphStartIndex(0) |
| 97 , fGlyphEndIndex(0) | 98 , fGlyphEndIndex(0) |
| 98 , fVertexStartIndex(0) | 99 , fVertexStartIndex(0) |
| 99 , fVertexEndIndex(0) {} | 100 , fVertexEndIndex(0) {} |
| 100 GrMaskFormat fMaskFormat; | 101 GrMaskFormat fMaskFormat; |
| 101 uint64_t fAtlasGeneration; | 102 uint64_t fAtlasGeneration; |
| 102 uint32_t fGlyphStartIndex; | 103 uint32_t fGlyphStartIndex; |
| 103 uint32_t fGlyphEndIndex; | 104 uint32_t fGlyphEndIndex; |
| 104 size_t fVertexStartIndex; | 105 size_t fVertexStartIndex; |
| 105 size_t fVertexEndIndex; | 106 size_t fVertexEndIndex; |
| 107 GrBatchAtlas::BulkUseTokenUpdater fBulkUseToken; |
| 106 }; | 108 }; |
| 107 SkSTArray<1, SubRunInfo, true> fSubRunInfo; | 109 SkSTArray<1, SubRunInfo, true> fSubRunInfo; |
| 108 SkAutoDescriptor fDescriptor; | 110 SkAutoDescriptor fDescriptor; |
| 109 SkAutoTUnref<SkTypeface> fTypeface; | 111 SkAutoTUnref<SkTypeface> fTypeface; |
| 110 SkRect fVertexBounds; | 112 SkRect fVertexBounds; |
| 111 GrColor fColor; | 113 GrColor fColor; |
| 112 bool fInitialized; | 114 bool fInitialized; |
| 113 bool fDrawAsPaths; | 115 bool fDrawAsPaths; |
| 114 }; | 116 }; |
| 115 | 117 |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 198 // TODO use real cache | 200 // TODO use real cache |
| 199 static void ClearCacheEntry(uint32_t key, BitmapTextBlob**); | 201 static void ClearCacheEntry(uint32_t key, BitmapTextBlob**); |
| 200 SkTHashMap<uint32_t, BitmapTextBlob*, BitmapTextBlob::Hash> fCache; | 202 SkTHashMap<uint32_t, BitmapTextBlob*, BitmapTextBlob::Hash> fCache; |
| 201 | 203 |
| 202 friend class BitmapTextBatch; | 204 friend class BitmapTextBatch; |
| 203 | 205 |
| 204 typedef GrTextContext INHERITED; | 206 typedef GrTextContext INHERITED; |
| 205 }; | 207 }; |
| 206 | 208 |
| 207 #endif | 209 #endif |
| OLD | NEW |