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 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 const webrtc::AudioReceiveStream::Config& config) override; | 70 const webrtc::AudioReceiveStream::Config& config) override; |
71 void DestroyAudioReceiveStream( | 71 void DestroyAudioReceiveStream( |
72 webrtc::AudioReceiveStream* receive_stream) override; | 72 webrtc::AudioReceiveStream* receive_stream) override; |
73 | 73 |
74 webrtc::VideoSendStream* CreateVideoSendStream( | 74 webrtc::VideoSendStream* CreateVideoSendStream( |
75 const webrtc::VideoSendStream::Config& config, | 75 const webrtc::VideoSendStream::Config& config, |
76 const VideoEncoderConfig& encoder_config) override; | 76 const VideoEncoderConfig& encoder_config) override; |
77 void DestroyVideoSendStream(webrtc::VideoSendStream* send_stream) override; | 77 void DestroyVideoSendStream(webrtc::VideoSendStream* send_stream) override; |
78 | 78 |
79 webrtc::VideoReceiveStream* CreateVideoReceiveStream( | 79 webrtc::VideoReceiveStream* CreateVideoReceiveStream( |
80 const webrtc::VideoReceiveStream::Config& config) override; | 80 webrtc::VideoReceiveStream::Config configuration) override; |
81 void DestroyVideoReceiveStream( | 81 void DestroyVideoReceiveStream( |
82 webrtc::VideoReceiveStream* receive_stream) override; | 82 webrtc::VideoReceiveStream* receive_stream) override; |
83 | 83 |
84 Stats GetStats() const override; | 84 Stats GetStats() const override; |
85 | 85 |
86 DeliveryStatus DeliverPacket(MediaType media_type, | 86 DeliveryStatus DeliverPacket(MediaType media_type, |
87 const uint8_t* packet, | 87 const uint8_t* packet, |
88 size_t length, | 88 size_t length, |
89 const PacketTime& packet_time) override; | 89 const PacketTime& packet_time) override; |
90 | 90 |
(...skipping 369 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
460 it != rtp_state.end(); | 460 it != rtp_state.end(); |
461 ++it) { | 461 ++it) { |
462 suspended_video_send_ssrcs_[it->first] = it->second; | 462 suspended_video_send_ssrcs_[it->first] = it->second; |
463 } | 463 } |
464 | 464 |
465 UpdateAggregateNetworkState(); | 465 UpdateAggregateNetworkState(); |
466 delete send_stream_impl; | 466 delete send_stream_impl; |
467 } | 467 } |
468 | 468 |
469 webrtc::VideoReceiveStream* Call::CreateVideoReceiveStream( | 469 webrtc::VideoReceiveStream* Call::CreateVideoReceiveStream( |
470 const webrtc::VideoReceiveStream::Config& config) { | 470 webrtc::VideoReceiveStream::Config configuration) { |
471 TRACE_EVENT0("webrtc", "Call::CreateVideoReceiveStream"); | 471 TRACE_EVENT0("webrtc", "Call::CreateVideoReceiveStream"); |
472 RTC_DCHECK(configuration_thread_checker_.CalledOnValidThread()); | 472 RTC_DCHECK(configuration_thread_checker_.CalledOnValidThread()); |
473 VideoReceiveStream* receive_stream = new VideoReceiveStream( | 473 VideoReceiveStream* receive_stream = new VideoReceiveStream( |
474 num_cpu_cores_, congestion_controller_.get(), config, voice_engine(), | 474 num_cpu_cores_, congestion_controller_.get(), std::move(configuration), |
475 module_process_thread_.get(), call_stats_.get(), &remb_); | 475 voice_engine(), module_process_thread_.get(), call_stats_.get(), &remb_); |
| 476 |
| 477 const webrtc::VideoReceiveStream::Config& config = receive_stream->config(); |
476 { | 478 { |
477 WriteLockScoped write_lock(*receive_crit_); | 479 WriteLockScoped write_lock(*receive_crit_); |
478 RTC_DCHECK(video_receive_ssrcs_.find(config.rtp.remote_ssrc) == | 480 RTC_DCHECK(video_receive_ssrcs_.find(config.rtp.remote_ssrc) == |
479 video_receive_ssrcs_.end()); | 481 video_receive_ssrcs_.end()); |
480 video_receive_ssrcs_[config.rtp.remote_ssrc] = receive_stream; | 482 video_receive_ssrcs_[config.rtp.remote_ssrc] = receive_stream; |
481 // TODO(pbos): Configure different RTX payloads per receive payload. | 483 // TODO(pbos): Configure different RTX payloads per receive payload. |
482 VideoReceiveStream::Config::Rtp::RtxMap::const_iterator it = | 484 VideoReceiveStream::Config::Rtp::RtxMap::const_iterator it = |
483 config.rtp.rtx.begin(); | 485 config.rtp.rtx.begin(); |
484 if (it != config.rtp.rtx.end()) | 486 if (it != config.rtp.rtx.end()) |
485 video_receive_ssrcs_[it->second.ssrc] = receive_stream; | 487 video_receive_ssrcs_[it->second.ssrc] = receive_stream; |
(...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
853 // thread. Then this check can be enabled. | 855 // thread. Then this check can be enabled. |
854 // RTC_DCHECK(!configuration_thread_checker_.CalledOnValidThread()); | 856 // RTC_DCHECK(!configuration_thread_checker_.CalledOnValidThread()); |
855 if (RtpHeaderParser::IsRtcp(packet, length)) | 857 if (RtpHeaderParser::IsRtcp(packet, length)) |
856 return DeliverRtcp(media_type, packet, length); | 858 return DeliverRtcp(media_type, packet, length); |
857 | 859 |
858 return DeliverRtp(media_type, packet, length, packet_time); | 860 return DeliverRtp(media_type, packet, length, packet_time); |
859 } | 861 } |
860 | 862 |
861 } // namespace internal | 863 } // namespace internal |
862 } // namespace webrtc | 864 } // namespace webrtc |
OLD | NEW |