OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2013 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 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
117 } | 117 } |
118 rtclog_config.rtcp_mode = config.rtp.rtcp_mode; | 118 rtclog_config.rtcp_mode = config.rtp.rtcp_mode; |
119 rtclog_config.rtp_extensions = config.rtp.extensions; | 119 rtclog_config.rtp_extensions = config.rtp.extensions; |
120 | 120 |
121 rtclog_config.codecs.emplace_back(config.encoder_settings.payload_name, | 121 rtclog_config.codecs.emplace_back(config.encoder_settings.payload_name, |
122 config.encoder_settings.payload_type, | 122 config.encoder_settings.payload_type, |
123 config.rtp.rtx.payload_type); | 123 config.rtp.rtx.payload_type); |
124 return rtclog_config; | 124 return rtclog_config; |
125 } | 125 } |
126 | 126 |
| 127 rtclog::StreamConfig CreateRtcLogStreamConfig( |
| 128 const AudioReceiveStream::Config& config) { |
| 129 rtclog::StreamConfig rtclog_config; |
| 130 rtclog_config.remote_ssrc = config.rtp.remote_ssrc; |
| 131 rtclog_config.local_ssrc = config.rtp.local_ssrc; |
| 132 rtclog_config.rtp_extensions = config.rtp.extensions; |
| 133 return rtclog_config; |
| 134 } |
| 135 |
127 } // namespace | 136 } // namespace |
128 | 137 |
129 namespace internal { | 138 namespace internal { |
130 | 139 |
131 class Call : public webrtc::Call, | 140 class Call : public webrtc::Call, |
132 public PacketReceiver, | 141 public PacketReceiver, |
133 public RecoveredPacketReceiver, | 142 public RecoveredPacketReceiver, |
134 public SendSideCongestionController::Observer, | 143 public SendSideCongestionController::Observer, |
135 public BitrateAllocator::LimitObserver { | 144 public BitrateAllocator::LimitObserver { |
136 public: | 145 public: |
(...skipping 450 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
587 } | 596 } |
588 } | 597 } |
589 UpdateAggregateNetworkState(); | 598 UpdateAggregateNetworkState(); |
590 delete audio_send_stream; | 599 delete audio_send_stream; |
591 } | 600 } |
592 | 601 |
593 webrtc::AudioReceiveStream* Call::CreateAudioReceiveStream( | 602 webrtc::AudioReceiveStream* Call::CreateAudioReceiveStream( |
594 const webrtc::AudioReceiveStream::Config& config) { | 603 const webrtc::AudioReceiveStream::Config& config) { |
595 TRACE_EVENT0("webrtc", "Call::CreateAudioReceiveStream"); | 604 TRACE_EVENT0("webrtc", "Call::CreateAudioReceiveStream"); |
596 RTC_DCHECK(configuration_thread_checker_.CalledOnValidThread()); | 605 RTC_DCHECK(configuration_thread_checker_.CalledOnValidThread()); |
597 event_log_->LogAudioReceiveStreamConfig(config); | 606 event_log_->LogAudioReceiveStreamConfig(CreateRtcLogStreamConfig(config)); |
598 AudioReceiveStream* receive_stream = | 607 AudioReceiveStream* receive_stream = |
599 new AudioReceiveStream(transport_send_->packet_router(), config, | 608 new AudioReceiveStream(transport_send_->packet_router(), config, |
600 config_.audio_state, event_log_); | 609 config_.audio_state, event_log_); |
601 { | 610 { |
602 WriteLockScoped write_lock(*receive_crit_); | 611 WriteLockScoped write_lock(*receive_crit_); |
603 audio_rtp_demuxer_.AddSink(config.rtp.remote_ssrc, receive_stream); | 612 audio_rtp_demuxer_.AddSink(config.rtp.remote_ssrc, receive_stream); |
604 receive_rtp_config_[config.rtp.remote_ssrc] = | 613 receive_rtp_config_[config.rtp.remote_ssrc] = |
605 ReceiveRtpConfig(config.rtp.extensions, UseSendSideBwe(config)); | 614 ReceiveRtpConfig(config.rtp.extensions, UseSendSideBwe(config)); |
606 audio_receive_streams_.insert(receive_stream); | 615 audio_receive_streams_.insert(receive_stream); |
607 | 616 |
(...skipping 664 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1272 (use_send_side_bwe && header.extension.hasTransportSequenceNumber)) { | 1281 (use_send_side_bwe && header.extension.hasTransportSequenceNumber)) { |
1273 receive_side_cc_.OnReceivedPacket( | 1282 receive_side_cc_.OnReceivedPacket( |
1274 packet.arrival_time_ms(), packet.payload_size() + packet.padding_size(), | 1283 packet.arrival_time_ms(), packet.payload_size() + packet.padding_size(), |
1275 header); | 1284 header); |
1276 } | 1285 } |
1277 } | 1286 } |
1278 | 1287 |
1279 } // namespace internal | 1288 } // namespace internal |
1280 | 1289 |
1281 } // namespace webrtc | 1290 } // namespace webrtc |
OLD | NEW |