| OLD | NEW |
| 1 /* | 1 /* |
| 2 * libjingle | 2 * libjingle |
| 3 * Copyright 2004--2011 Google Inc. | 3 * Copyright 2004--2011 Google Inc. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are met: | 6 * modification, are permitted provided that the following conditions are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright notice, | 8 * 1. Redistributions of source code must retain the above copyright notice, |
| 9 * this list of conditions and the following disclaimer. | 9 * this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright notice, | 10 * 2. Redistributions in binary form must reproduce the above copyright notice, |
| (...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 296 } | 296 } |
| 297 | 297 |
| 298 rtc::scoped_refptr<AudioTrackInterface> | 298 rtc::scoped_refptr<AudioTrackInterface> |
| 299 PeerConnectionFactory::CreateAudioTrack(const std::string& id, | 299 PeerConnectionFactory::CreateAudioTrack(const std::string& id, |
| 300 AudioSourceInterface* source) { | 300 AudioSourceInterface* source) { |
| 301 RTC_DCHECK(signaling_thread_->IsCurrent()); | 301 RTC_DCHECK(signaling_thread_->IsCurrent()); |
| 302 rtc::scoped_refptr<AudioTrackInterface> track(AudioTrack::Create(id, source)); | 302 rtc::scoped_refptr<AudioTrackInterface> track(AudioTrack::Create(id, source)); |
| 303 return AudioTrackProxy::Create(signaling_thread_, track); | 303 return AudioTrackProxy::Create(signaling_thread_, track); |
| 304 } | 304 } |
| 305 | 305 |
| 306 webrtc::MediaControllerInterface* PeerConnectionFactory::CreateMediaController() | 306 webrtc::MediaControllerInterface* PeerConnectionFactory::CreateMediaController( |
| 307 const cricket::MediaConfig& config) |
| 307 const { | 308 const { |
| 308 RTC_DCHECK(signaling_thread_->IsCurrent()); | 309 RTC_DCHECK(signaling_thread_->IsCurrent()); |
| 309 return MediaControllerInterface::Create(worker_thread_, | 310 return MediaControllerInterface::Create(config, worker_thread_, |
| 310 channel_manager_.get()); | 311 channel_manager_.get()); |
| 311 } | 312 } |
| 312 | 313 |
| 313 rtc::Thread* PeerConnectionFactory::signaling_thread() { | 314 rtc::Thread* PeerConnectionFactory::signaling_thread() { |
| 314 // This method can be called on a different thread when the factory is | 315 // This method can be called on a different thread when the factory is |
| 315 // created in CreatePeerConnectionFactory(). | 316 // created in CreatePeerConnectionFactory(). |
| 316 return signaling_thread_; | 317 return signaling_thread_; |
| 317 } | 318 } |
| 318 | 319 |
| 319 rtc::Thread* PeerConnectionFactory::worker_thread() { | 320 rtc::Thread* PeerConnectionFactory::worker_thread() { |
| 320 RTC_DCHECK(signaling_thread_->IsCurrent()); | 321 RTC_DCHECK(signaling_thread_->IsCurrent()); |
| 321 return worker_thread_; | 322 return worker_thread_; |
| 322 } | 323 } |
| 323 | 324 |
| 324 cricket::MediaEngineInterface* PeerConnectionFactory::CreateMediaEngine_w() { | 325 cricket::MediaEngineInterface* PeerConnectionFactory::CreateMediaEngine_w() { |
| 325 ASSERT(worker_thread_ == rtc::Thread::Current()); | 326 ASSERT(worker_thread_ == rtc::Thread::Current()); |
| 326 return cricket::WebRtcMediaEngineFactory::Create( | 327 return cricket::WebRtcMediaEngineFactory::Create( |
| 327 default_adm_.get(), video_encoder_factory_.get(), | 328 default_adm_.get(), video_encoder_factory_.get(), |
| 328 video_decoder_factory_.get()); | 329 video_decoder_factory_.get()); |
| 329 } | 330 } |
| 330 | 331 |
| 331 } // namespace webrtc | 332 } // namespace webrtc |
| OLD | NEW |