Chromium Code Reviews| Index: src/gpu/text/GrAtlasTextContext.h |
| diff --git a/src/gpu/text/GrAtlasTextContext.h b/src/gpu/text/GrAtlasTextContext.h |
| index f2536b34dba6e2941f4d24885a89aa124ce65580..bc758ef8084f5b30e922a8173adec382656552e2 100644 |
| --- a/src/gpu/text/GrAtlasTextContext.h |
| +++ b/src/gpu/text/GrAtlasTextContext.h |
| @@ -31,29 +31,33 @@ class SkGlyph; |
| */ |
| class GrAtlasTextContext : public GrTextContext { |
| public: |
| - static GrAtlasTextContext* Create(GrContext*); |
| + static GrAtlasTextContext* Create(); |
|
robertphillips
2016/02/10 19:44:39
private for canDraw ?
|
| - bool canDraw(const SkPaint&, const SkMatrix& viewMatrix, const SkSurfaceProps&); |
| - void drawText(GrDrawContext*, const GrClip&, const GrPaint&, const SkPaint&, |
| + bool canDraw(const SkPaint&, const SkMatrix& viewMatrix, const SkSurfaceProps&, |
| + const GrShaderCaps&); |
| + void drawText(GrContext*, GrDrawContext*, const GrClip&, const GrPaint&, const SkPaint&, |
| const SkMatrix& viewMatrix, const SkSurfaceProps&, const char text[], |
| size_t byteLength, SkScalar x, SkScalar y, |
| const SkIRect& regionClipBounds) override; |
| - void drawPosText(GrDrawContext*, const GrClip&, const GrPaint&, |
| + void drawPosText(GrContext*, GrDrawContext*, const GrClip&, const GrPaint&, |
| const SkPaint&, const SkMatrix& viewMatrix, const SkSurfaceProps&, |
| const char text[], size_t byteLength, |
| const SkScalar pos[], int scalarsPerPosition, |
| const SkPoint& offset, const SkIRect& regionClipBounds) override; |
| - void drawTextBlob(GrDrawContext*, const GrClip&, const SkPaint&, |
| + void drawTextBlob(GrContext*, GrDrawContext*, const GrClip&, const SkPaint&, |
| const SkMatrix& viewMatrix, const SkSurfaceProps&, const SkTextBlob*, |
| SkScalar x, SkScalar y, |
| SkDrawFilter*, const SkIRect& clipBounds) override; |
| private: |
| - GrAtlasTextContext(GrContext*); |
| + GrAtlasTextContext(); |
| // sets up the descriptor on the blob and returns a detached cache. Client must attach |
| inline static GrColor ComputeCanonicalColor(const SkPaint&, bool lcd); |
| - void regenerateTextBlob(GrAtlasTextBlob* bmp, const SkPaint& skPaint, GrColor, |
| + void regenerateTextBlob(GrAtlasTextBlob* bmp, |
| + GrBatchFontCache*, |
| + const GrShaderCaps&, |
| + const SkPaint& skPaint, GrColor, |
| const SkMatrix& viewMatrix, |
| const SkSurfaceProps&, |
| const SkTextBlob* blob, SkScalar x, SkScalar y, |
| @@ -61,12 +65,16 @@ private: |
| inline static bool HasLCD(const SkTextBlob*); |
|
robertphillips
2016/02/10 19:44:39
IIUC these aren't just test methods.
|
| // Test methods |
| - inline GrAtlasTextBlob* createDrawTextBlob(const GrPaint&, |
| + inline GrAtlasTextBlob* createDrawTextBlob(GrTextBlobCache*, |
| + GrBatchFontCache*, const GrShaderCaps&, |
| + const GrPaint&, |
| const SkPaint&, const SkMatrix& viewMatrix, |
| const SkSurfaceProps&, |
| const char text[], size_t byteLength, |
| SkScalar x, SkScalar y); |
| - inline GrAtlasTextBlob* createDrawPosTextBlob(const GrPaint&, |
| + inline GrAtlasTextBlob* createDrawPosTextBlob(GrTextBlobCache*, GrBatchFontCache*, |
| + const GrShaderCaps&, |
| + const GrPaint&, |
| const SkPaint&, const SkMatrix& viewMatrix, |
| const SkSurfaceProps&, |
| const char text[], size_t byteLength, |
| @@ -74,7 +82,6 @@ private: |
| const SkPoint& offset); |
| const GrDistanceFieldAdjustTable* dfAdjustTable() const { return fDistanceAdjustTable; } |
| - GrTextBlobCache* fCache; |
| SkAutoTUnref<const GrDistanceFieldAdjustTable> fDistanceAdjustTable; |
| #ifdef GR_TEST_UTILS |