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 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
54 } else { | 54 } else { |
55 // No clock implementation provided, use default clock. | 55 // No clock implementation provided, use default clock. |
56 RtpRtcp::Configuration configuration_copy; | 56 RtpRtcp::Configuration configuration_copy; |
57 memcpy(&configuration_copy, &configuration, | 57 memcpy(&configuration_copy, &configuration, |
58 sizeof(RtpRtcp::Configuration)); | 58 sizeof(RtpRtcp::Configuration)); |
59 configuration_copy.clock = Clock::GetRealTimeClock(); | 59 configuration_copy.clock = Clock::GetRealTimeClock(); |
60 return new ModuleRtpRtcpImpl(configuration_copy); | 60 return new ModuleRtpRtcpImpl(configuration_copy); |
61 } | 61 } |
62 } | 62 } |
63 | 63 |
64 // Deprecated. | |
65 inline int32_t RtpRtcp::SetFecParameters( | |
danilchap
2016/10/28 11:16:11
since it is in .cc remove inline (you might get li
brandtr
2016/10/28 12:10:03
Done.
| |
66 const FecProtectionParams* delta_params, | |
67 const FecProtectionParams* key_params) { | |
68 RTC_DCHECK(delta_params); | |
69 RTC_DCHECK(key_params); | |
70 return SetFecParameters(*delta_params, *key_params) ? 0 : -1; | |
71 } | |
72 | |
64 ModuleRtpRtcpImpl::ModuleRtpRtcpImpl(const Configuration& configuration) | 73 ModuleRtpRtcpImpl::ModuleRtpRtcpImpl(const Configuration& configuration) |
65 : rtp_sender_(configuration.audio, | 74 : rtp_sender_(configuration.audio, |
66 configuration.clock, | 75 configuration.clock, |
67 configuration.outgoing_transport, | 76 configuration.outgoing_transport, |
68 configuration.paced_sender, | 77 configuration.paced_sender, |
69 configuration.transport_sequence_number_allocator, | 78 configuration.transport_sequence_number_allocator, |
70 configuration.transport_feedback_callback, | 79 configuration.transport_feedback_callback, |
71 configuration.send_bitrate_observer, | 80 configuration.send_bitrate_observer, |
72 configuration.send_frame_count_observer, | 81 configuration.send_frame_count_observer, |
73 configuration.send_side_delay_observer, | 82 configuration.send_side_delay_observer, |
(...skipping 713 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
787 const uint8_t picture_id) { | 796 const uint8_t picture_id) { |
788 return rtcp_sender_.SendRTCP( | 797 return rtcp_sender_.SendRTCP( |
789 GetFeedbackState(), kRtcpSli, 0, 0, false, picture_id); | 798 GetFeedbackState(), kRtcpSli, 0, 0, false, picture_id); |
790 } | 799 } |
791 | 800 |
792 void ModuleRtpRtcpImpl::SetUlpfecConfig(int red_payload_type, | 801 void ModuleRtpRtcpImpl::SetUlpfecConfig(int red_payload_type, |
793 int ulpfec_payload_type) { | 802 int ulpfec_payload_type) { |
794 rtp_sender_.SetUlpfecConfig(red_payload_type, ulpfec_payload_type); | 803 rtp_sender_.SetUlpfecConfig(red_payload_type, ulpfec_payload_type); |
795 } | 804 } |
796 | 805 |
797 int32_t ModuleRtpRtcpImpl::SetFecParameters( | 806 bool ModuleRtpRtcpImpl::SetFecParameters( |
798 const FecProtectionParams* delta_params, | 807 const FecProtectionParams& delta_params, |
799 const FecProtectionParams* key_params) { | 808 const FecProtectionParams& key_params) { |
800 return rtp_sender_.SetFecParameters(delta_params, key_params); | 809 return rtp_sender_.SetFecParameters(delta_params, key_params); |
801 } | 810 } |
802 | 811 |
803 void ModuleRtpRtcpImpl::SetRemoteSSRC(const uint32_t ssrc) { | 812 void ModuleRtpRtcpImpl::SetRemoteSSRC(const uint32_t ssrc) { |
804 // Inform about the incoming SSRC. | 813 // Inform about the incoming SSRC. |
805 rtcp_sender_.SetRemoteSSRC(ssrc); | 814 rtcp_sender_.SetRemoteSSRC(ssrc); |
806 rtcp_receiver_.SetRemoteSSRC(ssrc); | 815 rtcp_receiver_.SetRemoteSSRC(ssrc); |
807 | 816 |
808 // Check for a SSRC collision. | 817 // Check for a SSRC collision. |
809 if (rtp_sender_.SSRC() == ssrc && !collision_detected_) { | 818 if (rtp_sender_.SSRC() == ssrc && !collision_detected_) { |
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
925 void ModuleRtpRtcpImpl::RegisterSendChannelRtpStatisticsCallback( | 934 void ModuleRtpRtcpImpl::RegisterSendChannelRtpStatisticsCallback( |
926 StreamDataCountersCallback* callback) { | 935 StreamDataCountersCallback* callback) { |
927 rtp_sender_.RegisterRtpStatisticsCallback(callback); | 936 rtp_sender_.RegisterRtpStatisticsCallback(callback); |
928 } | 937 } |
929 | 938 |
930 StreamDataCountersCallback* | 939 StreamDataCountersCallback* |
931 ModuleRtpRtcpImpl::GetSendChannelRtpStatisticsCallback() const { | 940 ModuleRtpRtcpImpl::GetSendChannelRtpStatisticsCallback() const { |
932 return rtp_sender_.GetRtpStatisticsCallback(); | 941 return rtp_sender_.GetRtpStatisticsCallback(); |
933 } | 942 } |
934 } // namespace webrtc | 943 } // namespace webrtc |
OLD | NEW |