diff options
author | joshualitt <joshualitt@chromium.org> | 2016-02-16 06:47:52 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-02-16 06:47:52 -0800 |
commit | ddd22d86455d95941ea21253b210819c1d4a3863 (patch) | |
tree | d371c8482601378fbbf902528a42babcb237ddd2 /src/gpu/text/GrAtlasTextBlob.h | |
parent | 6f65957335e9a1fa3eb0fdf8dee0a66d35fc27f6 (diff) |
Remove last bit of privacy violation for GrAtlasTextBlob
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1698503002
Review URL: https://codereview.chromium.org/1698503002
Diffstat (limited to 'src/gpu/text/GrAtlasTextBlob.h')
-rw-r--r-- | src/gpu/text/GrAtlasTextBlob.h | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/src/gpu/text/GrAtlasTextBlob.h b/src/gpu/text/GrAtlasTextBlob.h index b4168e921e..63eb56b6f8 100644 --- a/src/gpu/text/GrAtlasTextBlob.h +++ b/src/gpu/text/GrAtlasTextBlob.h @@ -17,6 +17,7 @@ #include "SkSurfaceProps.h" #include "SkTInternalLList.h" +class GrBlobRegenHelper; struct GrDistanceFieldAdjustTable; class GrMemoryPool; class GrTextContext; @@ -108,6 +109,8 @@ public: void setHasDistanceField() { fTextType |= kHasDistanceField_TextType; } void setHasBitmap() { fTextType |= kHasBitmap_TextType; } + int runCount() const { return fRunCount; } + void push_back_run(int currRun) { SkASSERT(currRun < fRunCount); if (currRun > 0) { @@ -255,6 +258,13 @@ public: this->setupViewMatrix(viewMatrix, x, y); } + void regenInBatch(GrDrawBatch::Target* target, GrBatchFontCache* fontCache, + GrBlobRegenHelper *helper, int run, int subRun, SkGlyphCache** cache, + SkTypeface** typeface, GrFontScaler** scaler, + const SkDescriptor** desc, size_t vertexStride, + GrColor color, SkScalar transX, SkScalar transY, + void** vertices, size_t* byteCount, int* glyphCount); + const Key& key() const { return fKey; } ~GrAtlasTextBlob() { @@ -453,6 +463,17 @@ private: bool fDrawAsPaths; }; + template <bool regenPos, bool regenCol, bool regenTexCoords, bool regenGlyphs> + void regenInBatch(GrDrawBatch::Target* target, + GrBatchFontCache* fontCache, + GrBlobRegenHelper* helper, + Run* run, Run::SubRunInfo* info, SkGlyphCache** cache, + SkTypeface** typeface, GrFontScaler** scaler, + const SkDescriptor** desc, + int glyphCount, size_t vertexStride, + GrColor color, SkScalar transX, + SkScalar transY) const; + inline GrDrawBatch* createBatch(const Run::SubRunInfo& info, int glyphCount, int run, int subRun, GrColor color, SkScalar transX, SkScalar transY, @@ -510,8 +531,6 @@ private: SkScalar fMinMaxScale; int fRunCount; uint8_t fTextType; - - friend class GrAtlasTextBatch; // We might be able to get rid of this friending }; #endif |