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

Unified Diff: gpu/command_buffer/service/feature_info.h

Issue 2444813002: Remove unsafe mode to enable es3 api by default for WebGL2 and ES3 context (Closed)
Patch Set: fix a bug Created 4 years, 2 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/public/browser/gpu_utils.cc ('k') | gpu/command_buffer/service/feature_info.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gpu/command_buffer/service/feature_info.h
diff --git a/gpu/command_buffer/service/feature_info.h b/gpu/command_buffer/service/feature_info.h
index a3f767146ad06f20901bc7791d99dff088ce4fd0..00ff7278b6b4114aeb803be5078783eff047eb25 100644
--- a/gpu/command_buffer/service/feature_info.h
+++ b/gpu/command_buffer/service/feature_info.h
@@ -147,7 +147,17 @@ class GPU_EXPORT FeatureInfo : public base::RefCounted<FeatureInfo> {
void EnableES3Validators();
bool IsES3Enabled() const {
- return unsafe_es3_apis_enabled_;
+ return es3_apis_enabled_;
+ }
+
+ // TODO(yunchao): This is a workaround to make gpu_unittests pass.
+ // Will fix it later.
+ void SetES3APIsSwitch(bool enabled) {
+ enable_es3_apis_switch_ = enabled;
+ }
+
+ bool GetES3APIsSwitch() const {
+ return enable_es3_apis_switch_;
}
bool disable_shader_translator() const { return disable_shader_translator_; }
@@ -195,10 +205,8 @@ class GPU_EXPORT FeatureInfo : public base::RefCounted<FeatureInfo> {
// Flags for Workarounds.
const GpuDriverBugWorkarounds workarounds_;
- // Whether the command line switch kEnableUnsafeES3APIs is passed in.
- bool enable_unsafe_es3_apis_switch_;
-
- bool unsafe_es3_apis_enabled_;
+ bool es3_apis_enabled_;
+ bool enable_es3_apis_switch_;
bool ext_color_buffer_float_available_;
bool oes_texture_float_linear_available_;
« no previous file with comments | « content/public/browser/gpu_utils.cc ('k') | gpu/command_buffer/service/feature_info.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698