Chromium Code Reviews| Index: gpu/command_buffer/service/feature_info.cc |
| diff --git a/gpu/command_buffer/service/feature_info.cc b/gpu/command_buffer/service/feature_info.cc |
| index 77000c5037eee2a85806b6bb6250b366d81f2f26..baef762db9ebe83d7824e812f36c540e6f2443ba 100644 |
| --- a/gpu/command_buffer/service/feature_info.cc |
| +++ b/gpu/command_buffer/service/feature_info.cc |
| @@ -599,6 +599,17 @@ void FeatureInfo::InitializeFeatures() { |
| GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING_EXT); |
| validators_.texture_unsized_internal_format.AddValue(GL_SRGB_EXT); |
| validators_.texture_unsized_internal_format.AddValue(GL_SRGB_ALPHA_EXT); |
| + |
| + // GL_FRAMEBUFFER_SRGB_EXT is exposed by the GLES extension |
| + // GL_EXT_sRGB_write_control (which is not part of the core, even in GLES3), |
| + // and the desktop extension GL_ARB_framebuffer_sRGB (part of the core in |
| + // 3.0). |
| + if (feature_flags_.desktop_srgb_support || |
| + extensions.Contains("GL_EXT_sRGB_write_control")) { |
|
Zhenyao Mo
2016/11/30 19:31:11
Don't does this if IsWebGLContext(). Otherwise you
ccameron
2016/11/30 23:59:44
Updated to track if we support srgb framebuffers,
|
| + feature_flags_.ext_srgb_write_control = true; |
| + AddExtensionString("GL_EXT_sRGB_write_control"); |
| + validators_.capability.AddValue(GL_FRAMEBUFFER_SRGB_EXT); |
| + } |
| } |
| // On desktop, GL_EXT_texture_sRGB is required regardless of GL version, |