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 |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 GrColor color, GrFontScaler*, const SkIRect& clipRect, Sk
Scalar textRatio, | 64 GrColor color, GrFontScaler*, const SkIRect& clipRect, Sk
Scalar textRatio, |
65 const SkMatrix& viewMatrix); | 65 const SkMatrix& viewMatrix); |
66 inline void appendGlyphPath(GrAtlasTextBlob*, GrGlyph*, GrFontScaler*, const
SkGlyph&, | 66 inline void appendGlyphPath(GrAtlasTextBlob*, GrGlyph*, GrFontScaler*, const
SkGlyph&, |
67 SkScalar x, SkScalar y, SkScalar scale = 1.0f, | 67 SkScalar x, SkScalar y, SkScalar scale = 1.0f, |
68 bool applyVM = false); | 68 bool applyVM = false); |
69 inline void appendGlyphCommon(GrAtlasTextBlob*, Run*, Run::SubRunInfo*, | 69 inline void appendGlyphCommon(GrAtlasTextBlob*, Run*, Run::SubRunInfo*, |
70 const SkRect& positions, GrColor color, | 70 const SkRect& positions, GrColor color, |
71 size_t vertexStride, bool useVertexColor, | 71 size_t vertexStride, bool useVertexColor, |
72 GrGlyph*); | 72 GrGlyph*); |
73 | 73 |
74 inline void flushRunAsPaths(GrDrawContext*, GrRenderTarget*, | 74 inline void flushRunAsPaths(GrDrawContext*, |
75 const SkTextBlobRunIterator&, const GrClip& clip
, | 75 const SkTextBlobRunIterator&, const GrClip& clip
, |
76 const SkPaint&, SkDrawFilter*, | 76 const SkPaint&, SkDrawFilter*, |
77 const SkMatrix& viewMatrix, const SkIRect& clipB
ounds, SkScalar x, | 77 const SkMatrix& viewMatrix, const SkIRect& clipB
ounds, SkScalar x, |
78 SkScalar y); | 78 SkScalar y); |
79 inline GrDrawBatch* createBatch(GrAtlasTextBlob*, const PerSubRunInfo&, | 79 inline GrDrawBatch* createBatch(GrAtlasTextBlob*, const PerSubRunInfo&, |
80 int glyphCount, int run, int subRun, | 80 int glyphCount, int run, int subRun, |
81 GrColor, SkScalar transX, SkScalar transY, | 81 GrColor, SkScalar transX, SkScalar transY, |
82 const SkPaint&); | 82 const SkPaint&); |
83 inline void flushRun(GrDrawContext*, GrPipelineBuilder*, GrAtlasTextBlob*, i
nt run, GrColor, | 83 inline void flushRun(GrDrawContext*, GrPipelineBuilder*, GrAtlasTextBlob*, i
nt run, GrColor, |
84 SkScalar transX, SkScalar transY, const SkPaint&); | 84 SkScalar transX, SkScalar transY, const SkPaint&); |
85 inline void flushBigGlyphs(GrAtlasTextBlob* cacheBlob, GrDrawContext*, GrRen
derTarget*, | 85 inline void flushBigGlyphs(GrAtlasTextBlob* cacheBlob, GrDrawContext*, |
86 const GrClip& clip, const SkPaint& skPaint, | 86 const GrClip& clip, const SkPaint& skPaint, |
87 SkScalar transX, SkScalar transY, const SkIRect&
clipBounds); | 87 SkScalar transX, SkScalar transY, const SkIRect&
clipBounds); |
88 | 88 |
89 // We have to flush SkTextBlobs differently from drawText / drawPosText | 89 // We have to flush SkTextBlobs differently from drawText / drawPosText |
90 void flush(const SkTextBlob*, GrAtlasTextBlob*, GrDrawContext*, GrRenderTarg
et*, | 90 void flush(const SkTextBlob*, GrAtlasTextBlob*, GrDrawContext*, GrRenderTarg
et*, |
91 const SkPaint&, const GrPaint&, SkDrawFilter*, const GrClip&, | 91 const SkPaint&, const GrPaint&, SkDrawFilter*, const GrClip&, |
92 const SkMatrix& viewMatrix, const SkIRect& clipBounds, SkScalar x
, SkScalar y, | 92 const SkMatrix& viewMatrix, const SkIRect& clipBounds, SkScalar x
, SkScalar y, |
93 SkScalar transX, SkScalar transY); | 93 SkScalar transX, SkScalar transY); |
94 void flush(GrAtlasTextBlob*, GrDrawContext*, GrRenderTarget*, const SkPaint&
, | 94 void flush(GrAtlasTextBlob*, GrDrawContext*, GrRenderTarget*, const SkPaint&
, |
95 const GrPaint&, const GrClip&, const SkIRect& clipBounds); | 95 const GrPaint&, const GrClip&, const SkIRect& clipBounds); |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
186 friend class GrAtlasTextBatch; | 186 friend class GrAtlasTextBatch; |
187 | 187 |
188 #ifdef GR_TEST_UTILS | 188 #ifdef GR_TEST_UTILS |
189 DRAW_BATCH_TEST_FRIEND(TextBlobBatch); | 189 DRAW_BATCH_TEST_FRIEND(TextBlobBatch); |
190 #endif | 190 #endif |
191 | 191 |
192 typedef GrTextContext INHERITED; | 192 typedef GrTextContext INHERITED; |
193 }; | 193 }; |
194 | 194 |
195 #endif | 195 #endif |
OLD | NEW |