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 <set> | 7 #include <set> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/string_util.h" | 10 #include "base/string_util.h" |
(...skipping 520 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
531 } | 531 } |
532 } | 532 } |
533 | 533 |
534 // Check for multisample support | 534 // Check for multisample support |
535 bool ext_has_multisample = | 535 bool ext_has_multisample = |
536 extensions.Contains("GL_EXT_framebuffer_multisample"); | 536 extensions.Contains("GL_EXT_framebuffer_multisample"); |
537 if (!is_qualcomm && !workarounds_.disable_angle_framebuffer_multisample) { | 537 if (!is_qualcomm && !workarounds_.disable_angle_framebuffer_multisample) { |
538 ext_has_multisample |= | 538 ext_has_multisample |= |
539 extensions.Contains("GL_ANGLE_framebuffer_multisample"); | 539 extensions.Contains("GL_ANGLE_framebuffer_multisample"); |
540 } | 540 } |
541 if (!disallowed_features_.multisampling && ext_has_multisample) { | 541 if (ext_has_multisample) { |
542 feature_flags_.chromium_framebuffer_multisample = true; | 542 feature_flags_.chromium_framebuffer_multisample = true; |
543 validators_.frame_buffer_target.AddValue(GL_READ_FRAMEBUFFER_EXT); | 543 validators_.frame_buffer_target.AddValue(GL_READ_FRAMEBUFFER_EXT); |
544 validators_.frame_buffer_target.AddValue(GL_DRAW_FRAMEBUFFER_EXT); | 544 validators_.frame_buffer_target.AddValue(GL_DRAW_FRAMEBUFFER_EXT); |
545 validators_.g_l_state.AddValue(GL_READ_FRAMEBUFFER_BINDING_EXT); | 545 validators_.g_l_state.AddValue(GL_READ_FRAMEBUFFER_BINDING_EXT); |
546 validators_.g_l_state.AddValue(GL_MAX_SAMPLES_EXT); | 546 validators_.g_l_state.AddValue(GL_MAX_SAMPLES_EXT); |
547 validators_.render_buffer_parameter.AddValue(GL_RENDERBUFFER_SAMPLES_EXT); | 547 validators_.render_buffer_parameter.AddValue(GL_RENDERBUFFER_SAMPLES_EXT); |
548 AddExtensionString("GL_CHROMIUM_framebuffer_multisample"); | 548 AddExtensionString("GL_CHROMIUM_framebuffer_multisample"); |
549 } | 549 } |
550 | 550 |
551 if (extensions.Contains("GL_OES_depth24") || gfx::HasDesktopGLFeatures()) { | 551 if (extensions.Contains("GL_OES_depth24") || gfx::HasDesktopGLFeatures()) { |
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
721 if (extensions_.find(str) == std::string::npos) { | 721 if (extensions_.find(str) == std::string::npos) { |
722 extensions_ += (extensions_.empty() ? "" : " ") + str; | 722 extensions_ += (extensions_.empty() ? "" : " ") + str; |
723 } | 723 } |
724 } | 724 } |
725 | 725 |
726 FeatureInfo::~FeatureInfo() { | 726 FeatureInfo::~FeatureInfo() { |
727 } | 727 } |
728 | 728 |
729 } // namespace gles2 | 729 } // namespace gles2 |
730 } // namespace gpu | 730 } // namespace gpu |
OLD | NEW |