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

Side by Side Diff: webrtc/modules/audio_coding/main/acm2/dump.proto

Issue 1230973005: Adds logging of configuration information for VideoReceiveStream (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years, 5 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
OLDNEW
1 syntax = "proto2"; 1 syntax = "proto2";
2 option optimize_for = LITE_RUNTIME; 2 option optimize_for = LITE_RUNTIME;
3 package webrtc; 3 package webrtc;
4 4
5 // This is the main message to dump to a file, it can contain multiple event 5 // This is the main message to dump to a file, it can contain multiple event
6 // messages, but it is possible to append multiple EventStreams (each with a 6 // messages, but it is possible to append multiple EventStreams (each with a
7 // single event) to a file. 7 // single event) to a file.
8 // This has the benefit that there's no need to keep all data in memory. 8 // This has the benefit that there's no need to keep all data in memory.
9 message ACMDumpEventStream { 9 message ACMDumpEventStream {
10 repeated ACMDumpEvent stream = 1; 10 repeated ACMDumpEvent stream = 1;
11 } 11 }
12 12
13 13
14 message ACMDumpEvent { 14 message ACMDumpEvent {
15 // required - Elapsed wallclock time in us since the start of the log. 15 // required - Elapsed wallclock time in us since the start of the log.
16 optional int64 timestamp_us = 1; 16 optional int64 timestamp_us = 1;
17 17
18 // The different types of events that can occur, the UNKNOWN_EVENT entry 18 // The different types of events that can occur, the UNKNOWN_EVENT entry
19 // is added in case future EventTypes are added, in that case old code will 19 // is added in case future EventTypes are added, in that case old code will
20 // receive the new events as UNKNOWN_EVENT. 20 // receive the new events as UNKNOWN_EVENT.
21 enum EventType { 21 enum EventType {
22 UNKNOWN_EVENT = 0; 22 UNKNOWN_EVENT = 0;
23 RTP_EVENT = 1; 23 RTP_EVENT = 1;
24 DEBUG_EVENT = 2; 24 RTCP_EVENT = 2;
25 CONFIG_EVENT = 3; 25 DEBUG_EVENT = 3;
26 RECEIVER_CONFIG_EVENT = 4;
27 SENDER_CONFIG_EVENT = 5;
28 AUDIO_RECEIVER_CONFIG_EVENT = 6;
29 AUDIO_SENDER_CONFIG_EVENT = 7;
26 } 30 }
27 31
28 // required - Indicates the type of this event 32 // required - Indicates the type of this event
29 optional EventType type = 2; 33 optional EventType type = 2;
30 34
31 // optional - but required if type == RTP_EVENT 35 // optional - but required if type == RTP_EVENT
32 optional ACMDumpRTPPacket packet = 3; 36 optional ACMDumpRtpPacket rtp_packet = 3;
37
38 // optional - but required if type == RTCP_EVENT
39 optional ACMDumpRtcpPacket rtcp_packet = 4;
33 40
34 // optional - but required if type == DEBUG_EVENT 41 // optional - but required if type == DEBUG_EVENT
35 optional ACMDumpDebugEvent debug_event = 4; 42 optional ACMDumpDebugEvent debug_event = 5;
36 43
37 // optional - but required if type == CONFIG_EVENT 44 // optional - but required if type == RECEIVER_CONFIG_EVENT
38 optional ACMDumpConfigEvent config = 5; 45 optional ACMDumpVideoReceiveConfig receiver_config = 6;
46
47 // optional - but required if type == SENDER_CONFIG_EVENT
48 optional ACMDumpVideoSendConfig sender_config = 7;
49
50 // optional - but required if type == AUDIO_RECEIVER_CONFIG_EVENT
51 optional ACMDumpAudioReceiveConfig audio_receiver_config = 8;
52
53 // optional - but required if type == AUDIO_SENDER_CONFIG_EVENT
54 optional ACMDumpAudioSendConfig audio_sender_config = 9;
39 } 55 }
40 56
41 57
42 message ACMDumpRTPPacket { 58 message ACMDumpRtpPacket {
43 // Indicates if the packet is incoming or outgoing with respect to the user 59 // Indicates if the packet is incoming or outgoing with respect to the user
44 // that is logging the data. 60 // that is logging the data.
45 enum Direction { 61 enum Direction {
62 UNKNOWN_DIRECTION = 0;
63 OUTGOING = 1;
64 INCOMING = 2;
65 }
66 enum PayloadType {
67 UNKNOWN_TYPE = 0;
68 AUDIO = 1;
69 VIDEO = 2;
70 RTX = 3; // TODO(terelius): Where does this get set?
ivoc 2015/07/14 12:13:14 Nowhere yet :-) We should change that.
terelius 2015/07/16 12:47:03 I mean that I don't think the RTX flag makes any s
ivoc 2015/07/17 12:14:28 Okay, makes sense, feel free to remove it in that
71 }
72
73 // required
74 optional Direction direction = 1;
75
76 // required
77 optional PayloadType type = 2;
78
79 // required - The size of the packet including both payload and header.
80 optional uint32 packet_length = 3;
81
82 // required - The RTP header only.
83 optional bytes header = 4;
84
85 // Logging payloads for user data requires privacy review. Don't uncomment.
86 // optional bytes payload = 5;
stefan-webrtc 2015/07/14 13:28:56 Can we simply not add this until we actually need
ivoc 2015/07/14 13:58:03 +1
terelius 2015/07/16 12:47:03 I would *very* strongly advise against this. We sh
ivoc 2015/07/17 12:14:28 I think we were trying to argue that these two lin
terelius 2015/07/17 17:48:33 I missed this comment in my last reply. Based on
minyue-webrtc 2015/07/21 12:22:46 I do not know the privacy policy well enough. But
87 }
88
89
90 message ACMDumpRtcpPacket {
91 // Indicates if the packet is incoming or outgoing with respect to the user
92 // that is logging the data.
93 enum Direction {
46 UNKNOWN_DIRECTION = 0; 94 UNKNOWN_DIRECTION = 0;
47 OUTGOING = 1; 95 OUTGOING = 1;
48 INCOMING = 2; 96 INCOMING = 2;
49 } 97 }
98 // RTX is not used for RTCP packets.
stefan-webrtc 2015/07/14 13:28:56 I don't think this is necessary to comment on.
terelius 2015/07/16 12:47:03 Done.
50 enum PayloadType { 99 enum PayloadType {
51 UNKNOWN_TYPE = 0; 100 UNKNOWN_TYPE = 0;
52 AUDIO = 1; 101 AUDIO = 1;
53 VIDEO = 2; 102 VIDEO = 2;
54 RTX = 3;
55 } 103 }
56 104
57 // required 105 // required
58 optional Direction direction = 1; 106 optional Direction direction = 1;
59 107
60 // required 108 // required
61 optional PayloadType type = 2; 109 optional PayloadType type = 2;
62 110
63 // required - Contains the whole RTP packet (header+payload). 111 // required - The whole packet including both payload and header.
64 optional bytes RTP_data = 3; 112 optional bytes data = 3;
65 } 113 }
66 114
67 115
68 message ACMDumpDebugEvent { 116 message ACMDumpDebugEvent {
69 // Indicates the type of the debug event. 117 // Indicates the type of the debug event.
70 // LOG_START and LOG_END indicate the start and end of the log respectively. 118 // LOG_START and LOG_END indicate the start and end of the log respectively.
71 // AUDIO_PLAYOUT indicates a call to the PlayoutData10Ms() function in ACM. 119 // AUDIO_PLAYOUT indicates a call to the PlayoutData10Ms() function in ACM.
72 enum EventType { 120 enum EventType {
73 UNKNOWN_EVENT = 0; 121 UNKNOWN_EVENT = 0;
74 LOG_START = 1; 122 LOG_START = 1;
75 LOG_END = 2; 123 LOG_END = 2;
76 AUDIO_PLAYOUT = 3; 124 AUDIO_PLAYOUT = 3;
77 } 125 }
78 126
79 // required 127 // required
80 optional EventType type = 1; 128 optional EventType type = 1;
81 129
82 // An optional message that can be used to store additional information about 130 // An optional message that can be used to store additional information about
83 // the debug event. 131 // the debug event.
84 optional string message = 2; 132 optional string message = 2;
85 } 133 }
86 134
87 135
88 // TODO(terelius): Video and audio streams could in principle share SSRC, 136 // TODO(terelius): Video and audio streams could in principle share SSRC,
89 // so identifying a stream based only on SSRC might not work. 137 // so identifying a stream based only on SSRC might not work.
90 // It might be better to use a combination of SSRC and media type 138 // It might be better to use a combination of SSRC and media type
91 // or SSRC and port number, but for now we will rely on SSRC only. 139 // or SSRC and port number, but for now we will rely on SSRC only.
92 message ACMDumpConfigEvent { 140 message ACMDumpVideoReceiveConfig {
93 // Synchronization source (stream identifier) to be received. 141 // required - Synchronization source (stream identifier) to be received.
94 optional uint32 remote_ssrc = 1; 142 optional uint32 remote_ssrc = 1;
143 // required - Sender SSRC used for sending RTCP (such as receiver reports).
144 optional uint32 local_ssrc = 2;
95 145
96 // RTX settings for incoming video payloads that may be received. RTX is 146 // Compound mode is described by RFC 4585 and reduced-size
97 // disabled if there's no config present. 147 // RTCP mode is described by RFC 5506.
98 optional RtcpConfig rtcp_config = 3; 148 enum RtcpMode {
149 RTCP_COMPOUND = 1;
150 RTCP_REDUCEDSIZE = 2;
151 }
152 // required - RTCP mode to use.
153 optional RtcpMode rtcp_mode = 3;
154
155 // required - Extended RTCP settings.
156 optional bool receiver_reference_time_report = 4;
157
158 // required - Receiver estimated maximum bandwidth.
159 optional bool remb = 5;
99 160
100 // Map from video RTP payload type -> RTX config. 161 // Map from video RTP payload type -> RTX config.
101 repeated RtxMap rtx_map = 4; 162 repeated RtxMap rtx_map = 6;
102 163
103 // RTP header extensions used for the received stream. 164 // RTP header extensions used for the received stream.
104 repeated RtpHeaderExtension header_extensions = 5; 165 repeated RtpHeaderExtension header_extensions = 7;
105 166
106 // List of decoders associated with the stream. 167 // List of decoders associated with the stream.
107 repeated DecoderConfig decoders = 6; 168 repeated DecoderConfig decoders = 8;
108 } 169 }
109 170
110 171
111 // Maps decoder names to payload types. 172 // Maps decoder names to payload types.
112 message DecoderConfig { 173 message DecoderConfig {
113 // required 174 // required
114 optional string name = 1; 175 optional string name = 1;
115 176
116 // required 177 // required
117 optional sint32 payload_type = 2; 178 optional sint32 payload_type = 2;
118 } 179 }
119 180
120 181
121 // Maps RTP header extension names to numerical ids. 182 // Maps RTP header extension names to numerical IDs.
122 message RtpHeaderExtension { 183 message RtpHeaderExtension {
123 // required 184 // required
124 optional string name = 1; 185 optional string name = 1;
125 186
126 // required 187 // required
127 optional sint32 id = 2; 188 optional sint32 id = 2;
128 } 189 }
129 190
130 191
131 // RTX settings for incoming video payloads that may be received. 192 // RTX settings for incoming video payloads that may be received.
132 // RTX is disabled if there's no config present. 193 // RTX is disabled if there's no config present.
133 message RtxConfig { 194 message RtxConfig {
134 // required - SSRCs to use for the RTX streams. 195 // required - SSRC to use for the RTX stream.
135 optional uint32 ssrc = 1; 196 optional uint32 rtx_ssrc = 1;
136 197
137 // required - Payload type to use for the RTX stream. 198 // required - Payload type to use for the RTX stream.
138 optional sint32 payload_type = 2; 199 optional sint32 rtx_payload_type = 2;
139 } 200 }
140 201
141 202
142 message RtxMap { 203 message RtxMap {
143 // required 204 // required
144 optional sint32 payload_type = 1; 205 optional sint32 payload_type = 1;
145 206
146 // required 207 // required
147 optional RtxConfig config = 2; 208 optional RtxConfig config = 2;
148 } 209 }
149 210
150 211
151 // Configuration information for RTCP. 212 message ACMDumpVideoSendConfig {
152 // For bandwidth estimation purposes it is more interesting to log the 213 // Synchronization source (stream identifier) for outgoing stream.
153 // RTCP messages that the sender receives, but we will support logging 214 // One stream can have several ssrcs for e.g. simulcast.
154 // at the receiver side too. 215 // At least one ssrc is required.
155 message RtcpConfig { 216 repeated uint32 ssrcs = 1;
156 // Sender SSRC used for sending RTCP (such as receiver reports).
157 optional uint32 local_ssrc = 1;
158 217
159 // RTCP mode to use. Compound mode is described by RFC 4585 and reduced-size 218 // RTP header extensions used for the outgoing stream.
160 // RTCP mode is described by RFC 5506. 219 repeated RtpHeaderExtension header_extensions = 2;
161 enum RtcpMode {RTCP_COMPOUND = 1; RTCP_REDUCEDSIZE = 2;}
162 optional RtcpMode rtcp_mode = 2;
163 220
164 // Extended RTCP settings. 221 // List of SSRCs for retransmitted packets.
165 optional bool receiver_reference_time_report = 3; 222 repeated uint32 rtx_ssrcs = 3;
166 223
167 // Receiver estimated maximum bandwidth. 224 // required if rtx_ssrcs is used - Payload type for retransmitted packets.
168 optional bool remb = 4; 225 optional sint32 rtx_payload_type = 4;
226
227 // required - Canonical end-point identifier.
228 optional string c_name = 5;
229
230 // required - Encoder associated with the stream.
231 optional EncoderConfig encoder = 6;
169 } 232 }
233
234
235 // Maps encoder names to payload types.
236 message EncoderConfig {
237 // required
238 optional string name = 1;
239
240 // required
241 optional sint32 payload_type = 2;
242 }
243
244
245 message ACMDumpAudioReceiveConfig {
246 // TODO(terelius): Figure out what the requirements are from the audio team.
ivoc 2015/07/14 12:13:14 I will try to look into that.
terelius 2015/07/16 12:47:03 Acknowledged.
247 }
248
249
250 message ACMDumpAudioSendConfig {
251 // TODO(terelius): Figure out what the requirements are from the audio team.
252 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698