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

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

Issue 1143393007: Teach GPU command buffer whether a context is webgl. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 6 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
Index: gpu/command_buffer/service/feature_info.cc
diff --git a/gpu/command_buffer/service/feature_info.cc b/gpu/command_buffer/service/feature_info.cc
index c86de231fd4695af0574699fbab0570a12d47675..d692b546ed4885cc1f536207cd212eb0a3a4b518 100644
--- a/gpu/command_buffer/service/feature_info.cc
+++ b/gpu/command_buffer/service/feature_info.cc
@@ -523,10 +523,11 @@ void FeatureInfo::InitializeFeatures() {
}
// Check if we should allow GL_OES_texture_npot
- if (gl_version_info_->is_es3 ||
- gl_version_info_->is_desktop_core_profile ||
- extensions.Contains("GL_ARB_texture_non_power_of_two") ||
- extensions.Contains("GL_OES_texture_npot")) {
+ if (!disallowed_features_.npot_support &&
Zhenyao Mo 2015/06/07 21:42:11 This is where we disable NPOT support for WebGL 1.
+ (gl_version_info_->is_es3 ||
+ gl_version_info_->is_desktop_core_profile ||
+ extensions.Contains("GL_ARB_texture_non_power_of_two") ||
+ extensions.Contains("GL_OES_texture_npot"))) {
AddExtensionString("GL_OES_texture_npot");
feature_flags_.npot_ok = true;
}

Powered by Google App Engine
This is Rietveld 408576698