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

Side by Side Diff: chrome/common/gpu_messages_internal.h

Issue 5317007: Add flow control between renderer and GPU processes, and, on Mac OS X,... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years 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
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 // This header is meant to be included in multiple passes, hence no traditional 5 // This header is meant to be included in multiple passes, hence no traditional
6 // header guard. It is included by backing_store_messages_internal.h 6 // header guard. It is included by backing_store_messages_internal.h
7 // See ipc_message_macros.h for explanation of the macros and passes. 7 // See ipc_message_macros.h for explanation of the macros and passes.
8 8
9 // This file needs to be included again, even though we're actually included 9 // This file needs to be included again, even though we're actually included
10 // from it via utility_messages.h. 10 // from it via utility_messages.h.
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 // previous asynchronous messages (i.e., GpuMsg_EstablishChannel) has 44 // previous asynchronous messages (i.e., GpuMsg_EstablishChannel) has
45 // completed. (This message can't be synchronous because the 45 // completed. (This message can't be synchronous because the
46 // GpuProcessHost uses an IPC::ChannelProxy, which sends all messages 46 // GpuProcessHost uses an IPC::ChannelProxy, which sends all messages
47 // asynchronously.) Results in a GpuHostMsg_SynchronizeReply. 47 // asynchronously.) Results in a GpuHostMsg_SynchronizeReply.
48 IPC_MESSAGE_CONTROL0(GpuMsg_Synchronize) 48 IPC_MESSAGE_CONTROL0(GpuMsg_Synchronize)
49 49
50 // Tells the GPU process to create a context for collecting graphics card 50 // Tells the GPU process to create a context for collecting graphics card
51 // information. 51 // information.
52 IPC_MESSAGE_CONTROL0(GpuMsg_CollectGraphicsInfo) 52 IPC_MESSAGE_CONTROL0(GpuMsg_CollectGraphicsInfo)
53 53
54 #if defined(OS_MACOSX)
55 // Tells the GPU process that the browser process handled the swap
56 // buffers request with the given number. Note that it is possible
57 // for the browser process to coalesce frames; it is not guaranteed
58 // that every GpuHostMsg_AcceleratedSurfaceBuffersSwapped message
59 // will result in a buffer swap on the browser side.
60 IPC_MESSAGE_CONTROL3(GpuMsg_AcceleratedSurfaceBuffersSwappedACK,
61 int /* renderer_id */,
62 int32 /* route_id */,
63 uint64 /* swap_buffers_count */)
64 #endif
65
54 // Tells the GPU process to crash. 66 // Tells the GPU process to crash.
55 IPC_MESSAGE_CONTROL0(GpuMsg_Crash) 67 IPC_MESSAGE_CONTROL0(GpuMsg_Crash)
56 68
57 // Tells the GPU process to hang. 69 // Tells the GPU process to hang.
58 IPC_MESSAGE_CONTROL0(GpuMsg_Hang) 70 IPC_MESSAGE_CONTROL0(GpuMsg_Hang)
59 71
60 IPC_END_MESSAGES(Gpu) 72 IPC_END_MESSAGES(Gpu)
61 73
62 //------------------------------------------------------------------------------ 74 //------------------------------------------------------------------------------
63 // GPU Host Messages 75 // GPU Host Messages
(...skipping 22 matching lines...) Expand all
86 // supported), is sent from the GPU process to the browser to indicate that a 98 // supported), is sent from the GPU process to the browser to indicate that a
87 // new backing store was allocated for the given "window" (fake 99 // new backing store was allocated for the given "window" (fake
88 // PluginWindowHandle). The renderer ID and render view ID are needed in 100 // PluginWindowHandle). The renderer ID and render view ID are needed in
89 // order to uniquely identify the RenderWidgetHostView on the browser side. 101 // order to uniquely identify the RenderWidgetHostView on the browser side.
90 IPC_MESSAGE_CONTROL1(GpuHostMsg_AcceleratedSurfaceSetIOSurface, 102 IPC_MESSAGE_CONTROL1(GpuHostMsg_AcceleratedSurfaceSetIOSurface,
91 GpuHostMsg_AcceleratedSurfaceSetIOSurface_Params) 103 GpuHostMsg_AcceleratedSurfaceSetIOSurface_Params)
92 104
93 // This message notifies the browser process that the renderer 105 // This message notifies the browser process that the renderer
94 // swapped the buffers associated with the given "window", which 106 // swapped the buffers associated with the given "window", which
95 // should cause the browser to redraw the compositor's contents. 107 // should cause the browser to redraw the compositor's contents.
96 IPC_MESSAGE_CONTROL4(GpuHostMsg_AcceleratedSurfaceBuffersSwapped, 108 IPC_MESSAGE_CONTROL1(GpuHostMsg_AcceleratedSurfaceBuffersSwapped,
97 int32, /* renderer_id */ 109 GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params)
98 int32, /* render_view_id */
99 gfx::PluginWindowHandle /* window */,
100 uint64 /* surface_id */)
101 #endif 110 #endif
102 111
103 IPC_END_MESSAGES(GpuHost) 112 IPC_END_MESSAGES(GpuHost)
104 113
105 //------------------------------------------------------------------------------ 114 //------------------------------------------------------------------------------
106 // GPU Channel Messages 115 // GPU Channel Messages
107 // These are messages from a renderer process to the GPU process. 116 // These are messages from a renderer process to the GPU process.
108 IPC_BEGIN_MESSAGES(GpuChannel) 117 IPC_BEGIN_MESSAGES(GpuChannel)
109 118
110 // Tells the GPU process to create a new command buffer that renders directly 119 // Tells the GPU process to create a new command buffer that renders directly
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 gfx::Size /* size */) 227 gfx::Size /* size */)
219 228
220 #if defined(OS_MACOSX) 229 #if defined(OS_MACOSX)
221 // On Mac OS X the GPU plugin must be offscreen, because there is no 230 // On Mac OS X the GPU plugin must be offscreen, because there is no
222 // true cross-process window hierarchy. For this reason we must send 231 // true cross-process window hierarchy. For this reason we must send
223 // resize events explicitly to the command buffer stub so it can 232 // resize events explicitly to the command buffer stub so it can
224 // reallocate its backing store and send the new one back to the 233 // reallocate its backing store and send the new one back to the
225 // browser. This message is currently used only on 10.6 and later. 234 // browser. This message is currently used only on 10.6 and later.
226 IPC_MESSAGE_ROUTED1(GpuCommandBufferMsg_SetWindowSize, 235 IPC_MESSAGE_ROUTED1(GpuCommandBufferMsg_SetWindowSize,
227 gfx::Size /* size */) 236 gfx::Size /* size */)
228
229 // This message is sent from the GPU process to the renderer process (and
230 // from there the browser process) that the buffers associated with the
231 // given "window" were swapped, which should cause the browser to redraw
232 // the various accelerated surfaces.
233 IPC_MESSAGE_ROUTED1(GpuCommandBufferMsg_AcceleratedSurfaceBuffersSwapped,
234 gfx::PluginWindowHandle /* window */)
235 #endif 237 #endif
236 238
237 IPC_END_MESSAGES(GpuCommandBuffer) 239 IPC_END_MESSAGES(GpuCommandBuffer)
238 240
239 //------------------------------------------------------------------------------ 241 //------------------------------------------------------------------------------
240 // GPU Video Decoder Messages 242 // GPU Video Decoder Messages
241 // These messages are sent from Renderer process to GPU process. 243 // These messages are sent from Renderer process to GPU process.
242 IPC_BEGIN_MESSAGES(GpuVideoDecoder) 244 IPC_BEGIN_MESSAGES(GpuVideoDecoder)
243 // Initialize and configure GpuVideoDecoder asynchronously. 245 // Initialize and configure GpuVideoDecoder asynchronously.
244 IPC_MESSAGE_ROUTED1(GpuVideoDecoderMsg_Initialize, 246 IPC_MESSAGE_ROUTED1(GpuVideoDecoderMsg_Initialize,
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
319 321
320 // GpuVideoDecoder report output format change. 322 // GpuVideoDecoder report output format change.
321 IPC_MESSAGE_ROUTED1(GpuVideoDecoderHostMsg_MediaFormatChange, 323 IPC_MESSAGE_ROUTED1(GpuVideoDecoderHostMsg_MediaFormatChange,
322 GpuVideoDecoderFormatChangeParam) 324 GpuVideoDecoderFormatChangeParam)
323 325
324 // GpuVideoDecoder report error. 326 // GpuVideoDecoder report error.
325 IPC_MESSAGE_ROUTED1(GpuVideoDecoderHostMsg_ErrorNotification, 327 IPC_MESSAGE_ROUTED1(GpuVideoDecoderHostMsg_ErrorNotification,
326 GpuVideoDecoderErrorInfoParam) 328 GpuVideoDecoderErrorInfoParam)
327 329
328 IPC_END_MESSAGES(GpuVideoDecoderHost) 330 IPC_END_MESSAGES(GpuVideoDecoderHost)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698