Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1285)

Unified Diff: gpu/command_buffer/service/gles2_cmd_decoder.cc

Issue 640283003: Use NV_draw_buffers to implement EXT_draw_buffers (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkgr
Patch Set: Added explanation of nv_draw_buffers flag to feature_info.cc Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gpu/command_buffer/service/feature_info_unittest.cc ('k') | gpu/command_buffer/service/test_helper.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gpu/command_buffer/service/gles2_cmd_decoder.cc
diff --git a/gpu/command_buffer/service/gles2_cmd_decoder.cc b/gpu/command_buffer/service/gles2_cmd_decoder.cc
index 65587ec03277791f3eaee02dacf077f0eb9a5a74..a6152956a58734f48b8fc5f0e58fc399be0f4aa7 100644
--- a/gpu/command_buffer/service/gles2_cmd_decoder.cc
+++ b/gpu/command_buffer/service/gles2_cmd_decoder.cc
@@ -2792,6 +2792,8 @@ bool GLES2DecoderImpl::InitializeShaderTranslator() {
if (!draw_buffers_explicitly_enabled_)
resources.MaxDrawBuffers = 1;
resources.EXT_shader_texture_lod = shader_texture_lod_explicitly_enabled_;
+ resources.NV_draw_buffers =
+ draw_buffers_explicitly_enabled_ && features().nv_draw_buffers;
} else {
resources.OES_standard_derivatives =
features().oes_standard_derivatives ? 1 : 0;
@@ -2805,6 +2807,8 @@ bool GLES2DecoderImpl::InitializeShaderTranslator() {
features().ext_frag_depth ? 1 : 0;
resources.EXT_shader_texture_lod =
features().ext_shader_texture_lod ? 1 : 0;
+ resources.NV_draw_buffers =
+ features().nv_draw_buffers ? 1 : 0;
}
ShShaderSpec shader_spec = force_webgl_glsl_validation_ ? SH_WEBGL_SPEC
« no previous file with comments | « gpu/command_buffer/service/feature_info_unittest.cc ('k') | gpu/command_buffer/service/test_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698