Index: src/gpu/GrCaps.cpp |
diff --git a/src/gpu/GrCaps.cpp b/src/gpu/GrCaps.cpp |
index 19ef38c49d244fe226e47e3232fe5457ed1e8f29..622c6855fae0ad93e29fd05c4fc6c62a0b65df45 100644 |
--- a/src/gpu/GrCaps.cpp |
+++ b/src/gpu/GrCaps.cpp |
@@ -7,6 +7,7 @@ |
#include "GrCaps.h" |
#include "GrContextOptions.h" |
+#include "GrWindowRectangles.h" |
GrShaderCaps::GrShaderCaps() { |
fShaderDerivativeSupport = false; |
@@ -131,6 +132,7 @@ GrCaps::GrCaps(const GrContextOptions& options) { |
} |
void GrCaps::applyOptionsOverrides(const GrContextOptions& options) { |
+ this->onApplyOptionsOverrides(options); |
fMaxTextureSize = SkTMin(fMaxTextureSize, options.fMaxTextureSizeOverride); |
// If the max tile override is zero, it means we should use the max texture size. |
if (!options.fMaxTileSizeOverride || options.fMaxTileSizeOverride > fMaxTextureSize) { |
@@ -138,7 +140,9 @@ void GrCaps::applyOptionsOverrides(const GrContextOptions& options) { |
} else { |
fMaxTileSize = options.fMaxTileSizeOverride; |
} |
- this->onApplyOptionsOverrides(options); |
+ if (fMaxWindowRectangles > GrWindowRectangles::kMaxWindows) { |
+ fMaxWindowRectangles = GrWindowRectangles::kMaxWindows; |
csmartdalton
2016/08/17 18:24:06
We still cap. The cap just got moved here instead.
|
+ } |
} |
static SkString map_flags_to_string(uint32_t flags) { |