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

Unified Diff: content/public/test/browser_test_base.h

Issue 21052007: aura: Clean up compositor initialization/destruction. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: cleanupcompositor: UseRealGLBindings for CompositingRWHVBrowserTests on win_rel Created 7 years, 4 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/common/gpu/client/gl_helper.cc ('k') | content/public/test/browser_test_base.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/test/browser_test_base.h
diff --git a/content/public/test/browser_test_base.h b/content/public/test/browser_test_base.h
index 26f7c0700205871ac5cc29acbdf011ab945ad854..c789ff4301f1521b3ae03ad5e4340b6fad1d41e3 100644
--- a/content/public/test/browser_test_base.h
+++ b/content/public/test/browser_test_base.h
@@ -109,6 +109,16 @@ class BrowserTestBase : public testing::Test {
// returns.
void PostTaskToInProcessRendererAndWait(const base::Closure& task);
+ // Call this before SetUp() to use real GL contexts in Compositor for the
+ // test.
+ void UseRealGLContexts() { allow_test_contexts_ = false; }
+
+ // Call this before SetUp() to use real GL drivers instead of OSMesa for the
+ // test.
+ void UseRealGLBindings() { allow_osmesa_ = false; }
+
+ bool UsingAcceleratedVideoDecode() { return using_accelerated_video_decode_; }
+
private:
void ProxyRunTestOnMainThreadLoop();
@@ -118,6 +128,16 @@ class BrowserTestBase : public testing::Test {
// Embedded test server, cheap to create, started on demand.
scoped_ptr<net::test_server::EmbeddedTestServer> embedded_test_server_;
+ // When false, the ui::Compositor will be forced to use real GL contexts for
+ // the test, so that it produces real pixel output.
+ bool allow_test_contexts_;
+
+ // When false, the GL backend will use a real GPU. When true, it uses OSMesa
+ // to run GL on the CPU in a way that works across all platforms.
+ bool allow_osmesa_;
+
+ bool using_accelerated_video_decode_;
+
#if defined(OS_POSIX)
bool handle_sigterm_;
#endif
« no previous file with comments | « content/common/gpu/client/gl_helper.cc ('k') | content/public/test/browser_test_base.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698