summaryrefslogtreecommitdiffstats
path: root/android_webview/lib
diff options
context:
space:
mode:
authorboliu@chromium.org <boliu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-05-24 01:16:19 +0000
committerboliu@chromium.org <boliu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-05-24 01:16:19 +0000
commit8705654b9dca0ad235794da2d85fd67107ed9789 (patch)
tree999550e096e1bb5476db8cfda5109dddf5285984 /android_webview/lib
parentd6cca23af08515770c2ba66d01a3851d3da21570 (diff)
downloadchromium_src-8705654b9dca0ad235794da2d85fd67107ed9789.zip
chromium_src-8705654b9dca0ad235794da2d85fd67107ed9789.tar.gz
chromium_src-8705654b9dca0ad235794da2d85fd67107ed9789.tar.bz2
[Android WebView] Implement delegated rendering for sync compositor
Modify content SynchronousCompositor related classes to support for content embedder to use delegated rendering. The embedder is responsible for creating the parent compositor. Essentially need to pass CompositorFrame and CompositorFrameAck between embedder and SynchronousCompositor. Also need to expose the share context so embedder can correctly initialize a context for parent compositor. In android_webview implemented parent compositor for delegated rendering while keeping the current direct renderer working, controlled by a command line switch. BrowserViewRenderer deals exclusively with SynchronousCompositor (the child). And HardwareRenderer deals exclusively with the parent compositor. The two share data through lock protected SharedRendererState. And all are coordinated by native AwContents. Direct rendering path is kept alive in HardwareRendererLegacy and code guarded by switches::UbercompEnabled. Direct rendering path remains the default. BUG=344087 Review URL: https://codereview.chromium.org/287993004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@272668 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'android_webview/lib')
-rw-r--r--android_webview/lib/main/aw_main_delegate.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/android_webview/lib/main/aw_main_delegate.cc b/android_webview/lib/main/aw_main_delegate.cc
index a71c0a6..c5f99b7 100644
--- a/android_webview/lib/main/aw_main_delegate.cc
+++ b/android_webview/lib/main/aw_main_delegate.cc
@@ -8,6 +8,7 @@
#include "android_webview/browser/browser_view_renderer.h"
#include "android_webview/browser/gpu_memory_buffer_factory_impl.h"
#include "android_webview/browser/scoped_allow_wait_for_legacy_web_view_api.h"
+#include "android_webview/common/aw_switches.h"
#include "android_webview/lib/aw_browser_dependency_factory_impl.h"
#include "android_webview/native/aw_geolocation_permission_context.h"
#include "android_webview/native/aw_quota_manager_bridge_impl.h"
@@ -66,6 +67,12 @@ bool AwMainDelegate::BasicStartupComplete(int* exit_code) {
// Not yet supported in single-process mode.
cl->AppendSwitch(switches::kDisableSharedWorkers);
+ if (!switches::UbercompEnabled()) {
+ cl->AppendSwitch(switches::kDisableDelegatedRenderer);
+ } else {
+ cl->AppendSwitch(switches::kDisableAccelerated2dCanvas);
+ cl->AppendSwitch(switches::kDisableExperimentalWebGL);
+ }
// File system API not supported (requires some new API; internal bug 6930981)
cl->AppendSwitch(switches::kDisableFileSystem);