| OLD | NEW |
| 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/feature_info.h" | 5 #include "gpu/command_buffer/service/feature_info.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <set> | 9 #include <set> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 1302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1313 feature_flags_.emulate_primitive_restart_fixed_index = true; | 1313 feature_flags_.emulate_primitive_restart_fixed_index = true; |
| 1314 } | 1314 } |
| 1315 } | 1315 } |
| 1316 | 1316 |
| 1317 bool FeatureInfo::IsES3Capable() const { | 1317 bool FeatureInfo::IsES3Capable() const { |
| 1318 if (!enable_unsafe_es3_apis_switch_) | 1318 if (!enable_unsafe_es3_apis_switch_) |
| 1319 return false; | 1319 return false; |
| 1320 if (workarounds_.disable_texture_storage) | 1320 if (workarounds_.disable_texture_storage) |
| 1321 return false; | 1321 return false; |
| 1322 if (gl_version_info_) | 1322 if (gl_version_info_) |
| 1323 return gl_version_info_->IsES3Capable(); | 1323 return gl_version_info_->is_es3_capable; |
| 1324 return false; | 1324 return false; |
| 1325 } | 1325 } |
| 1326 | 1326 |
| 1327 void FeatureInfo::EnableES3Validators() { | 1327 void FeatureInfo::EnableES3Validators() { |
| 1328 DCHECK(IsES3Capable()); | 1328 DCHECK(IsES3Capable()); |
| 1329 validators_.UpdateValuesES3(); | 1329 validators_.UpdateValuesES3(); |
| 1330 | 1330 |
| 1331 GLint max_color_attachments = 0; | 1331 GLint max_color_attachments = 0; |
| 1332 glGetIntegerv(GL_MAX_COLOR_ATTACHMENTS, &max_color_attachments); | 1332 glGetIntegerv(GL_MAX_COLOR_ATTACHMENTS, &max_color_attachments); |
| 1333 const int kTotalColorAttachmentEnums = 16; | 1333 const int kTotalColorAttachmentEnums = 16; |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1415 if (pos == std::string::npos) { | 1415 if (pos == std::string::npos) { |
| 1416 extensions_ += (extensions_.empty() ? "" : " ") + str; | 1416 extensions_ += (extensions_.empty() ? "" : " ") + str; |
| 1417 } | 1417 } |
| 1418 } | 1418 } |
| 1419 | 1419 |
| 1420 FeatureInfo::~FeatureInfo() { | 1420 FeatureInfo::~FeatureInfo() { |
| 1421 } | 1421 } |
| 1422 | 1422 |
| 1423 } // namespace gles2 | 1423 } // namespace gles2 |
| 1424 } // namespace gpu | 1424 } // namespace gpu |
| OLD | NEW |