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

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

Issue 2693333003: Don't use a global share group for the passthrough command buffer contexts. (Closed)
Patch Set: Created 3 years, 10 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 a4acdd15c4927e7548fe0e35fc3e52f1aed62aa5..0b5354c066068e7d888da9d60536e0bcb4e09c9b 100644
--- a/gpu/command_buffer/service/feature_info.cc
+++ b/gpu/command_buffer/service/feature_info.cc
@@ -1496,33 +1496,11 @@ bool FeatureInfo::IsWebGLContext() const {
}
bool FeatureInfo::IsWebGL1OrES2Context() const {
- // Switch statement to cause a compile-time error if we miss a case.
- switch (context_type_) {
- case CONTEXT_TYPE_WEBGL1:
- case CONTEXT_TYPE_OPENGLES2:
- return true;
- case CONTEXT_TYPE_WEBGL2:
- case CONTEXT_TYPE_OPENGLES3:
- return false;
- }
-
- NOTREACHED();
- return false;
+ return IsWebGL1OrES2ContextType(context_type_);
}
bool FeatureInfo::IsWebGL2OrES3Context() const {
- // Switch statement to cause a compile-time error if we miss a case.
- switch (context_type_) {
- case CONTEXT_TYPE_WEBGL2:
- case CONTEXT_TYPE_OPENGLES3:
- return true;
- case CONTEXT_TYPE_WEBGL1:
- case CONTEXT_TYPE_OPENGLES2:
- return false;
- }
-
- NOTREACHED();
- return false;
+ return IsWebGL2OrES3ContextType(context_type_);
}
void FeatureInfo::AddExtensionString(const char* s) {

Powered by Google App Engine
This is Rietveld 408576698