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

Unified Diff: src/gpu/GrTextStrike.h

Issue 24981004: GrAtlas cleanup: Split out GrPlot and GrAtlas (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Tweaked comment Created 7 years, 3 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/GrTextContext.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 66bbb0d93c846bcfcac458023f717269c40ed545..2f52d987040839f1f079e92d8f86818d99674d70 100644
--- a/src/gpu/GrTextStrike.h
+++ b/src/gpu/GrTextStrike.h
@@ -17,8 +17,8 @@
#include "GrPoint.h"
#include "GrGlyph.h"
#include "GrDrawTarget.h"
+#include "GrAtlas.h"
-class GrAtlasMgr;
class GrFontCache;
class GrGpu;
class GrFontPurgeListener;
@@ -45,10 +45,9 @@ public:
const GrGlyph* glyphAt(int index) const {
return fCache.getArray()[index];
}
- GrAtlas* getAtlas() const { return fAtlas; }
- // returns true if an atlas was removed
- bool removeUnusedAtlases();
+ // returns true if a plot was removed
+ bool removeUnusedPlots();
public:
// for LRU
@@ -63,13 +62,11 @@ private:
GrFontCache* fFontCache;
GrAtlasMgr* fAtlasMgr;
- GrAtlas* fAtlas; // linklist
+ GrAtlas fAtlas;
GrMaskFormat fMaskFormat;
GrGlyph* generateGlyph(GrGlyph::PackedID packed, GrFontScaler* scaler);
- // returns true if after the purge, the strike is empty
- bool purgeAtlasAtY(GrAtlas* atlas, int yCoord);
friend class GrFontCache;
};
@@ -85,8 +82,8 @@ public:
void purgeExceptFor(GrTextStrike*);
- // remove an unused atlas and its strike (if necessary)
- void freeAtlasExceptFor(GrTextStrike*);
+ // remove an unused plot and its strike (if necessary)
+ void freePlotExceptFor(GrTextStrike*);
// testing
int countStrikes() const { return fCache.getArray().count(); }
@@ -113,7 +110,6 @@ private:
GrGpu* fGpu;
GrAtlasMgr* fAtlasMgr[kMaskFormatCount];
-
GrTextStrike* generateStrike(GrFontScaler*, const Key&);
inline void detachStrikeFromList(GrTextStrike*);
};
« no previous file with comments | « src/gpu/GrTextContext.cpp ('k') | src/gpu/GrTextStrike.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698