| Index: src/gpu/text/GrTextUtils.cpp
|
| diff --git a/src/gpu/text/GrTextUtils.cpp b/src/gpu/text/GrTextUtils.cpp
|
| index 293ea4d891edac7888625522a1563b663bb9e675..9d6bb2c857dfa18de7a512bf1037e60d487dcd8d 100644
|
| --- a/src/gpu/text/GrTextUtils.cpp
|
| +++ b/src/gpu/text/GrTextUtils.cpp
|
| @@ -23,7 +23,7 @@
|
|
|
| void GrTextUtils::DrawBmpText(GrAtlasTextBlob* blob, int runIndex,
|
| GrBatchFontCache* fontCache,
|
| - SkGlyphCache* cache, const SkPaint& skPaint,
|
| + const SkSurfaceProps& props, const SkPaint& skPaint,
|
| GrColor color,
|
| const SkMatrix& viewMatrix,
|
| const char text[], size_t byteLength,
|
| @@ -38,6 +38,7 @@
|
| GrBatchTextStrike* currStrike = nullptr;
|
|
|
| // Get GrFontScaler from cache
|
| + SkGlyphCache* cache = blob->setupCache(runIndex, props, skPaint, &viewMatrix, false);
|
| GrFontScaler* fontScaler = GrTextContext::GetGrFontScaler(cache);
|
|
|
| SkFindAndPlaceGlyph::ProcessText(
|
| @@ -52,11 +53,13 @@
|
| color, fontScaler);
|
| }
|
| );
|
| +
|
| + SkGlyphCache::AttachCache(cache);
|
| }
|
|
|
| void GrTextUtils::DrawBmpPosText(GrAtlasTextBlob* blob, int runIndex,
|
| GrBatchFontCache* fontCache,
|
| - SkGlyphCache* cache, const SkPaint& skPaint,
|
| + const SkSurfaceProps& props, const SkPaint& skPaint,
|
| GrColor color,
|
| const SkMatrix& viewMatrix,
|
| const char text[], size_t byteLength,
|
| @@ -73,6 +76,7 @@
|
| GrBatchTextStrike* currStrike = nullptr;
|
|
|
| // Get GrFontScaler from cache
|
| + SkGlyphCache* cache = blob->setupCache(runIndex, props, skPaint, &viewMatrix, false);
|
| GrFontScaler* fontScaler = GrTextContext::GetGrFontScaler(cache);
|
|
|
| SkFindAndPlaceGlyph::ProcessPosText(
|
| @@ -87,6 +91,8 @@
|
| color, fontScaler);
|
| }
|
| );
|
| +
|
| + SkGlyphCache::AttachCache(cache);
|
| }
|
|
|
| void GrTextUtils::BmpAppendGlyph(GrAtlasTextBlob* blob, int runIndex,
|
|
|