| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2004 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2004 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 191 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 202 if (!default_network_manager_) { | 202 if (!default_network_manager_) { |
| 203 return false; | 203 return false; |
| 204 } | 204 } |
| 205 | 205 |
| 206 default_socket_factory_.reset( | 206 default_socket_factory_.reset( |
| 207 new rtc::BasicPacketSocketFactory(network_thread_)); | 207 new rtc::BasicPacketSocketFactory(network_thread_)); |
| 208 if (!default_socket_factory_) { | 208 if (!default_socket_factory_) { |
| 209 return false; | 209 return false; |
| 210 } | 210 } |
| 211 | 211 |
| 212 // TODO: Need to make sure only one VoE is created inside | |
| 213 // WebRtcMediaEngine. | |
| 214 std::unique_ptr<cricket::MediaEngineInterface> media_engine = | 212 std::unique_ptr<cricket::MediaEngineInterface> media_engine = |
| 215 worker_thread_->Invoke<std::unique_ptr<cricket::MediaEngineInterface>>( | 213 worker_thread_->Invoke<std::unique_ptr<cricket::MediaEngineInterface>>( |
| 216 RTC_FROM_HERE, | 214 RTC_FROM_HERE, |
| 217 rtc::Bind(&PeerConnectionFactory::CreateMediaEngine_w, this)); | 215 rtc::Bind(&PeerConnectionFactory::CreateMediaEngine_w, this)); |
| 218 | 216 |
| 219 channel_manager_.reset(new cricket::ChannelManager( | 217 channel_manager_.reset(new cricket::ChannelManager( |
| 220 std::move(media_engine), worker_thread_, network_thread_)); | 218 std::move(media_engine), worker_thread_, network_thread_)); |
| 221 | 219 |
| 222 channel_manager_->SetVideoRtxEnabled(true); | 220 channel_manager_->SetVideoRtxEnabled(true); |
| 223 channel_manager_->SetCryptoOptions(options_.crypto_options); | 221 channel_manager_->SetCryptoOptions(options_.crypto_options); |
| (...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 395 PeerConnectionFactory::CreateMediaEngine_w() { | 393 PeerConnectionFactory::CreateMediaEngine_w() { |
| 396 RTC_DCHECK(worker_thread_ == rtc::Thread::Current()); | 394 RTC_DCHECK(worker_thread_ == rtc::Thread::Current()); |
| 397 return std::unique_ptr<cricket::MediaEngineInterface>( | 395 return std::unique_ptr<cricket::MediaEngineInterface>( |
| 398 cricket::WebRtcMediaEngineFactory::Create( | 396 cricket::WebRtcMediaEngineFactory::Create( |
| 399 default_adm_.get(), audio_decoder_factory_, | 397 default_adm_.get(), audio_decoder_factory_, |
| 400 video_encoder_factory_.get(), video_decoder_factory_.get(), | 398 video_encoder_factory_.get(), video_decoder_factory_.get(), |
| 401 external_audio_mixer_)); | 399 external_audio_mixer_)); |
| 402 } | 400 } |
| 403 | 401 |
| 404 } // namespace webrtc | 402 } // namespace webrtc |
| OLD | NEW |