| 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 f76c085eb35b97d269bc5549fb29b0996e1b7a48..28c1e0f0c2d865043ad09ccf754650e360148749 100644
|
| --- a/gpu/command_buffer/service/gles2_cmd_decoder.cc
|
| +++ b/gpu/command_buffer/service/gles2_cmd_decoder.cc
|
| @@ -2474,14 +2474,6 @@ bool GLES2DecoderImpl::Initialize(
|
| set_log_commands(true);
|
| }
|
|
|
| - if (base::CommandLine::ForCurrentProcess()->HasSwitch(
|
| - switches::kEnableUnsafeES3APIs) &&
|
| - attrib_parser.es3_context_required) {
|
| - // TODO(zmo): We need to implement capabilities check to ensure we can
|
| - // actually create ES3 contexts.
|
| - set_unsafe_es3_apis_enabled(true);
|
| - }
|
| -
|
| compile_shader_always_succeeds_ =
|
| base::CommandLine::ForCurrentProcess()->HasSwitch(
|
| switches::kCompileShaderAlwaysSucceeds);
|
| @@ -2516,6 +2508,14 @@ bool GLES2DecoderImpl::Initialize(
|
| }
|
| CHECK_GL_ERROR();
|
|
|
| + if (base::CommandLine::ForCurrentProcess()->HasSwitch(
|
| + switches::kEnableUnsafeES3APIs) &&
|
| + attrib_parser.es3_context_required &&
|
| + feature_info_->IsES3Capable()) {
|
| + feature_info_->EnableES3Validators();
|
| + set_unsafe_es3_apis_enabled(true);
|
| + }
|
| +
|
| disallowed_features_ = disallowed_features;
|
|
|
| state_.attrib_values.resize(group_->max_vertex_attribs());
|
|
|