Skip the sRGB mip-map testing on command buffer
Chromium command buffer now has the sRGB decode extension, but it doesn't
make any guarantees about the interaction with glGenerateMipmap.
BUG=skia:
Review-Url: https://codereview.chromium.org/2557603006
diff --git a/src/gpu/gl/GrGLCaps.cpp b/src/gpu/gl/GrGLCaps.cpp
index 168acde..5a0864e 100644
--- a/src/gpu/gl/GrGLCaps.cpp
+++ b/src/gpu/gl/GrGLCaps.cpp
@@ -52,6 +52,7 @@
fRGBAToBGRAReadbackConversionsAreSlow = false;
fDoManualMipmapping = false;
fSRGBDecodeDisableSupport = false;
+ fSRGBDecodeDisableAffectsMipmaps = false;
fBlitFramebufferFlags = kNoSupport_BlitFramebufferFlag;
@@ -609,6 +610,8 @@
}
fSRGBDecodeDisableSupport = ctxInfo.hasExtension("GL_EXT_texture_sRGB_decode");
+ fSRGBDecodeDisableAffectsMipmaps = fSRGBDecodeDisableSupport &&
+ kChromium_GrGLDriver != ctxInfo.driver();
// Requires fTextureRedSupport, fTextureSwizzleSupport, msaa support, ES compatibility have
// already been detected.