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

Side by Side Diff: gpu/command_buffer/service/gles2_cmd_decoder.cc

Issue 2446773002: Always use Desktop GL 4.1 or less BindBufferRange behavior. (Closed)
Patch Set: fix comments Created 4 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « no previous file | gpu/command_buffer/service/gles2_cmd_decoder_unittest_buffers.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" 5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h"
6 6
7 #include <limits.h> 7 #include <limits.h>
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 #include <stdio.h> 10 #include <stdio.h>
(...skipping 3085 matching lines...) Expand 10 before | Expand all | Expand 10 after
3096 break; 3096 break;
3097 } 3097 }
3098 } 3098 }
3099 3099
3100 if (!supported) { 3100 if (!supported) {
3101 Destroy(true); 3101 Destroy(true);
3102 return false; 3102 return false;
3103 } 3103 }
3104 } 3104 }
3105 3105
3106 bool needs_emulation = gl_version_info().IsLowerThanGL(4, 2); 3106 // In theory |needs_emulation| needs to be true on Desktop GL 4.1 or lower.
3107 // However, we set it to true everywhere, not to trust drivers to handle
3108 // out-of-bounds buffer accesses.
3109 bool needs_emulation = true;
3107 transform_feedback_manager_.reset(new TransformFeedbackManager( 3110 transform_feedback_manager_.reset(new TransformFeedbackManager(
3108 group_->max_transform_feedback_separate_attribs(), needs_emulation)); 3111 group_->max_transform_feedback_separate_attribs(), needs_emulation));
3109 3112
3110 if (feature_info_->IsWebGL2OrES3Context()) { 3113 if (feature_info_->IsWebGL2OrES3Context()) {
3111 if (!feature_info_->IsES3Capable()) { 3114 if (!feature_info_->IsES3Capable()) {
3112 LOG(ERROR) << "Underlying driver does not support ES3."; 3115 LOG(ERROR) << "Underlying driver does not support ES3.";
3113 Destroy(true); 3116 Destroy(true);
3114 return false; 3117 return false;
3115 } 3118 }
3116 feature_info_->EnableES3Validators(); 3119 feature_info_->EnableES3Validators();
(...skipping 15548 matching lines...) Expand 10 before | Expand all | Expand 10 after
18665 } 18668 }
18666 18669
18667 // Include the auto-generated part of this file. We split this because it means 18670 // Include the auto-generated part of this file. We split this because it means
18668 // we can easily edit the non-auto generated parts right here in this file 18671 // we can easily edit the non-auto generated parts right here in this file
18669 // instead of having to edit some template or the code generator. 18672 // instead of having to edit some template or the code generator.
18670 #include "base/macros.h" 18673 #include "base/macros.h"
18671 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" 18674 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h"
18672 18675
18673 } // namespace gles2 18676 } // namespace gles2
18674 } // namespace gpu 18677 } // namespace gpu
OLDNEW
« no previous file with comments | « no previous file | gpu/command_buffer/service/gles2_cmd_decoder_unittest_buffers.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698