diff options
author | 2015-12-28 07:14:52 -0800 | |
---|---|---|
committer | 2015-12-28 07:14:52 -0800 | |
commit | 90e293dae4990a86cb952663ccde8fae55112d7d (patch) | |
tree | c205b1cf7dc5f0579bf93c382f97df909b57a26e /src/gpu/text/GrTextUtils.cpp | |
parent | 9a878a00ef2c2eb72628c807be5969e2d8098317 (diff) |
Revert of Make draw* lines responsible for cache management (patchset #1 id:1 of https://codereview.chromium.org/1521613002/ )
Reason for revert:
seeing crashes on android and linux
Original issue's description:
> Make draw* lines responsible for cache management
>
> TBR=bsalomon@google.com
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/66957946c0c418e71c0f36bb2904cc38c334eba4
TBR=bsalomon@google.com,jvanverth@google.com,joshualitt@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:
Review URL: https://codereview.chromium.org/1552513003
Diffstat (limited to 'src/gpu/text/GrTextUtils.cpp')
-rw-r--r-- | src/gpu/text/GrTextUtils.cpp | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/src/gpu/text/GrTextUtils.cpp b/src/gpu/text/GrTextUtils.cpp index 9d6bb2c857..293ea4d891 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, - const SkSurfaceProps& props, const SkPaint& skPaint, + SkGlyphCache* cache, const SkPaint& skPaint, GrColor color, const SkMatrix& viewMatrix, const char text[], size_t byteLength, @@ -38,7 +38,6 @@ void GrTextUtils::DrawBmpText(GrAtlasTextBlob* blob, int runIndex, GrBatchTextStrike* currStrike = nullptr; // Get GrFontScaler from cache - SkGlyphCache* cache = blob->setupCache(runIndex, props, skPaint, &viewMatrix, false); GrFontScaler* fontScaler = GrTextContext::GetGrFontScaler(cache); SkFindAndPlaceGlyph::ProcessText( @@ -53,13 +52,11 @@ void GrTextUtils::DrawBmpText(GrAtlasTextBlob* blob, int runIndex, color, fontScaler); } ); - - SkGlyphCache::AttachCache(cache); } void GrTextUtils::DrawBmpPosText(GrAtlasTextBlob* blob, int runIndex, GrBatchFontCache* fontCache, - const SkSurfaceProps& props, const SkPaint& skPaint, + SkGlyphCache* cache, const SkPaint& skPaint, GrColor color, const SkMatrix& viewMatrix, const char text[], size_t byteLength, @@ -76,7 +73,6 @@ void GrTextUtils::DrawBmpPosText(GrAtlasTextBlob* blob, int runIndex, GrBatchTextStrike* currStrike = nullptr; // Get GrFontScaler from cache - SkGlyphCache* cache = blob->setupCache(runIndex, props, skPaint, &viewMatrix, false); GrFontScaler* fontScaler = GrTextContext::GetGrFontScaler(cache); SkFindAndPlaceGlyph::ProcessPosText( @@ -91,8 +87,6 @@ void GrTextUtils::DrawBmpPosText(GrAtlasTextBlob* blob, int runIndex, color, fontScaler); } ); - - SkGlyphCache::AttachCache(cache); } void GrTextUtils::BmpAppendGlyph(GrAtlasTextBlob* blob, int runIndex, |