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

Unified Diff: content/browser/android/in_process/synchronous_compositor_factory_impl.h

Issue 1253553002: Add switch to use ipc command buffer in Android WebView (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review Created 5 years, 5 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: content/browser/android/in_process/synchronous_compositor_factory_impl.h
diff --git a/content/browser/android/in_process/synchronous_compositor_factory_impl.h b/content/browser/android/in_process/synchronous_compositor_factory_impl.h
index 91ef7f61dc16e026256e2ffa49221ac450210eb9..e15daf2c666768bb011359c62c27330c3b6cbe38 100644
--- a/content/browser/android/in_process/synchronous_compositor_factory_impl.h
+++ b/content/browser/android/in_process/synchronous_compositor_factory_impl.h
@@ -8,6 +8,7 @@
#include "base/synchronization/lock.h"
#include "cc/blink/context_provider_web_context.h"
#include "content/browser/android/in_process/synchronous_input_event_filter.h"
+#include "content/common/gpu/client/command_buffer_metrics.h"
#include "content/renderer/android/synchronous_compositor_factory.h"
#include "content/renderer/media/android/stream_texture_factory_synchronous_impl.h"
#include "gpu/command_buffer/service/in_process_command_buffer.h"
@@ -44,12 +45,13 @@ class SynchronousCompositorFactoryImpl : public SynchronousCompositorFactory {
InputHandlerManagerClient* GetInputHandlerManagerClient() override;
scoped_ptr<cc::BeginFrameSource> CreateExternalBeginFrameSource(
int routing_id) override;
+ scoped_refptr<StreamTextureFactory> CreateStreamTextureFactory(
+ int view_id) override;
+ bool OverrideWithFactory() override;
scoped_refptr<cc_blink::ContextProviderWebContext>
CreateOffscreenContextProvider(
const blink::WebGraphicsContext3D::Attributes& attributes,
const std::string& debug_name) override;
- scoped_refptr<StreamTextureFactory> CreateStreamTextureFactory(
- int view_id) override;
gpu_blink::WebGraphicsContext3DInProcessCommandBufferImpl*
CreateOffscreenGraphicsContext3D(
const blink::WebGraphicsContext3D::Attributes& attributes) override;
@@ -64,12 +66,14 @@ class SynchronousCompositorFactoryImpl : public SynchronousCompositorFactory {
base::Thread* CreateInProcessGpuThread(
const InProcessChildThreadParams& params);
void SetRecordFullDocument(bool record_full_document);
+ void SetUseIpcCommandBuffer();
void CompositorInitializedHardwareDraw();
void CompositorReleasedHardwareDraw();
- scoped_refptr<cc::ContextProvider> CreateContextProviderForCompositor();
private:
+ scoped_refptr<cc::ContextProvider> CreateContextProviderForCompositor(
+ CommandBufferContextType type);
bool CanCreateMainThreadContext();
scoped_refptr<StreamTextureFactorySynchronousImpl::ContextProvider>
TryCreateStreamTextureFactory();
@@ -85,6 +89,7 @@ class SynchronousCompositorFactoryImpl : public SynchronousCompositorFactory {
scoped_refptr<VideoContextProvider> video_context_provider_;
bool record_full_layer_;
+ bool use_ipc_command_buffer_;
// |num_hardware_compositor_lock_| is updated on UI thread only but can be
// read on renderer main thread.
« no previous file with comments | « android_webview/common/aw_switches.cc ('k') | content/browser/android/in_process/synchronous_compositor_factory_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698