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

Unified Diff: src/gpu/GrTextStrike.h

Issue 177463003: New approach for GPU font atlas (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Remove unnecessary reference to GrAtlasMgr Created 6 years, 10 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 | « src/gpu/GrDistanceFieldTextContext.cpp ('k') | src/gpu/GrTextStrike.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrTextStrike.h
diff --git a/src/gpu/GrTextStrike.h b/src/gpu/GrTextStrike.h
index 17dcec618c500964abbdaed0a62e09bee7f85ee4..784ea91544d49bc3ff6f0e0b6d9fae8071c38929 100644
--- a/src/gpu/GrTextStrike.h
+++ b/src/gpu/GrTextStrike.h
@@ -37,7 +37,7 @@ public:
GrMaskFormat getMaskFormat() const { return fMaskFormat; }
inline GrGlyph* getGlyph(GrGlyph::PackedID, GrFontScaler*);
- bool getGlyphAtlas(GrGlyph*, GrFontScaler*);
+ bool addGlyphToAtlas(GrGlyph*, GrFontScaler*);
SkISize getAtlasSize() const { return fAtlas.getSize(); }
@@ -47,11 +47,11 @@ public:
return fCache.getArray()[index];
}
- // returns true if a plot was removed
- bool removeUnusedPlots();
+ // remove any references to this plot
+ void removePlot(const GrPlot* plot);
public:
- // for LRU
+ // for easy removal from list
GrTextStrike* fPrev;
GrTextStrike* fNext;
@@ -88,10 +88,8 @@ public:
void freeAll();
- void purgeExceptFor(GrTextStrike*);
-
- // remove an unused plot and its strike (if necessary)
- void freePlotExceptFor(GrTextStrike*);
+ // make an unused plot available
+ bool freeUnusedPlot(GrTextStrike* preserveStrike);
// testing
int countStrikes() const { return fCache.getArray().count(); }
« no previous file with comments | « src/gpu/GrDistanceFieldTextContext.cpp ('k') | src/gpu/GrTextStrike.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698