| Index: media/gpu/ipc/client/gpu_video_decode_accelerator_host.h
|
| diff --git a/media/gpu/ipc/client/gpu_video_decode_accelerator_host.h b/media/gpu/ipc/client/gpu_video_decode_accelerator_host.h
|
| index 2ba09634b483b851cc02029ad6e4a12cc3ccd76c..a2f6ffde7e3f8826a99b128ca62f8e2b9c31a1d9 100644
|
| --- a/media/gpu/ipc/client/gpu_video_decode_accelerator_host.h
|
| +++ b/media/gpu/ipc/client/gpu_video_decode_accelerator_host.h
|
| @@ -11,6 +11,7 @@
|
|
|
| #include "base/macros.h"
|
| #include "base/memory/weak_ptr.h"
|
| +#include "base/single_thread_task_runner.h"
|
| #include "base/threading/non_thread_safe.h"
|
| #include "gpu/ipc/client/command_buffer_proxy_impl.h"
|
| #include "ipc/ipc_listener.h"
|
| @@ -86,6 +87,10 @@ class GpuVideoDecodeAcceleratorHost
|
| // The client that will receive callbacks from the decoder.
|
| Client* client_;
|
|
|
| + // Protect |impl_|. |impl_| is used on media thread, but it can be invalidated
|
| + // on main thread.
|
| + base::Lock impl_lock_;
|
| +
|
| // Unowned reference to the gpu::CommandBufferProxyImpl that created us.
|
| // |this| registers as a DeletionObserver of |impl_|, the so reference is
|
| // always valid as long as it is not NULL.
|
| @@ -94,6 +99,10 @@ class GpuVideoDecodeAcceleratorHost
|
| // Requested dimensions of the buffer, from ProvidePictureBuffers().
|
| gfx::Size picture_buffer_dimensions_;
|
|
|
| + // Task runner for tasks that should run on the thread this class is
|
| + // constructed.
|
| + scoped_refptr<base::SingleThreadTaskRunner> media_task_runner_;
|
| +
|
| // WeakPtr factory for posting tasks back to itself.
|
| base::WeakPtrFactory<GpuVideoDecodeAcceleratorHost> weak_this_factory_;
|
|
|
|
|