Calculate numPlotsY from height

Add a compensating change to make A8 plot
size 512x512.

Change-Id: Iaca4327d07c629143ec7dfb9e294b8fed4b8135a
Reviewed-on: https://skia-review.googlesource.com/152420
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Herb Derby <herb@google.com>
This commit is contained in:
Herb Derby 2018-09-06 14:50:22 -04:00 committed by Skia Commit-Bot
parent fc9624cb84
commit 307d6fd4b8
2 changed files with 2 additions and 2 deletions

View File

@ -19,7 +19,7 @@ class GrRectanizer;
struct GrDrawOpAtlasConfig {
int numPlotsX() const { return fWidth / fPlotWidth; }
int numPlotsY() const { return fHeight / fPlotWidth; }
int numPlotsY() const { return fHeight / fPlotHeight; }
int fWidth;
int fHeight;
int fPlotWidth;

View File

@ -52,7 +52,7 @@ GrAtlasManager::GrAtlasManager(GrProxyProvider* proxyProvider, GrGlyphCache* gly
fAtlasConfigs[kA8_GrMaskFormat].fWidth = maxDim;
fAtlasConfigs[kA8_GrMaskFormat].fHeight = maxDim;
fAtlasConfigs[kA8_GrMaskFormat].fPlotWidth = maxPlot;
fAtlasConfigs[kA8_GrMaskFormat].fPlotHeight = minPlot;
fAtlasConfigs[kA8_GrMaskFormat].fPlotHeight = maxPlot;
// A565 and ARGB use maxDim x minDim.
fAtlasConfigs[kA565_GrMaskFormat].fWidth = minDim;