Chromium Code Reviews| Index: content/common/gpu/client/gpu_channel_host.cc |
| diff --git a/content/common/gpu/client/gpu_channel_host.cc b/content/common/gpu/client/gpu_channel_host.cc |
| index 601c06d9dac1073b9af4c16652c61ded8cf3d6e0..64b7aa954dd404491a07006574f6eacb370b2a6a 100644 |
| --- a/content/common/gpu/client/gpu_channel_host.cc |
| +++ b/content/common/gpu/client/gpu_channel_host.cc |
| @@ -13,6 +13,7 @@ |
| #include "base/posix/eintr_wrapper.h" |
| #include "base/threading/thread_restrictions.h" |
| #include "content/common/gpu/client/command_buffer_proxy_impl.h" |
| +#include "content/common/gpu/client/gpu_video_encode_accelerator_host.h" |
| #include "content/common/gpu/gpu_messages.h" |
| #include "gpu/command_buffer/common/mailbox.h" |
| #include "ipc/ipc_sync_message_filter.h" |
| @@ -184,6 +185,25 @@ scoped_ptr<media::VideoDecodeAccelerator> GpuChannelHost::CreateVideoDecoder( |
| return proxy->CreateVideoDecoder(profile, client).Pass(); |
| } |
| +scoped_ptr<media::VideoEncodeAccelerator> GpuChannelHost::CreateVideoEncoder( |
|
Ami GONE FROM CHROMIUM
2013/07/31 23:01:12
I'm surprised by the asymmetry between CVD() and C
sheu
2013/08/02 01:27:49
Decode is tied to the CommandBufferImplProxy, sinc
|
| + media::VideoEncodeAccelerator::Client* client) { |
| + TRACE_EVENT0("gpu", "GpuChannelHost::CreateVideoEncoder"); |
| + |
| + scoped_ptr<media::VideoEncodeAccelerator> vea; |
| + int32 route_id; |
| + if (!Send(new GpuChannelMsg_CreateVideoEncoder(&route_id))) { |
| + return vea.Pass(); |
| + } |
| + if (route_id == MSG_ROUTING_NONE) |
| + return vea.Pass(); |
| + |
| + GpuVideoEncodeAcceleratorHost* vea_host = |
| + new GpuVideoEncodeAcceleratorHost(client, this, route_id); |
| + AddRoute(route_id, vea_host->AsWeakPtr()); |
| + vea.reset(vea_host); |
| + return vea.Pass(); |
| +} |
| + |
| void GpuChannelHost::DestroyCommandBuffer( |
| CommandBufferProxyImpl* command_buffer) { |
| TRACE_EVENT0("gpu", "GpuChannelHost::DestroyCommandBuffer"); |