Index: src/gpu/GrBitmapTextContext.cpp |
diff --git a/src/gpu/GrBitmapTextContext.cpp b/src/gpu/GrBitmapTextContext.cpp |
index 9ef8da254ac11708739db23f4d14787ce7904721..421051752615c4f32f89281262bff40b69b69777 100755 |
--- a/src/gpu/GrBitmapTextContext.cpp |
+++ b/src/gpu/GrBitmapTextContext.cpp |
@@ -454,30 +454,32 @@ void GrBitmapTextContext::drawPackedGlyph(GrGlyph::PackedID packed, |
} |
if (NULL == glyph->fPlot) { |
- if (fStrike->addGlyphToAtlas(glyph, scaler)) { |
- goto HAS_ATLAS; |
- } |
+ if (!fStrike->glyphTooLargeForAtlas(glyph)) { |
+ if (fStrike->addGlyphToAtlas(glyph, scaler)) { |
+ goto HAS_ATLAS; |
+ } |
- // try to clear out an unused plot before we flush |
- if (fContext->getFontCache()->freeUnusedPlot(fStrike) && |
- fStrike->addGlyphToAtlas(glyph, scaler)) { |
- goto HAS_ATLAS; |
- } |
+ // try to clear out an unused plot before we flush |
+ if (fContext->getFontCache()->freeUnusedPlot(fStrike) && |
+ fStrike->addGlyphToAtlas(glyph, scaler)) { |
+ goto HAS_ATLAS; |
+ } |
- if (c_DumpFontCache) { |
+ if (c_DumpFontCache) { |
#ifdef SK_DEVELOPER |
- fContext->getFontCache()->dump(); |
+ fContext->getFontCache()->dump(); |
#endif |
- } |
+ } |
- // flush any accumulated draws to allow us to free up a plot |
- this->flushGlyphs(); |
- fContext->flush(); |
+ // flush any accumulated draws to allow us to free up a plot |
+ this->flushGlyphs(); |
+ fContext->flush(); |
- // we should have an unused plot now |
- if (fContext->getFontCache()->freeUnusedPlot(fStrike) && |
- fStrike->addGlyphToAtlas(glyph, scaler)) { |
- goto HAS_ATLAS; |
+ // we should have an unused plot now |
+ if (fContext->getFontCache()->freeUnusedPlot(fStrike) && |
+ fStrike->addGlyphToAtlas(glyph, scaler)) { |
+ goto HAS_ATLAS; |
+ } |
} |
if (NULL == glyph->fPath) { |