OLD | NEW |
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 message ACMDumpEvent { | 14 message ACMDumpEvent { |
14 // 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. |
15 optional int64 timestamp_us = 1; | 16 optional int64 timestamp_us = 1; |
16 | 17 |
17 // 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 |
18 // 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 |
19 // receive the new events as UNKNOWN_EVENT. | 20 // receive the new events as UNKNOWN_EVENT. |
20 enum EventType { | 21 enum EventType { |
21 UNKNOWN_EVENT = 0; | 22 UNKNOWN_EVENT = 0; |
22 RTP_EVENT = 1; | 23 RTP_EVENT = 1; |
23 DEBUG_EVENT = 2; | 24 DEBUG_EVENT = 2; |
| 25 CONFIG_EVENT = 3; |
24 } | 26 } |
25 | 27 |
26 // required - Indicates the type of this event | 28 // required - Indicates the type of this event |
27 optional EventType type = 2; | 29 optional EventType type = 2; |
28 | 30 |
29 // optional - but required if type == RTP_EVENT | 31 // optional - but required if type == RTP_EVENT |
30 optional ACMDumpRTPPacket packet = 3; | 32 optional ACMDumpRTPPacket packet = 3; |
31 | 33 |
32 // optional - but required if type == DEBUG_EVENT | 34 // optional - but required if type == DEBUG_EVENT |
33 optional ACMDumpDebugEvent debug_event = 4; | 35 optional ACMDumpDebugEvent debug_event = 4; |
| 36 |
| 37 // optional - but required if type == CONFIG_EVENT |
| 38 optional ACMDumpConfigEvent config = 5; |
34 } | 39 } |
35 | 40 |
| 41 |
36 message ACMDumpRTPPacket { | 42 message ACMDumpRTPPacket { |
37 // Indicates if the packet is incoming or outgoing with respect to the user | 43 // Indicates if the packet is incoming or outgoing with respect to the user |
38 // that is logging the data. | 44 // that is logging the data. |
39 enum Direction { | 45 enum Direction { |
40 UNKNOWN_DIRECTION = 0; | 46 UNKNOWN_DIRECTION = 0; |
41 OUTGOING = 1; | 47 OUTGOING = 1; |
42 INCOMING = 2; | 48 INCOMING = 2; |
43 } | 49 } |
44 enum PayloadType { | 50 enum PayloadType { |
45 UNKNOWN_TYPE = 0; | 51 UNKNOWN_TYPE = 0; |
46 AUDIO = 1; | 52 AUDIO = 1; |
47 VIDEO = 2; | 53 VIDEO = 2; |
48 RTX = 3; | 54 RTX = 3; |
49 } | 55 } |
50 | 56 |
51 // required | 57 // required |
52 optional Direction direction = 1; | 58 optional Direction direction = 1; |
53 | 59 |
54 // required | 60 // required |
55 optional PayloadType type = 2; | 61 optional PayloadType type = 2; |
56 | 62 |
57 // required - Contains the whole RTP packet (header+payload). | 63 // required - Contains the whole RTP packet (header+payload). |
58 optional bytes RTP_data = 3; | 64 optional bytes RTP_data = 3; |
59 } | 65 } |
60 | 66 |
| 67 |
61 message ACMDumpDebugEvent { | 68 message ACMDumpDebugEvent { |
62 // Indicates the type of the debug event. | 69 // Indicates the type of the debug event. |
63 // LOG_START and LOG_END indicate the start and end of the log respectively. | 70 // LOG_START and LOG_END indicate the start and end of the log respectively. |
64 // AUDIO_PLAYOUT indicates a call to the PlayoutData10Ms() function in ACM. | 71 // AUDIO_PLAYOUT indicates a call to the PlayoutData10Ms() function in ACM. |
65 enum EventType { | 72 enum EventType { |
66 UNKNOWN_EVENT = 0; | 73 UNKNOWN_EVENT = 0; |
67 LOG_START = 1; | 74 LOG_START = 1; |
68 LOG_END = 2; | 75 LOG_END = 2; |
69 AUDIO_PLAYOUT = 3; | 76 AUDIO_PLAYOUT = 3; |
70 } | 77 } |
71 | 78 |
72 // required | 79 // required |
73 optional EventType type = 1; | 80 optional EventType type = 1; |
74 | 81 |
75 // An optional message that can be used to store additional information about | 82 // An optional message that can be used to store additional information about |
76 // the debug event. | 83 // the debug event. |
77 optional string message = 2; | 84 optional string message = 2; |
78 } | 85 } |
| 86 |
| 87 |
| 88 // TODO(terelius): Video and audio streams could in principle share SSRC, |
| 89 // 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 |
| 91 // or SSRC and port number, but for now we will rely on SSRC only. |
| 92 message ACMDumpConfigEvent { |
| 93 // Synchronization source (stream identifier) to be received. |
| 94 optional uint32 remote_ssrc = 1; |
| 95 |
| 96 // RTX settings for incoming video payloads that may be received. RTX is |
| 97 // disabled if there's no config present. |
| 98 optional RtcpConfig rtcp_config = 3; |
| 99 |
| 100 // Map from video RTP payload type -> RTX config. |
| 101 repeated RtxMap rtx_map = 4; |
| 102 |
| 103 // RTP header extensions used for the received stream. |
| 104 repeated RtpHeaderExtension header_extensions = 5; |
| 105 |
| 106 // List of decoders associated with the stream. |
| 107 repeated DecoderConfig decoders = 6; |
| 108 } |
| 109 |
| 110 |
| 111 // Maps decoder names to payload types. |
| 112 message DecoderConfig { |
| 113 // required |
| 114 optional string name = 1; |
| 115 |
| 116 // required |
| 117 optional sint32 payload_type = 2; |
| 118 } |
| 119 |
| 120 |
| 121 // Maps RTP header extension names to numerical ids. |
| 122 message RtpHeaderExtension { |
| 123 // required |
| 124 optional string name = 1; |
| 125 |
| 126 // required |
| 127 optional sint32 id = 2; |
| 128 } |
| 129 |
| 130 |
| 131 // RTX settings for incoming video payloads that may be received. |
| 132 // RTX is disabled if there's no config present. |
| 133 message RtxConfig { |
| 134 // required - SSRCs to use for the RTX streams. |
| 135 optional uint32 ssrc = 1; |
| 136 |
| 137 // required - Payload type to use for the RTX stream. |
| 138 optional sint32 payload_type = 2; |
| 139 } |
| 140 |
| 141 |
| 142 message RtxMap { |
| 143 // required |
| 144 optional sint32 payload_type = 1; |
| 145 |
| 146 // required |
| 147 optional RtxConfig config = 2; |
| 148 } |
| 149 |
| 150 |
| 151 // Configuration information for RTCP. |
| 152 // For bandwidth estimation purposes it is more interesting to log the |
| 153 // RTCP messages that the sender receives, but we will support logging |
| 154 // at the receiver side too. |
| 155 message RtcpConfig { |
| 156 // Sender SSRC used for sending RTCP (such as receiver reports). |
| 157 optional uint32 local_ssrc = 1; |
| 158 |
| 159 // RTCP mode to use. Compound mode is described by RFC 4585 and reduced-size |
| 160 // RTCP mode is described by RFC 5506. |
| 161 enum RtcpMode {RTCP_COMPOUND = 1; RTCP_REDUCEDSIZE = 2;} |
| 162 optional RtcpMode rtcp_mode = 2; |
| 163 |
| 164 // Extended RTCP settings. |
| 165 optional bool receiver_reference_time_report = 3; |
| 166 |
| 167 // Receiver estimated maximum bandwidth. |
| 168 optional bool remb = 4; |
| 169 } |
OLD | NEW |