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 e4ae9c5111dee212cb1327ca2c94081b9ab4fe40..1967b2846795334ecfca6185ede0096f76c50c66 100644 |
| --- a/gpu/command_buffer/service/feature_info.cc |
| +++ b/gpu/command_buffer/service/feature_info.cc |
| @@ -143,7 +143,8 @@ FeatureInfo::FeatureFlags::FeatureFlags() |
| angle_texture_usage(false), |
| ext_texture_storage(false), |
| chromium_path_rendering(false), |
| - ext_blend_minmax(false) { |
| + ext_blend_minmax(false), |
| + blend_equation_advanced(false) { |
| } |
| FeatureInfo::Workarounds::Workarounds() : |
| @@ -852,6 +853,41 @@ void FeatureInfo::InitializeFeatures() { |
| feature_flags_.chromium_sync_query = true; |
| } |
| + bool blend_equation_advanced_coherent = |
| + extensions.Contains("GL_NV_blend_equation_advanced_coherent") || |
| + extensions.Contains("GL_KHR_blend_equation_advanced_coherent"); |
| + |
| + if (blend_equation_advanced_coherent || |
| + extensions.Contains("GL_NV_blend_equation_advanced") || |
| + extensions.Contains("GL_KHR_blend_equation_advanced")) { |
| + const GLenum equations[] = {GL_MULTIPLY_KHR, |
| + GL_SCREEN_KHR, |
| + GL_OVERLAY_KHR, |
| + GL_DARKEN_KHR, |
| + GL_LIGHTEN_KHR, |
| + GL_COLORDODGE_KHR, |
| + GL_COLORBURN_KHR, |
| + GL_HARDLIGHT_KHR, |
| + GL_SOFTLIGHT_KHR, |
| + GL_DIFFERENCE_KHR, |
| + GL_EXCLUSION_KHR, |
| + GL_HSL_HUE_KHR, |
| + GL_HSL_SATURATION_KHR, |
| + GL_HSL_COLOR_KHR, |
| + GL_HSL_LUMINOSITY_KHR}; |
| + |
| + for (GLenum equation : equations) |
| + validators_.equation.AddValue(equation); |
| + if (blend_equation_advanced_coherent) |
| + AddExtensionString("GL_KHR_blend_equation_advanced_coherent"); |
|
piman
2014/10/17 21:36:29
nit: indent wrong (should be +2)
Erik Dahlström (inactive)
2014/10/20 15:32:21
Done.
|
| + else |
| + AddExtensionString("GL_KHR_blend_equation_advanced"); |
|
piman
2014/10/17 21:36:29
We should add this one either way.
Erik Dahlström (inactive)
2014/10/20 15:32:21
Done.
|
| + |
| + feature_flags_.blend_equation_advanced = true; |
| + feature_flags_.blend_equation_advanced_coherent = |
| + blend_equation_advanced_coherent; |
| + } |
| + |
| if (extensions.Contains("GL_NV_path_rendering")) { |
| if (extensions.Contains("GL_EXT_direct_state_access") || is_es3) { |
| AddExtensionString("GL_CHROMIUM_path_rendering"); |