OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 12 matching lines...) Expand all Loading... |
23 // Disable warning C4355: 'this' : used in base member initializer list. | 23 // Disable warning C4355: 'this' : used in base member initializer list. |
24 #pragma warning(disable : 4355) | 24 #pragma warning(disable : 4355) |
25 #endif | 25 #endif |
26 | 26 |
27 namespace webrtc { | 27 namespace webrtc { |
28 | 28 |
29 RtpRtcp::Configuration::Configuration() | 29 RtpRtcp::Configuration::Configuration() |
30 : id(-1), | 30 : id(-1), |
31 audio(false), | 31 audio(false), |
32 receiver_only(false), | 32 receiver_only(false), |
33 clock(NULL), | 33 clock(nullptr), |
34 receive_statistics(NullObjectReceiveStatistics()), | 34 receive_statistics(NullObjectReceiveStatistics()), |
35 outgoing_transport(NULL), | 35 outgoing_transport(nullptr), |
36 intra_frame_callback(NULL), | 36 intra_frame_callback(nullptr), |
37 bandwidth_callback(NULL), | 37 bandwidth_callback(nullptr), |
38 rtt_stats(NULL), | 38 rtt_stats(nullptr), |
39 rtcp_packet_type_counter_observer(NULL), | 39 rtcp_packet_type_counter_observer(nullptr), |
40 audio_messages(NullObjectRtpAudioFeedback()), | 40 audio_messages(NullObjectRtpAudioFeedback()), |
41 remote_bitrate_estimator(NULL), | 41 remote_bitrate_estimator(nullptr), |
42 paced_sender(NULL), | 42 paced_sender(nullptr), |
43 send_bitrate_observer(NULL), | 43 packet_router(nullptr), |
44 send_frame_count_observer(NULL), | 44 send_bitrate_observer(nullptr), |
45 send_side_delay_observer(NULL) { | 45 send_frame_count_observer(nullptr), |
| 46 send_side_delay_observer(nullptr) { |
46 } | 47 } |
47 | 48 |
48 RtpRtcp* RtpRtcp::CreateRtpRtcp(const RtpRtcp::Configuration& configuration) { | 49 RtpRtcp* RtpRtcp::CreateRtpRtcp(const RtpRtcp::Configuration& configuration) { |
49 if (configuration.clock) { | 50 if (configuration.clock) { |
50 return new ModuleRtpRtcpImpl(configuration); | 51 return new ModuleRtpRtcpImpl(configuration); |
51 } else { | 52 } else { |
52 // No clock implementation provided, use default clock. | 53 // No clock implementation provided, use default clock. |
53 RtpRtcp::Configuration configuration_copy; | 54 RtpRtcp::Configuration configuration_copy; |
54 memcpy(&configuration_copy, &configuration, | 55 memcpy(&configuration_copy, &configuration, |
55 sizeof(RtpRtcp::Configuration)); | 56 sizeof(RtpRtcp::Configuration)); |
56 configuration_copy.clock = Clock::GetRealTimeClock(); | 57 configuration_copy.clock = Clock::GetRealTimeClock(); |
57 return new ModuleRtpRtcpImpl(configuration_copy); | 58 return new ModuleRtpRtcpImpl(configuration_copy); |
58 } | 59 } |
59 } | 60 } |
60 | 61 |
61 ModuleRtpRtcpImpl::ModuleRtpRtcpImpl(const Configuration& configuration) | 62 ModuleRtpRtcpImpl::ModuleRtpRtcpImpl(const Configuration& configuration) |
62 : rtp_sender_(configuration.id, | 63 : rtp_sender_(configuration.id, |
63 configuration.audio, | 64 configuration.audio, |
64 configuration.clock, | 65 configuration.clock, |
65 configuration.outgoing_transport, | 66 configuration.outgoing_transport, |
66 configuration.audio_messages, | 67 configuration.audio_messages, |
67 configuration.paced_sender, | 68 configuration.paced_sender, |
| 69 configuration.packet_router, |
| 70 configuration.send_time_callback, |
68 configuration.send_bitrate_observer, | 71 configuration.send_bitrate_observer, |
69 configuration.send_frame_count_observer, | 72 configuration.send_frame_count_observer, |
70 configuration.send_side_delay_observer), | 73 configuration.send_side_delay_observer), |
71 rtcp_sender_(configuration.id, | 74 rtcp_sender_(configuration.id, |
72 configuration.audio, | 75 configuration.audio, |
73 configuration.clock, | 76 configuration.clock, |
74 configuration.receive_statistics, | 77 configuration.receive_statistics, |
75 configuration.rtcp_packet_type_counter_observer), | 78 configuration.rtcp_packet_type_counter_observer), |
76 rtcp_receiver_(configuration.id, | 79 rtcp_receiver_(configuration.id, |
77 configuration.clock, | 80 configuration.clock, |
(...skipping 916 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
994 void ModuleRtpRtcpImpl::RegisterSendChannelRtpStatisticsCallback( | 997 void ModuleRtpRtcpImpl::RegisterSendChannelRtpStatisticsCallback( |
995 StreamDataCountersCallback* callback) { | 998 StreamDataCountersCallback* callback) { |
996 rtp_sender_.RegisterRtpStatisticsCallback(callback); | 999 rtp_sender_.RegisterRtpStatisticsCallback(callback); |
997 } | 1000 } |
998 | 1001 |
999 StreamDataCountersCallback* | 1002 StreamDataCountersCallback* |
1000 ModuleRtpRtcpImpl::GetSendChannelRtpStatisticsCallback() const { | 1003 ModuleRtpRtcpImpl::GetSendChannelRtpStatisticsCallback() const { |
1001 return rtp_sender_.GetRtpStatisticsCallback(); | 1004 return rtp_sender_.GetRtpStatisticsCallback(); |
1002 } | 1005 } |
1003 } // namespace webrtc | 1006 } // namespace webrtc |
OLD | NEW |