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

Side by Side Diff: media/cast/logging/proto/raw_events.proto

Issue 270493003: Cast: Deduplicate event types in cast library. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 7 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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 // Protocol for audio messages. 5 // Protocol for audio messages.
6 6
7 syntax = "proto2"; 7 syntax = "proto2";
8 8
9 option optimize_for = LITE_RUNTIME; 9 option optimize_for = LITE_RUNTIME;
10 10
11 package media.cast.proto; 11 package media.cast.proto;
12 12
13 // Keep in sync with media/cast/logging/logging_defines.h. 13 // Keep in sync with media/cast/logging/logging_defines.h.
14 // For compatibility reasons, existing values in this enum must not be changed. 14 // For compatibility reasons, existing values in this enum must not be changed.
15 enum EventType { 15 enum EventType {
16 UNKNOWN = 0; 16 UNKNOWN = 0;
17
18 // Note: 1-28 are deprecated in favor of unified event types. Do not use.
17 // Generic events. No longer used. 19 // Generic events. No longer used.
18 RTT_MS = 1; 20 RTT_MS = 1;
19 PACKET_LOSS = 2; 21 PACKET_LOSS = 2;
20 JITTER_MS = 3; 22 JITTER_MS = 3;
21 VIDEO_ACK_RECEIVED = 4; // Sender side frame event. 23 VIDEO_ACK_RECEIVED = 4; // Sender side frame event.
22 REMB_BITRATE = 5; // Generic event. No longer used. 24 REMB_BITRATE = 5; // Generic event. No longer used.
23 // Audio receiver. 25 // Audio receiver.
24 AUDIO_ACK_SENT = 6; 26 AUDIO_ACK_SENT = 6;
25 // Video receiver. 27 // Video receiver.
26 VIDEO_ACK_SENT = 7; 28 VIDEO_ACK_SENT = 7;
(...skipping 17 matching lines...) Expand all
44 // VIDEO_PACKET_SENT_TO_PACER = 20; // Deprecated 46 // VIDEO_PACKET_SENT_TO_PACER = 20; // Deprecated
45 AUDIO_PACKET_SENT_TO_NETWORK = 21; 47 AUDIO_PACKET_SENT_TO_NETWORK = 21;
46 VIDEO_PACKET_SENT_TO_NETWORK = 22; 48 VIDEO_PACKET_SENT_TO_NETWORK = 22;
47 AUDIO_PACKET_RETRANSMITTED = 23; 49 AUDIO_PACKET_RETRANSMITTED = 23;
48 VIDEO_PACKET_RETRANSMITTED = 24; 50 VIDEO_PACKET_RETRANSMITTED = 24;
49 // Receiver-side packet events. 51 // Receiver-side packet events.
50 AUDIO_PACKET_RECEIVED = 25; 52 AUDIO_PACKET_RECEIVED = 25;
51 VIDEO_PACKET_RECEIVED = 26; 53 VIDEO_PACKET_RECEIVED = 26;
52 DUPLICATE_AUDIO_PACKET_RECEIVED = 27; 54 DUPLICATE_AUDIO_PACKET_RECEIVED = 27;
53 DUPLICATE_VIDEO_PACKET_RECEIVED = 28; 55 DUPLICATE_VIDEO_PACKET_RECEIVED = 28;
56
57
58 // New, unified event types.
59 FRAME_CAPTURE_BEGIN = 29;
60 FRAME_CAPTURE_END = 30;
61 FRAME_ENCODED = 31;
62 FRAME_ACK_RECEIVED = 32;
63 FRAME_ACK_SENT = 33;
64 FRAME_DECODED = 34;
65 FRAME_PLAYOUT = 35;
66 PACKET_SENT_TO_NETWORK = 36;
67 PACKET_RETRANSMITTED = 37;
68 PACKET_RECEIVED = 38;
54 } 69 }
55 70
56 // Each log will contain one |LogMetadata|. 71 // Each log will contain one |LogMetadata|.
57 message LogMetadata { 72 message LogMetadata {
58 // |true| if the events are related to audio. |false| if they are related to 73 // |true| if the events are related to audio. |false| if they are related to
59 // video. 74 // video.
60 optional bool is_audio = 1; 75 optional bool is_audio = 1;
61 76
62 // Used as a reference for all event entries. 77 // Used as a reference for all event entries.
63 // i.e. the original RTP timestamp for each event will be 78 // i.e. the original RTP timestamp for each event will be
(...skipping 15 matching lines...) Expand all
79 message AggregatedFrameEvent { 94 message AggregatedFrameEvent {
80 optional uint32 relative_rtp_timestamp = 1; 95 optional uint32 relative_rtp_timestamp = 1;
81 96
82 repeated EventType event_type = 2 [packed = true]; 97 repeated EventType event_type = 2 [packed = true];
83 98
84 // The internal timestamp value in milliseconds. Use 99 // The internal timestamp value in milliseconds. Use
85 // LogMetadata.reference_timestamp_ms_at_unix_epoch to relate to a real time 100 // LogMetadata.reference_timestamp_ms_at_unix_epoch to relate to a real time
86 // and date. 101 // and date.
87 repeated int64 event_timestamp_ms = 3 [packed = true]; 102 repeated int64 event_timestamp_ms = 3 [packed = true];
88 103
89 // Only set if there is a kAudioFrameEncoded and kVideoFrameEncoded event. 104 // Only set if there is a frame encoded event.
90 optional int32 encoded_frame_size = 4; 105 optional int32 encoded_frame_size = 4;
91 106
92 // Only set if there is a kAudioPlayoutDelay or kVideoRenderDelay event. 107 // Only set if there is a frame playout event.
93 optional int32 delay_millis = 5; 108 optional int32 delay_millis = 5;
94 109
95 // Only set if there is a kVideoFrameEncoded event. 110 // Only set if there is a video frame encoded event.
96 optional bool key_frame = 6; 111 optional bool key_frame = 6;
97 112
98 // Only set if there is a kVideoFrameEncoded event. 113 // Only set if there is a video frame encoded event.
99 optional int32 target_bitrate = 7; 114 optional int32 target_bitrate = 7;
100 }; 115 };
101 116
102 message BasePacketEvent { 117 message BasePacketEvent {
103 optional int32 packet_id = 1; 118 optional int32 packet_id = 1;
104 repeated EventType event_type = 2 [packed = true]; 119 repeated EventType event_type = 2 [packed = true];
105 120
106 // The internal timestamp value in milliseconds. Use 121 // The internal timestamp value in milliseconds. Use
107 // LogMetadata.reference_timestamp_ms_at_unix_epoch to relate to a real time 122 // LogMetadata.reference_timestamp_ms_at_unix_epoch to relate to a real time
108 // and date. 123 // and date.
109 repeated int64 event_timestamp_ms = 3 [packed = true]; 124 repeated int64 event_timestamp_ms = 3 [packed = true];
110 125
111 // Size of the packet. 126 // Size of the packet.
112 optional int32 size = 4; 127 optional int32 size = 4;
113 } 128 }
114 129
115 message AggregatedPacketEvent { 130 message AggregatedPacketEvent {
116 optional uint32 relative_rtp_timestamp = 1; 131 optional uint32 relative_rtp_timestamp = 1;
117 repeated BasePacketEvent base_packet_event = 2; 132 repeated BasePacketEvent base_packet_event = 2;
118 }; 133 };
119 134
OLDNEW
« no previous file with comments | « media/cast/logging/proto/proto_utils.cc ('k') | media/cast/logging/receiver_time_offset_estimator_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698