| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2014 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 #include "webrtc/base/checks.h" | 10 #include "webrtc/base/checks.h" |
| (...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 210 for (const RtpExtension& extension : video_send_config_.rtp.extensions) | 210 for (const RtpExtension& extension : video_send_config_.rtp.extensions) |
| 211 video_config.rtp.extensions.push_back(extension); | 211 video_config.rtp.extensions.push_back(extension); |
| 212 for (size_t i = 0; i < video_send_config_.rtp.ssrcs.size(); ++i) { | 212 for (size_t i = 0; i < video_send_config_.rtp.ssrcs.size(); ++i) { |
| 213 VideoReceiveStream::Decoder decoder = | 213 VideoReceiveStream::Decoder decoder = |
| 214 test::CreateMatchingDecoder(video_send_config_.encoder_settings); | 214 test::CreateMatchingDecoder(video_send_config_.encoder_settings); |
| 215 allocated_decoders_.push_back( | 215 allocated_decoders_.push_back( |
| 216 std::unique_ptr<VideoDecoder>(decoder.decoder)); | 216 std::unique_ptr<VideoDecoder>(decoder.decoder)); |
| 217 video_config.decoders.clear(); | 217 video_config.decoders.clear(); |
| 218 video_config.decoders.push_back(decoder); | 218 video_config.decoders.push_back(decoder); |
| 219 video_config.rtp.remote_ssrc = video_send_config_.rtp.ssrcs[i]; | 219 video_config.rtp.remote_ssrc = video_send_config_.rtp.ssrcs[i]; |
| 220 video_receive_configs_.push_back(video_config); | 220 video_receive_configs_.push_back(video_config.Copy()); |
| 221 } | 221 } |
| 222 } | 222 } |
| 223 | 223 |
| 224 RTC_DCHECK(num_audio_streams_ <= 1); | 224 RTC_DCHECK(num_audio_streams_ <= 1); |
| 225 if (num_audio_streams_ == 1) { | 225 if (num_audio_streams_ == 1) { |
| 226 RTC_DCHECK(voe_send_.channel_id >= 0); | 226 RTC_DCHECK(voe_send_.channel_id >= 0); |
| 227 AudioReceiveStream::Config audio_config; | 227 AudioReceiveStream::Config audio_config; |
| 228 audio_config.rtp.local_ssrc = kReceiverLocalAudioSsrc; | 228 audio_config.rtp.local_ssrc = kReceiverLocalAudioSsrc; |
| 229 audio_config.rtcp_send_transport = rtcp_send_transport; | 229 audio_config.rtcp_send_transport = rtcp_send_transport; |
| 230 audio_config.voe_channel_id = voe_recv_.channel_id; | 230 audio_config.voe_channel_id = voe_recv_.channel_id; |
| (...skipping 28 matching lines...) Expand all Loading... |
| 259 | 259 |
| 260 void CallTest::CreateVideoStreams() { | 260 void CallTest::CreateVideoStreams() { |
| 261 RTC_DCHECK(video_send_stream_ == nullptr); | 261 RTC_DCHECK(video_send_stream_ == nullptr); |
| 262 RTC_DCHECK(video_receive_streams_.empty()); | 262 RTC_DCHECK(video_receive_streams_.empty()); |
| 263 RTC_DCHECK(audio_send_stream_ == nullptr); | 263 RTC_DCHECK(audio_send_stream_ == nullptr); |
| 264 RTC_DCHECK(audio_receive_streams_.empty()); | 264 RTC_DCHECK(audio_receive_streams_.empty()); |
| 265 | 265 |
| 266 video_send_stream_ = sender_call_->CreateVideoSendStream( | 266 video_send_stream_ = sender_call_->CreateVideoSendStream( |
| 267 video_send_config_, video_encoder_config_); | 267 video_send_config_, video_encoder_config_); |
| 268 for (size_t i = 0; i < video_receive_configs_.size(); ++i) { | 268 for (size_t i = 0; i < video_receive_configs_.size(); ++i) { |
| 269 video_receive_streams_.push_back( | 269 video_receive_streams_.push_back(receiver_call_->CreateVideoReceiveStream( |
| 270 receiver_call_->CreateVideoReceiveStream(video_receive_configs_[i])); | 270 video_receive_configs_[i].Copy())); |
| 271 } | 271 } |
| 272 } | 272 } |
| 273 | 273 |
| 274 void CallTest::SetFakeVideoCaptureRotation(VideoRotation rotation) { | 274 void CallTest::SetFakeVideoCaptureRotation(VideoRotation rotation) { |
| 275 frame_generator_capturer_->SetFakeRotation(rotation); | 275 frame_generator_capturer_->SetFakeRotation(rotation); |
| 276 } | 276 } |
| 277 | 277 |
| 278 void CallTest::CreateAudioStreams() { | 278 void CallTest::CreateAudioStreams() { |
| 279 audio_send_stream_ = sender_call_->CreateAudioSendStream(audio_send_config_); | 279 audio_send_stream_ = sender_call_->CreateAudioSendStream(audio_send_config_); |
| 280 for (size_t i = 0; i < audio_receive_configs_.size(); ++i) { | 280 for (size_t i = 0; i < audio_receive_configs_.size(); ++i) { |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 425 | 425 |
| 426 EndToEndTest::EndToEndTest(unsigned int timeout_ms) : BaseTest(timeout_ms) { | 426 EndToEndTest::EndToEndTest(unsigned int timeout_ms) : BaseTest(timeout_ms) { |
| 427 } | 427 } |
| 428 | 428 |
| 429 bool EndToEndTest::ShouldCreateReceivers() const { | 429 bool EndToEndTest::ShouldCreateReceivers() const { |
| 430 return true; | 430 return true; |
| 431 } | 431 } |
| 432 | 432 |
| 433 } // namespace test | 433 } // namespace test |
| 434 } // namespace webrtc | 434 } // namespace webrtc |
| OLD | NEW |