Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(435)

Unified Diff: src/gpu/GrAtlasTextContext.cpp

Issue 1076853002: fix for perf regression on ugamsolutions / msaa16 (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: nit Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/gpu/GrBatchFontCache.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrAtlasTextContext.cpp
diff --git a/src/gpu/GrAtlasTextContext.cpp b/src/gpu/GrAtlasTextContext.cpp
index d6bb3e079712ecb27c9996786cf741e228a197dc..8c89f2b53ef5d3f6d46fcae60051da768b2ddf91 100644
--- a/src/gpu/GrAtlasTextContext.cpp
+++ b/src/gpu/GrAtlasTextContext.cpp
@@ -701,13 +701,19 @@ public:
return;
}
+ GrTexture* texture = fFontCache->getTexture(fMaskFormat);
+ if (!texture) {
+ SkDebugf("Could not allocate backing texture for atlas\n");
+ return;
+ }
+
GrTextureParams params(SkShader::kClamp_TileMode, GrTextureParams::kNone_FilterMode);
// This will be ignored in the non A8 case
bool opaqueVertexColors = GrColorIsOpaque(this->color());
SkAutoTUnref<const GrGeometryProcessor> gp(
GrBitmapTextGeoProc::Create(this->color(),
- fFontCache->getTexture(fMaskFormat),
+ texture,
params,
fMaskFormat,
opaqueVertexColors,
« no previous file with comments | « no previous file | src/gpu/GrBatchFontCache.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698