Remove some redundant fields from BitmapTextBatch (and rename to TextBatch).
Review URL: https://codereview.chromium.org/1244093004
diff --git a/src/gpu/GrBatchFontCache.cpp b/src/gpu/GrBatchFontCache.cpp
index aa05260..6ffcdcf 100644
--- a/src/gpu/GrBatchFontCache.cpp
+++ b/src/gpu/GrBatchFontCache.cpp
@@ -39,7 +39,7 @@
bool GrBatchFontCache::initAtlas(GrMaskFormat format) {
int index = MaskFormatToAtlasIndex(format);
if (!fAtlases[index]) {
- GrPixelConfig config = this->getPixelConfig(format);
+ GrPixelConfig config = MaskFormatToPixelConfig(format);
if (kA8_GrMaskFormat == format) {
fAtlases[index] = make_atlas(fContext, config,
GR_FONT_ATLAS_A8_TEXTURE_WIDTH,
@@ -99,17 +99,6 @@
}
}
-GrPixelConfig GrBatchFontCache::getPixelConfig(GrMaskFormat format) const {
- static const GrPixelConfig kPixelConfigs[] = {
- kAlpha_8_GrPixelConfig,
- kRGB_565_GrPixelConfig,
- kSkia8888_GrPixelConfig
- };
- SK_COMPILE_ASSERT(SK_ARRAY_COUNT(kPixelConfigs) == kMaskFormatCount, array_size_mismatch);
-
- return kPixelConfigs[format];
-}
-
void GrBatchFontCache::HandleEviction(GrBatchAtlas::AtlasID id, void* ptr) {
GrBatchFontCache* fontCache = reinterpret_cast<GrBatchFontCache*>(ptr);