OLD | NEW |
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 #ifndef MEDIA_CAST_TRANSPORT_CAST_TRANSPORT_CONFIG_H_ | 5 #ifndef MEDIA_CAST_TRANSPORT_CAST_TRANSPORT_CONFIG_H_ |
6 #define MEDIA_CAST_TRANSPORT_CAST_TRANSPORT_CONFIG_H_ | 6 #define MEDIA_CAST_TRANSPORT_CAST_TRANSPORT_CONFIG_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 25 matching lines...) Expand all Loading... |
36 kAudioCodecLast = kExternalAudio | 36 kAudioCodecLast = kExternalAudio |
37 }; | 37 }; |
38 | 38 |
39 struct RtpConfig { | 39 struct RtpConfig { |
40 RtpConfig(); | 40 RtpConfig(); |
41 int history_ms; // The time RTP packets are stored for retransmissions. | 41 int history_ms; // The time RTP packets are stored for retransmissions. |
42 int max_delay_ms; | 42 int max_delay_ms; |
43 int payload_type; | 43 int payload_type; |
44 }; | 44 }; |
45 | 45 |
46 struct CastTransportConfig { | 46 struct CastTransportBaseConfig { |
47 CastTransportConfig(); | 47 CastTransportBaseConfig(); |
48 ~CastTransportConfig(); | 48 ~CastTransportBaseConfig(); |
49 | 49 |
50 // Transport: Local receiver. | 50 uint32 ssrc; |
51 net::IPEndPoint receiver_endpoint; | 51 RtpConfig rtp_config; |
52 net::IPEndPoint local_endpoint; | |
53 | |
54 uint32 audio_ssrc; | |
55 uint32 video_ssrc; | |
56 | |
57 VideoCodec video_codec; | |
58 AudioCodec audio_codec; | |
59 | |
60 // RTP. | |
61 RtpConfig audio_rtp_config; | |
62 RtpConfig video_rtp_config; | |
63 | |
64 int audio_frequency; | |
65 int audio_channels; | |
66 | |
67 std::string aes_key; // Binary string of size kAesKeySize. | 52 std::string aes_key; // Binary string of size kAesKeySize. |
68 std::string aes_iv_mask; // Binary string of size kAesBlockSize. | 53 std::string aes_iv_mask; // Binary string of size kAesBlockSize. |
69 }; | 54 }; |
70 | 55 |
| 56 struct CastTransportAudioConfig { |
| 57 CastTransportAudioConfig(); |
| 58 ~CastTransportAudioConfig(); |
| 59 |
| 60 CastTransportBaseConfig base; |
| 61 AudioCodec codec; |
| 62 int frequency; |
| 63 int channels; |
| 64 }; |
| 65 |
| 66 struct CastTransportVideoConfig { |
| 67 CastTransportVideoConfig(); |
| 68 ~CastTransportVideoConfig(); |
| 69 |
| 70 CastTransportBaseConfig base; |
| 71 VideoCodec codec; |
| 72 }; |
| 73 |
71 struct EncodedVideoFrame { | 74 struct EncodedVideoFrame { |
72 EncodedVideoFrame(); | 75 EncodedVideoFrame(); |
73 ~EncodedVideoFrame(); | 76 ~EncodedVideoFrame(); |
74 | 77 |
75 VideoCodec codec; | 78 VideoCodec codec; |
76 bool key_frame; | 79 bool key_frame; |
77 uint32 frame_id; | 80 uint32 frame_id; |
78 uint32 last_referenced_frame_id; | 81 uint32 last_referenced_frame_id; |
79 uint32 rtp_timestamp; | 82 uint32 rtp_timestamp; |
80 std::string data; | 83 std::string data; |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
173 lhs.rtp_timestamp == rhs.rtp_timestamp && | 176 lhs.rtp_timestamp == rhs.rtp_timestamp && |
174 lhs.send_packet_count == rhs.send_packet_count && | 177 lhs.send_packet_count == rhs.send_packet_count && |
175 lhs.send_octet_count == rhs.send_octet_count; | 178 lhs.send_octet_count == rhs.send_octet_count; |
176 } | 179 } |
177 | 180 |
178 } // namespace transport | 181 } // namespace transport |
179 } // namespace cast | 182 } // namespace cast |
180 } // namespace media | 183 } // namespace media |
181 | 184 |
182 #endif // MEDIA_CAST_TRANSPORT_CAST_TRANSPORT_CONFIG_H_ | 185 #endif // MEDIA_CAST_TRANSPORT_CAST_TRANSPORT_CONFIG_H_ |
OLD | NEW |