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 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
51 rtcp_packet_type_counter_observer; | 51 rtcp_packet_type_counter_observer; |
52 configuration.paced_sender = paced_sender; | 52 configuration.paced_sender = paced_sender; |
53 configuration.transport_sequence_number_allocator = | 53 configuration.transport_sequence_number_allocator = |
54 transport_sequence_number_allocator; | 54 transport_sequence_number_allocator; |
55 configuration.send_bitrate_observer = nullptr; | 55 configuration.send_bitrate_observer = nullptr; |
56 configuration.send_frame_count_observer = nullptr; | 56 configuration.send_frame_count_observer = nullptr; |
57 configuration.send_side_delay_observer = nullptr; | 57 configuration.send_side_delay_observer = nullptr; |
58 configuration.send_packet_observer = nullptr; | 58 configuration.send_packet_observer = nullptr; |
59 configuration.bandwidth_callback = nullptr; | 59 configuration.bandwidth_callback = nullptr; |
60 configuration.transport_feedback_callback = nullptr; | 60 configuration.transport_feedback_callback = nullptr; |
61 configuration.retransmission_rate_limiter = nullptr; | |
62 | 61 |
63 std::unique_ptr<RtpRtcp> rtp_rtcp(RtpRtcp::CreateRtpRtcp(configuration)); | 62 std::unique_ptr<RtpRtcp> rtp_rtcp(RtpRtcp::CreateRtpRtcp(configuration)); |
64 rtp_rtcp->SetSendingStatus(false); | 63 rtp_rtcp->SetSendingStatus(false); |
65 rtp_rtcp->SetSendingMediaStatus(false); | 64 rtp_rtcp->SetSendingMediaStatus(false); |
66 rtp_rtcp->SetRTCPStatus(RtcpMode::kCompound); | 65 rtp_rtcp->SetRTCPStatus(RtcpMode::kCompound); |
67 | 66 |
68 return rtp_rtcp; | 67 return rtp_rtcp; |
69 } | 68 } |
70 | 69 |
71 static const int kPacketLogIntervalMs = 10000; | 70 static const int kPacketLogIntervalMs = 10000; |
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
179 config_.rtp.fec.red_payload_type, | 178 config_.rtp.fec.red_payload_type, |
180 config_.rtp.fec.ulpfec_payload_type); | 179 config_.rtp.fec.ulpfec_payload_type); |
181 } | 180 } |
182 | 181 |
183 if (config_.rtp.rtcp_xr.receiver_reference_time_report) | 182 if (config_.rtp.rtcp_xr.receiver_reference_time_report) |
184 rtp_rtcp_->SetRtcpXrRrtrStatus(true); | 183 rtp_rtcp_->SetRtcpXrRrtrStatus(true); |
185 | 184 |
186 // Stats callback for CNAME changes. | 185 // Stats callback for CNAME changes. |
187 rtp_rtcp_->RegisterRtcpStatisticsCallback(receive_stats_proxy); | 186 rtp_rtcp_->RegisterRtcpStatisticsCallback(receive_stats_proxy); |
188 | 187 |
| 188 process_thread_->RegisterModule(rtp_receive_statistics_.get()); |
189 process_thread_->RegisterModule(rtp_rtcp_.get()); | 189 process_thread_->RegisterModule(rtp_rtcp_.get()); |
190 } | 190 } |
191 | 191 |
192 RtpStreamReceiver::~RtpStreamReceiver() { | 192 RtpStreamReceiver::~RtpStreamReceiver() { |
| 193 process_thread_->DeRegisterModule(rtp_receive_statistics_.get()); |
193 process_thread_->DeRegisterModule(rtp_rtcp_.get()); | 194 process_thread_->DeRegisterModule(rtp_rtcp_.get()); |
194 | 195 |
195 packet_router_->RemoveRtpModule(rtp_rtcp_.get()); | 196 packet_router_->RemoveRtpModule(rtp_rtcp_.get()); |
196 rtp_rtcp_->SetREMBStatus(false); | 197 rtp_rtcp_->SetREMBStatus(false); |
197 remb_->RemoveReceiveChannel(rtp_rtcp_.get()); | 198 remb_->RemoveReceiveChannel(rtp_rtcp_.get()); |
198 UpdateHistograms(); | 199 UpdateHistograms(); |
199 } | 200 } |
200 | 201 |
201 bool RtpStreamReceiver::SetReceiveCodec(const VideoCodec& video_codec) { | 202 bool RtpStreamReceiver::SetReceiveCodec(const VideoCodec& video_codec) { |
202 int8_t old_pltype = -1; | 203 int8_t old_pltype = -1; |
(...skipping 332 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
535 const std::string& extension, int id) { | 536 const std::string& extension, int id) { |
536 // One-byte-extension local identifiers are in the range 1-14 inclusive. | 537 // One-byte-extension local identifiers are in the range 1-14 inclusive. |
537 RTC_DCHECK_GE(id, 1); | 538 RTC_DCHECK_GE(id, 1); |
538 RTC_DCHECK_LE(id, 14); | 539 RTC_DCHECK_LE(id, 14); |
539 RTC_DCHECK(RtpExtension::IsSupportedForVideo(extension)); | 540 RTC_DCHECK(RtpExtension::IsSupportedForVideo(extension)); |
540 RTC_CHECK(rtp_header_parser_->RegisterRtpHeaderExtension( | 541 RTC_CHECK(rtp_header_parser_->RegisterRtpHeaderExtension( |
541 StringToRtpExtensionType(extension), id)); | 542 StringToRtpExtensionType(extension), id)); |
542 } | 543 } |
543 | 544 |
544 } // namespace webrtc | 545 } // namespace webrtc |
OLD | NEW |