diff options
Diffstat (limited to 'src/gpu/GrTextContext.cpp')
-rw-r--r-- | src/gpu/GrTextContext.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/gpu/GrTextContext.cpp b/src/gpu/GrTextContext.cpp index c245401d9a..e97bc8f3a2 100644 --- a/src/gpu/GrTextContext.cpp +++ b/src/gpu/GrTextContext.cpp @@ -221,11 +221,12 @@ void GrTextContext::drawPackedGlyph(GrGlyph::PackedID packed, glyph->fPath = path; } - GrPoint translate; - translate.set(GrFixedToScalar(vx - GrIntToFixed(glyph->fBounds.fLeft)), - GrFixedToScalar(vy - GrIntToFixed(glyph->fBounds.fTop))); - fContext->drawPath(fPaint, *glyph->fPath, kWinding_GrPathFill, - &translate); + GrContext::AutoMatrix am(fContext, GrContext::AutoMatrix::kPreserve_InitialMatrix); + GrMatrix translate; + translate.setTranslate(GrFixedToScalar(vx - GrIntToFixed(glyph->fBounds.fLeft)), + GrFixedToScalar(vy - GrIntToFixed(glyph->fBounds.fTop))); + fContext->concatMatrix(translate); + fContext->drawPath(fPaint, *glyph->fPath, kWinding_GrPathFill); return; } |