| 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 #ifndef GPU_COMMAND_BUFFER_SERVICE_FEATURE_INFO_H_ | 5 #ifndef GPU_COMMAND_BUFFER_SERVICE_FEATURE_INFO_H_ |
| 6 #define GPU_COMMAND_BUFFER_SERVICE_FEATURE_INFO_H_ | 6 #define GPU_COMMAND_BUFFER_SERVICE_FEATURE_INFO_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/macros.h" | 11 #include "base/macros.h" |
| 12 #include "base/memory/ref_counted.h" | 12 #include "base/memory/ref_counted.h" |
| 13 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" | 13 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" |
| 14 #include "gpu/command_buffer/service/gles2_cmd_validation.h" | 14 #include "gpu/command_buffer/service/gles2_cmd_validation.h" |
| 15 #include "gpu/config/gpu_driver_bug_workarounds.h" | 15 #include "gpu/config/gpu_driver_bug_workarounds.h" |
| 16 #include "gpu/gpu_export.h" | 16 #include "gpu/gpu_export.h" |
| 17 | 17 |
| 18 namespace base { | 18 namespace base { |
| 19 class CommandLine; | 19 class CommandLine; |
| 20 } | 20 } |
| 21 | 21 |
| 22 namespace gfx { | 22 namespace gl { |
| 23 struct GLVersionInfo; | 23 struct GLVersionInfo; |
| 24 } | 24 } |
| 25 | 25 |
| 26 namespace gpu { | 26 namespace gpu { |
| 27 namespace gles2 { | 27 namespace gles2 { |
| 28 | 28 |
| 29 // FeatureInfo records the features that are available for a ContextGroup. | 29 // FeatureInfo records the features that are available for a ContextGroup. |
| 30 class GPU_EXPORT FeatureInfo : public base::RefCounted<FeatureInfo> { | 30 class GPU_EXPORT FeatureInfo : public base::RefCounted<FeatureInfo> { |
| 31 public: | 31 public: |
| 32 struct FeatureFlags { | 32 struct FeatureFlags { |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 123 const FeatureFlags& feature_flags() const { | 123 const FeatureFlags& feature_flags() const { |
| 124 return feature_flags_; | 124 return feature_flags_; |
| 125 } | 125 } |
| 126 | 126 |
| 127 const GpuDriverBugWorkarounds& workarounds() const { return workarounds_; } | 127 const GpuDriverBugWorkarounds& workarounds() const { return workarounds_; } |
| 128 | 128 |
| 129 const DisallowedFeatures& disallowed_features() const { | 129 const DisallowedFeatures& disallowed_features() const { |
| 130 return disallowed_features_; | 130 return disallowed_features_; |
| 131 } | 131 } |
| 132 | 132 |
| 133 const gfx::GLVersionInfo& gl_version_info() const { | 133 const gl::GLVersionInfo& gl_version_info() const { |
| 134 DCHECK(gl_version_info_.get()); | 134 DCHECK(gl_version_info_.get()); |
| 135 return *(gl_version_info_.get()); | 135 return *(gl_version_info_.get()); |
| 136 } | 136 } |
| 137 | 137 |
| 138 bool IsES3Capable() const; | 138 bool IsES3Capable() const; |
| 139 void EnableES3Validators(); | 139 void EnableES3Validators(); |
| 140 | 140 |
| 141 bool IsES3Enabled() const { | 141 bool IsES3Enabled() const { |
| 142 return unsafe_es3_apis_enabled_; | 142 return unsafe_es3_apis_enabled_; |
| 143 } | 143 } |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 | 182 |
| 183 bool unsafe_es3_apis_enabled_; | 183 bool unsafe_es3_apis_enabled_; |
| 184 | 184 |
| 185 bool chromium_color_buffer_float_rgba_available_; | 185 bool chromium_color_buffer_float_rgba_available_; |
| 186 bool chromium_color_buffer_float_rgb_available_; | 186 bool chromium_color_buffer_float_rgb_available_; |
| 187 bool ext_color_buffer_float_available_; | 187 bool ext_color_buffer_float_available_; |
| 188 bool oes_texture_float_linear_available_; | 188 bool oes_texture_float_linear_available_; |
| 189 bool oes_texture_half_float_linear_available_; | 189 bool oes_texture_half_float_linear_available_; |
| 190 | 190 |
| 191 bool disable_shader_translator_; | 191 bool disable_shader_translator_; |
| 192 std::unique_ptr<gfx::GLVersionInfo> gl_version_info_; | 192 std::unique_ptr<gl::GLVersionInfo> gl_version_info_; |
| 193 | 193 |
| 194 DISALLOW_COPY_AND_ASSIGN(FeatureInfo); | 194 DISALLOW_COPY_AND_ASSIGN(FeatureInfo); |
| 195 }; | 195 }; |
| 196 | 196 |
| 197 } // namespace gles2 | 197 } // namespace gles2 |
| 198 } // namespace gpu | 198 } // namespace gpu |
| 199 | 199 |
| 200 #endif // GPU_COMMAND_BUFFER_SERVICE_FEATURE_INFO_H_ | 200 #endif // GPU_COMMAND_BUFFER_SERVICE_FEATURE_INFO_H_ |
| OLD | NEW |