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

Unified Diff: ui/gl/gl_helper.cc

Issue 2094823002: gl_unittests: on a core profile, use VAOs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Simplify ShouldTestsUseVAOs Created 4 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
« no previous file with comments | « ui/gl/gl_helper.h ('k') | ui/gl/test/gl_image_test_template.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gl/gl_helper.cc
diff --git a/ui/gl/gl_helper.cc b/ui/gl/gl_helper.cc
index 97a4e3b76f57be363ef6b289c827b383236b700a..4378c6b81838280dc6c9bdf44048ac6a6c934e46 100644
--- a/ui/gl/gl_helper.cc
+++ b/ui/gl/gl_helper.cc
@@ -7,6 +7,8 @@
#include <string>
#include "base/logging.h"
+#include "ui/gl/gl_context.h"
+#include "ui/gl/gl_version_info.h"
#include "ui/gl/scoped_binders.h"
namespace gl {
@@ -94,4 +96,9 @@ void GLHelper::DrawQuad(GLuint vertex_buffer) {
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
}
+// static
+bool GLHelper::ShouldTestsUseVAOs() {
+ return GLContext::GetCurrent()->GetVersionInfo()->is_desktop_core_profile;
+}
+
} // namespace gl
« no previous file with comments | « ui/gl/gl_helper.h ('k') | ui/gl/test/gl_image_test_template.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698