OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2013 Google Inc. | 2 * Copyright 2013 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 GrBitmapTextContext_DEFINED | 8 #ifndef GrBitmapTextContext_DEFINED |
9 #define GrBitmapTextContext_DEFINED | 9 #define GrBitmapTextContext_DEFINED |
10 | 10 |
(...skipping 22 matching lines...) Expand all Loading... |
33 private: | 33 private: |
34 enum { | 34 enum { |
35 kMinRequestedGlyphs = 1, | 35 kMinRequestedGlyphs = 1, |
36 kDefaultRequestedGlyphs = 64, | 36 kDefaultRequestedGlyphs = 64, |
37 kMinRequestedVerts = kMinRequestedGlyphs * 4, | 37 kMinRequestedVerts = kMinRequestedGlyphs * 4, |
38 kDefaultRequestedVerts = kDefaultRequestedGlyphs * 4, | 38 kDefaultRequestedVerts = kDefaultRequestedGlyphs * 4, |
39 }; | 39 }; |
40 | 40 |
41 GrTextStrike* fStrike; | 41 GrTextStrike* fStrike; |
42 void* fVertices; | 42 void* fVertices; |
43 int32_t fMaxVertices; | 43 int fCurrVertex; |
| 44 int fMaxVertices; |
| 45 SkRect fVertexBounds; |
44 GrTexture* fCurrTexture; | 46 GrTexture* fCurrTexture; |
| 47 GrMaskFormat fCurrMaskFormat; |
45 SkAutoTUnref<GrGeometryProcessor> fCachedGeometryProcessor; | 48 SkAutoTUnref<GrGeometryProcessor> fCachedGeometryProcessor; |
46 // Used to check whether fCachedEffect is still valid. | 49 // Used to check whether fCachedEffect is still valid. |
47 uint32_t fEffectTextureUniqueID; | 50 uint32_t fEffectTextureUniqueID; |
48 int fCurrVertex; | |
49 SkRect fVertexBounds; | |
50 | 51 |
51 void init(const GrPaint&, const SkPaint&); | 52 void init(const GrPaint&, const SkPaint&); |
52 void appendGlyph(GrGlyph::PackedID, SkFixed left, SkFixed top, GrFontScaler*
); | 53 void appendGlyph(GrGlyph::PackedID, SkFixed left, SkFixed top, GrFontScaler*
); |
53 void flush(); // automatically called by destructor | 54 void flush(); // automatically called by destructor |
54 void finish(); | 55 void finish(); |
55 | 56 |
56 }; | 57 }; |
57 | 58 |
58 #endif | 59 #endif |
OLD | NEW |