| Index: content/renderer/gpu/compositor_output_surface.cc
|
| diff --git a/content/renderer/gpu/compositor_output_surface.cc b/content/renderer/gpu/compositor_output_surface.cc
|
| index 4d72863896e3332cc2573da2cca0552783692b0a..5667310e2bbb3de29c05fab1e706256bc1341e2a 100644
|
| --- a/content/renderer/gpu/compositor_output_surface.cc
|
| +++ b/content/renderer/gpu/compositor_output_surface.cc
|
| @@ -10,6 +10,7 @@
|
| #include "cc/output/compositor_frame_ack.h"
|
| #include "cc/output/output_surface_client.h"
|
| #include "content/common/gpu/client/command_buffer_proxy_impl.h"
|
| +#include "content/common/gpu/client/context_provider_command_buffer.h"
|
| #include "content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.h"
|
| #include "content/common/view_messages.h"
|
| #include "content/public/common/content_switches.h"
|
| @@ -50,13 +51,13 @@ IPC::ForwardingMessageFilter* CompositorOutputSurface::CreateFilter(
|
| CompositorOutputSurface::CompositorOutputSurface(
|
| int32 routing_id,
|
| uint32 output_surface_id,
|
| - WebGraphicsContext3DCommandBufferImpl* context3D,
|
| - cc::SoftwareOutputDevice* software_device,
|
| + const scoped_refptr<ContextProviderCommandBuffer>& context_provider,
|
| + scoped_ptr<cc::SoftwareOutputDevice> software_device,
|
| bool use_swap_compositor_frame_message)
|
| - : OutputSurface(scoped_ptr<WebKit::WebGraphicsContext3D>(context3D),
|
| - make_scoped_ptr(software_device)),
|
| + : OutputSurface(context_provider, software_device.Pass()),
|
| output_surface_id_(output_surface_id),
|
| use_swap_compositor_frame_message_(use_swap_compositor_frame_message),
|
| + command_buffer_context_(context_provider->Context3d()),
|
| output_surface_filter_(
|
| RenderThreadImpl::current()->compositor_output_surface_filter()),
|
| routing_id_(routing_id),
|
| @@ -111,12 +112,10 @@ void CompositorOutputSurface::SwapBuffers(cc::CompositorFrame* frame) {
|
| }
|
|
|
| if (frame->gl_frame_data) {
|
| - WebGraphicsContext3DCommandBufferImpl* command_buffer =
|
| - static_cast<WebGraphicsContext3DCommandBufferImpl*>(context3d());
|
| CommandBufferProxyImpl* command_buffer_proxy =
|
| - command_buffer->GetCommandBufferProxy();
|
| + command_buffer_context_->GetCommandBufferProxy();
|
| DCHECK(command_buffer_proxy);
|
| - context3d()->shallowFlushCHROMIUM();
|
| + context_provider_->Context3d()->shallowFlushCHROMIUM();
|
| command_buffer_proxy->SetLatencyInfo(frame->metadata.latency_info);
|
| }
|
|
|
|
|