Chromium Code Reviews

Side by Side Diff: chrome/gpu/gpu_channel.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.
Jump to:
View unified diff | | Annotate | Revision Log
« no previous file with comments | « chrome/common/gpu_video_common.cc ('k') | chrome/gpu/gpu_channel.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_GPU_GPU_CHANNEL_H_ 5 #ifndef CHROME_GPU_GPU_CHANNEL_H_
6 #define CHROME_GPU_GPU_CHANNEL_H_ 6 #define CHROME_GPU_GPU_CHANNEL_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
11 #include "base/id_map.h" 11 #include "base/id_map.h"
12 #include "base/scoped_open_process.h" 12 #include "base/scoped_open_process.h"
13 #include "base/scoped_ptr.h" 13 #include "base/scoped_ptr.h"
14 #include "build/build_config.h" 14 #include "build/build_config.h"
15 #include "chrome/common/gpu_video_common.h"
16 #include "chrome/common/message_router.h" 15 #include "chrome/common/message_router.h"
17 #include "chrome/gpu/gpu_command_buffer_stub.h" 16 #include "chrome/gpu/gpu_command_buffer_stub.h"
18 #include "gfx/native_widget_types.h" 17 #include "gfx/native_widget_types.h"
19 #include "gfx/size.h" 18 #include "gfx/size.h"
20 #include "ipc/ipc_channel.h" 19 #include "ipc/ipc_channel.h"
21 #include "ipc/ipc_message.h" 20 #include "ipc/ipc_message.h"
22 #include "ipc/ipc_sync_channel.h" 21 #include "ipc/ipc_sync_channel.h"
23 22
24 // Encapsulates an IPC channel between the GPU process and one renderer 23 // Encapsulates an IPC channel between the GPU process and one renderer
25 // process. On the renderer side there's a corresponding GpuChannelHost. 24 // process. On the renderer side there's a corresponding GpuChannelHost.
(...skipping 40 matching lines...)
66 // Message handlers. 65 // Message handlers.
67 void OnCreateViewCommandBuffer(gfx::NativeViewId view, 66 void OnCreateViewCommandBuffer(gfx::NativeViewId view,
68 int32 render_view_id, 67 int32 render_view_id,
69 int32* route_id); 68 int32* route_id);
70 void OnCreateOffscreenCommandBuffer(int32 parent_route_id, 69 void OnCreateOffscreenCommandBuffer(int32 parent_route_id,
71 const gfx::Size& size, 70 const gfx::Size& size,
72 uint32 parent_texture_id, 71 uint32 parent_texture_id,
73 int32* route_id); 72 int32* route_id);
74 void OnDestroyCommandBuffer(int32 route_id); 73 void OnDestroyCommandBuffer(int32 route_id);
75 74
76 void OnGetVideoService(GpuVideoServiceInfoParam* info);
77 void OnCreateVideoDecoder(GpuVideoDecoderInfoParam* info);
78 void OnDestroyVideoDecoder(int32 decoder_id);
79
80 scoped_ptr<IPC::SyncChannel> channel_; 75 scoped_ptr<IPC::SyncChannel> channel_;
81 76
82 // Handle to the renderer process who is on the other side of the channel. 77 // Handle to the renderer process who is on the other side of the channel.
83 base::ScopedOpenProcess renderer_process_; 78 base::ScopedOpenProcess renderer_process_;
84 79
85 // The id of the renderer who is on the other side of the channel. 80 // The id of the renderer who is on the other side of the channel.
86 int renderer_id_; 81 int renderer_id_;
87 82
88 #if defined(OS_POSIX) 83 #if defined(OS_POSIX)
89 // FD for the renderer end of the pipe. It is stored until we send it over 84 // FD for the renderer end of the pipe. It is stored until we send it over
90 // IPC after which it is cleared. It will be closed by the IPC mechanism. 85 // IPC after which it is cleared. It will be closed by the IPC mechanism.
91 int renderer_fd_; 86 int renderer_fd_;
92 #endif 87 #endif
93 88
94 // Used to implement message routing functionality to CommandBuffer objects 89 // Used to implement message routing functionality to CommandBuffer objects
95 MessageRouter router_; 90 MessageRouter router_;
96 91
97 #if defined(ENABLE_GPU) 92 #if defined(ENABLE_GPU)
98 typedef IDMap<GpuCommandBufferStub, IDMapOwnPointer> StubMap; 93 typedef IDMap<GpuCommandBufferStub, IDMapOwnPointer> StubMap;
99 StubMap stubs_; 94 StubMap stubs_;
100 #endif 95 #endif
101 96
102 bool log_messages_; // True if we should log sent and received messages. 97 bool log_messages_; // True if we should log sent and received messages.
103 98
104 DISALLOW_COPY_AND_ASSIGN(GpuChannel); 99 DISALLOW_COPY_AND_ASSIGN(GpuChannel);
105 }; 100 };
106 101
107 #endif // CHROME_GPU_GPU_CHANNEL_H_ 102 #endif // CHROME_GPU_GPU_CHANNEL_H_
OLDNEW
« no previous file with comments | « chrome/common/gpu_video_common.cc ('k') | chrome/gpu/gpu_channel.cc » ('j') | no next file with comments »

Powered by Google App Engine