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

Unified Diff: content/common/gpu/client/gpu_jpeg_decode_accelerator_host.h

Issue 1656433002: Sample code: IPC Transport object for GPU Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: GpuMemoryBufferService + Transport object. TODO: Eliminate ChildThreadImpl dependency Created 4 years, 10 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/common/gpu/client/gpu_jpeg_decode_accelerator_host.h
diff --git a/content/common/gpu/client/gpu_jpeg_decode_accelerator_host.h b/content/common/gpu/client/gpu_jpeg_decode_accelerator_host.h
index 53465f3aee75fa5a01887e50b7509ef67fdf477a..d62cd1df3b2c10796cc8e107a3a0901819b3c464 100644
--- a/content/common/gpu/client/gpu_jpeg_decode_accelerator_host.h
+++ b/content/common/gpu/client/gpu_jpeg_decode_accelerator_host.h
@@ -10,17 +10,13 @@
#include "base/macros.h"
#include "base/memory/weak_ptr.h"
#include "base/threading/non_thread_safe.h"
+#include "content/common/gpu/client/ipc/gpu_jpeg_decode_accelerator_host_ipc_transport.h"
#include "media/video/jpeg_decode_accelerator.h"
namespace base {
class SingleThreadTaskRunner;
}
-namespace IPC {
-class Listener;
-class Message;
-}
-
namespace content {
class GpuChannelHost;
@@ -34,8 +30,7 @@ class GpuJpegDecodeAcceleratorHost : public media::JpegDecodeAccelerator,
// guaranteed not to outlive |channel|.
GpuJpegDecodeAcceleratorHost(
GpuChannelHost* channel,
- int32_t route_id,
- const scoped_refptr<base::SingleThreadTaskRunner>& io_task_runner);
+ scoped_ptr<GpuJpegDecodeAcceleratorHostIPCTransport> transport);
~GpuJpegDecodeAcceleratorHost() override;
// media::JpegDecodeAccelerator implementation.
@@ -46,25 +41,20 @@ class GpuJpegDecodeAcceleratorHost : public media::JpegDecodeAccelerator,
const scoped_refptr<media::VideoFrame>& video_frame) override;
bool IsSupported() override;
- base::WeakPtr<IPC::Listener> GetReceiver();
-
private:
class Receiver;
- void Send(IPC::Message* message);
-
// Unowned reference to the GpuChannelHost to send IPC messages to the GPU
// process.
GpuChannelHost* channel_;
- // Route ID for the associated decoder in the GPU process.
- int32_t decoder_route_id_;
-
// GPU IO task runner.
scoped_refptr<base::SingleThreadTaskRunner> io_task_runner_;
scoped_ptr<Receiver> receiver_;
+ scoped_ptr<GpuJpegDecodeAcceleratorHostIPCTransport> transport_;
+
DISALLOW_COPY_AND_ASSIGN(GpuJpegDecodeAcceleratorHost);
};
« no previous file with comments | « content/common/gpu/client/gpu_channel_host_factory.h ('k') | content/common/gpu/client/gpu_jpeg_decode_accelerator_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698