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

Side by Side Diff: chrome/renderer/gpu_video_service_host.h

Issue 3020077: Revert 55405 - Special thanks for in-ming cheng's MFT hardware decodering cod... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/renderer/gpu_video_decoder_host.cc ('k') | chrome/renderer/gpu_video_service_host.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_RENDERER_GPU_VIDEO_SERVICE_HOST_H_
6 #define CHROME_RENDERER_GPU_VIDEO_SERVICE_HOST_H_
7
8 #include <map>
9
10 #include "base/singleton.h"
11 #include "chrome/common/gpu_video_common.h"
12 #include "chrome/renderer/gpu_channel_host.h"
13 #include "chrome/renderer/gpu_video_decoder_host.h"
14 #include "ipc/ipc_channel.h"
15 #include "media/base/buffers.h"
16 #include "media/base/video_frame.h"
17
18 class GpuVideoServiceHost : public IPC::Channel::Listener,
19 public Singleton<GpuVideoServiceHost> {
20 public:
21 // IPC::Channel::Listener.
22 virtual void OnChannelConnected(int32 peer_pid) {}
23 virtual void OnChannelError();
24 virtual void OnMessageReceived(const IPC::Message& message);
25
26 void OnRendererThreadInit(MessageLoop* message_loop);
27 void OnGpuChannelConnected(GpuChannelHost* channel_host,
28 MessageRouter* router,
29 IPC::SyncChannel* channel);
30
31 // call at RenderThread. one per renderer process.
32 scoped_refptr<GpuVideoDecoderHost> CreateVideoDecoder(
33 GpuVideoDecoderHost::EventHandler* event_handler);
34 void DestroyVideoDecoder(scoped_refptr<GpuVideoDecoderHost>);
35
36 private:
37 GpuVideoServiceHost() : message_loop_(NULL) {
38 service_info_.service_available_ = 0;
39 }
40
41 scoped_refptr<GpuChannelHost> channel_host_;
42 MessageRouter* router_;
43 GpuVideoServiceInfoParam service_info_;
44 MessageLoop* message_loop_; // Message loop of render thread.
45
46 friend struct DefaultSingletonTraits<GpuVideoServiceHost>;
47 DISALLOW_COPY_AND_ASSIGN(GpuVideoServiceHost);
48 };
49
50 #endif // CHROME_RENDERER_GPU_VIDEO_SERVICE_HOST_H_
51
OLDNEW
« no previous file with comments | « chrome/renderer/gpu_video_decoder_host.cc ('k') | chrome/renderer/gpu_video_service_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698