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

Side by Side Diff: remoting/host/chromoting_messages.h

Issue 11413022: DesktopSessionAgent now hosts the video capturer and provides necessary plumbing to drive it via an… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month 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 | « no previous file | remoting/host/desktop_process.h » ('j') | remoting/host/desktop_process.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // Defines IPC messages used by Chromoting components. 5 #ifndef REMOTING_HOST_CHROMOTING_MESSAGES_H_
6 #define REMOTING_HOST_CHROMOTING_MESSAGES_H_
Wez 2012/11/16 23:37:31 nit: Chromoting IPC messages, for clarity?
alexeypa (please no reviews) 2012/11/19 21:46:25 No the file name is chromoting_messages.h. Other I
7
8 #include "ipc/ipc_platform_file.h"
9 #include "third_party/skia/include/core/SkPoint.h"
10 #include "third_party/skia/include/core/SkRect.h"
11 #include "third_party/skia/include/core/SkSize.h"
12
13 #endif // REMOTING_HOST_CHROMOTING_MESSAGES_H_
6 14
7 // Multiply-included message file, no traditional include guard. 15 // Multiply-included message file, no traditional include guard.
8 #include "ipc/ipc_message_macros.h" 16 #include "ipc/ipc_message_macros.h"
9 #include "ipc/ipc_platform_file.h"
10 17
11 #define IPC_MESSAGE_START ChromotingMsgStart 18 #define IPC_MESSAGE_START ChromotingMsgStart
12 19
13 //----------------------------------------------------------------------------- 20 //-----------------------------------------------------------------------------
14 // Chromoting messages sent from the daemon to the network process. 21 // Chromoting messages sent from the daemon to the network process.
15 22
16 // Requests the network process to crash producing a crash dump. The daemon 23 // Requests the network process to crash producing a crash dump. The daemon
17 // sends this message when a fatal error has been detected indicating that 24 // sends this message when a fatal error has been detected indicating that
18 // the network process misbehaves. The daemon passes the location of the code 25 // the network process misbehaves. The daemon passes the location of the code
19 // that detected the error. 26 // that detected the error.
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 // Chromoting messages sent from the desktop to the daemon process. 83 // Chromoting messages sent from the desktop to the daemon process.
77 84
78 // Notifies the daemon that a desktop integration process has been initialized. 85 // Notifies the daemon that a desktop integration process has been initialized.
79 // |desktop_pipe| specifies the client end of the desktop pipe. It is to be 86 // |desktop_pipe| specifies the client end of the desktop pipe. It is to be
80 // forwarded to the desktop environment stub. 87 // forwarded to the desktop environment stub.
81 // 88 //
82 // Windows only: |desktop_pipe| has to be duplicated from the desktop process by 89 // Windows only: |desktop_pipe| has to be duplicated from the desktop process by
83 // the receiver of the message. 90 // the receiver of the message.
84 IPC_MESSAGE_CONTROL1(ChromotingDesktopDaemonMsg_DesktopAttached, 91 IPC_MESSAGE_CONTROL1(ChromotingDesktopDaemonMsg_DesktopAttached,
85 IPC::PlatformFileForTransit /* desktop_pipe */) 92 IPC::PlatformFileForTransit /* desktop_pipe */)
93
94 //-----------------------------------------------------------------------------
95 // Chromoting messages sent from the desktop to the network process.
96
97 // Notifies the network process that a shared buffer has been created.
98 // The network process has to confirm registration by replying with
99 // ChromotingNetworkDesktopMsg_SharedBufferRegistered message.
100 IPC_MESSAGE_CONTROL3(ChromotingDesktopNetworkMsg_RegisterSharedBuffer,
Wez 2012/11/16 23:37:31 nit: Make this & next fn Add/RemoveSharedBuffer?
alexeypa (please no reviews) 2012/11/19 21:46:25 Done.
101 intptr_t /* id */,
102 IPC::PlatformFileForTransit /* handle */,
103 uint32 /* size */)
104
105 // Request the network process to stop using a shared buffer.
106 IPC_MESSAGE_CONTROL1(ChromotingDesktopNetworkMsg_DropSharedBuffer,
107 intptr_t /* id */)
108
109 IPC_STRUCT_TRAITS_BEGIN(SkIPoint)
110 IPC_STRUCT_TRAITS_MEMBER(fX)
111 IPC_STRUCT_TRAITS_MEMBER(fY)
112 IPC_STRUCT_TRAITS_END()
113
114 IPC_STRUCT_TRAITS_BEGIN(SkIRect)
115 IPC_STRUCT_TRAITS_MEMBER(fLeft)
116 IPC_STRUCT_TRAITS_MEMBER(fTop)
117 IPC_STRUCT_TRAITS_MEMBER(fRight)
118 IPC_STRUCT_TRAITS_MEMBER(fBottom)
119 IPC_STRUCT_TRAITS_END()
120
121 IPC_STRUCT_TRAITS_BEGIN(SkISize)
122 IPC_STRUCT_TRAITS_MEMBER(fWidth)
123 IPC_STRUCT_TRAITS_MEMBER(fHeight)
124 IPC_STRUCT_TRAITS_END()
125
126 // Serialized CaptureData structure.
127 IPC_STRUCT_BEGIN(SerializedCapturedData)
128 // ID of the shared memory buffer containing the pixels.
129 IPC_STRUCT_MEMBER(intptr_t, shared_buffer_id)
130
131 // Captured region.
132 IPC_STRUCT_MEMBER(std::vector<SkIRect>, dirty_region)
133
134 // Dimentions of the buffer in pixels.
Wez 2012/11/16 23:37:31 typo: dimensions
alexeypa (please no reviews) 2012/11/19 21:46:25 Done.
135 IPC_STRUCT_MEMBER(SkISize, dimensions)
136
137 // Pixel format.
Wez 2012/11/16 23:37:31 nit: "Format of the shared pixel data buffer."?
alexeypa (please no reviews) 2012/11/19 21:46:25 Why? The shared buffer does not know it carries pi
138 IPC_STRUCT_MEMBER(int32, pixel_format)
139
140 // Time spent in capture. Unit is in milliseconds.
141 IPC_STRUCT_MEMBER(int, capture_time_ms)
Wez 2012/11/16 23:37:31 nit: I'd suggest moving this to the end of the str
alexeypa (please no reviews) 2012/11/19 21:46:25 Right now the order of fields in this structure ma
142
143 // Sequence number supplied by client for performance tracking.
144 IPC_STRUCT_MEMBER(int64, client_sequence_number)
145
146 // DPI for this frame.
147 IPC_STRUCT_MEMBER(SkIPoint, dpi)
148 IPC_STRUCT_END()
149
150 // Notifies the network process that a shared buffer has been created.
151 IPC_MESSAGE_CONTROL1(ChromotingDesktopNetworkMsg_CaptureCompleted,
152 SerializedCapturedData /* capture_data */ )
153
154
155 //-----------------------------------------------------------------------------
156 // Chromoting messages sent from the network to the desktop process.
157
158 // Notifies the desktop process that the shared memory buffer has been mapped to
159 // the memory of the network process and so it can be safely dropped by
160 // the network process at any time.
Wez 2012/11/16 23:37:31 Do you mean it can be safely dropped by the deskto
alexeypa (please no reviews) 2012/11/19 21:46:25 It means the process can safely unmap the memory a
161 IPC_MESSAGE_CONTROL1(ChromotingNetworkDesktopMsg_SharedBufferRegistered,
162 intptr_t /* id */)
163
164 IPC_MESSAGE_CONTROL1(ChromotingNetworkDesktopMsg_InvalidateRegion,
165 std::vector<SkIRect> /* invalid_region */ )
166
167 IPC_MESSAGE_CONTROL0(ChromotingNetworkDesktopMsg_CaptureFrame)
Wez 2012/11/16 23:37:31 nit: Add comments to explain this & InvalidateRegi
alexeypa (please no reviews) 2012/11/19 21:46:25 Done.
OLDNEW
« no previous file with comments | « no previous file | remoting/host/desktop_process.h » ('j') | remoting/host/desktop_process.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698