Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(107)

Side by Side Diff: talk/app/webrtc/peerconnectionfactory.cc

Issue 1522903002: Add a 'remote' property to MediaSourceInterface. Also adding an implementation to the relevant sour… (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « talk/app/webrtc/peerconnection.cc ('k') | talk/app/webrtc/remoteaudiosource.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 207 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 rtc::scoped_refptr<LocalAudioSource> source( 218 rtc::scoped_refptr<LocalAudioSource> source(
219 LocalAudioSource::Create(options_, constraints)); 219 LocalAudioSource::Create(options_, constraints));
220 return source; 220 return source;
221 } 221 }
222 222
223 rtc::scoped_refptr<VideoSourceInterface> 223 rtc::scoped_refptr<VideoSourceInterface>
224 PeerConnectionFactory::CreateVideoSource( 224 PeerConnectionFactory::CreateVideoSource(
225 cricket::VideoCapturer* capturer, 225 cricket::VideoCapturer* capturer,
226 const MediaConstraintsInterface* constraints) { 226 const MediaConstraintsInterface* constraints) {
227 RTC_DCHECK(signaling_thread_->IsCurrent()); 227 RTC_DCHECK(signaling_thread_->IsCurrent());
228 rtc::scoped_refptr<VideoSource> source( 228 rtc::scoped_refptr<VideoSource> source(VideoSource::Create(
229 VideoSource::Create(channel_manager_.get(), capturer, constraints)); 229 channel_manager_.get(), capturer, constraints, false));
230 return VideoSourceProxy::Create(signaling_thread_, source); 230 return VideoSourceProxy::Create(signaling_thread_, source);
231 } 231 }
232 232
233 bool PeerConnectionFactory::StartAecDump(rtc::PlatformFile file) { 233 bool PeerConnectionFactory::StartAecDump(rtc::PlatformFile file) {
234 RTC_DCHECK(signaling_thread_->IsCurrent()); 234 RTC_DCHECK(signaling_thread_->IsCurrent());
235 return channel_manager_->StartAecDump(file); 235 return channel_manager_->StartAecDump(file);
236 } 236 }
237 237
238 void PeerConnectionFactory::StopAecDump() { 238 void PeerConnectionFactory::StopAecDump() {
239 RTC_DCHECK(signaling_thread_->IsCurrent()); 239 RTC_DCHECK(signaling_thread_->IsCurrent());
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
323 RTC_DCHECK(signaling_thread_->IsCurrent()); 323 RTC_DCHECK(signaling_thread_->IsCurrent());
324 return MediaStreamProxy::Create(signaling_thread_, 324 return MediaStreamProxy::Create(signaling_thread_,
325 MediaStream::Create(label)); 325 MediaStream::Create(label));
326 } 326 }
327 327
328 rtc::scoped_refptr<VideoTrackInterface> 328 rtc::scoped_refptr<VideoTrackInterface>
329 PeerConnectionFactory::CreateVideoTrack( 329 PeerConnectionFactory::CreateVideoTrack(
330 const std::string& id, 330 const std::string& id,
331 VideoSourceInterface* source) { 331 VideoSourceInterface* source) {
332 RTC_DCHECK(signaling_thread_->IsCurrent()); 332 RTC_DCHECK(signaling_thread_->IsCurrent());
333 RTC_DCHECK(!source || !source->remote());
perkj_webrtc 2015/12/14 15:55:03 I think this currently can be a remote source. It
tommi 2015/12/14 16:38:25 I see. The same is not true for CreateAudioTrack
333 rtc::scoped_refptr<VideoTrackInterface> track( 334 rtc::scoped_refptr<VideoTrackInterface> track(
334 VideoTrack::Create(id, source)); 335 VideoTrack::Create(id, source));
335 return VideoTrackProxy::Create(signaling_thread_, track); 336 return VideoTrackProxy::Create(signaling_thread_, track);
336 } 337 }
337 338
338 rtc::scoped_refptr<AudioTrackInterface> 339 rtc::scoped_refptr<AudioTrackInterface>
339 PeerConnectionFactory::CreateAudioTrack(const std::string& id, 340 PeerConnectionFactory::CreateAudioTrack(const std::string& id,
340 AudioSourceInterface* source) { 341 AudioSourceInterface* source) {
341 RTC_DCHECK(signaling_thread_->IsCurrent()); 342 RTC_DCHECK(signaling_thread_->IsCurrent());
342 rtc::scoped_refptr<AudioTrackInterface> track( 343 rtc::scoped_refptr<AudioTrackInterface> track(
(...skipping 20 matching lines...) Expand all
363 } 364 }
364 365
365 cricket::MediaEngineInterface* PeerConnectionFactory::CreateMediaEngine_w() { 366 cricket::MediaEngineInterface* PeerConnectionFactory::CreateMediaEngine_w() {
366 ASSERT(worker_thread_ == rtc::Thread::Current()); 367 ASSERT(worker_thread_ == rtc::Thread::Current());
367 return cricket::WebRtcMediaEngineFactory::Create( 368 return cricket::WebRtcMediaEngineFactory::Create(
368 default_adm_.get(), video_encoder_factory_.get(), 369 default_adm_.get(), video_encoder_factory_.get(),
369 video_decoder_factory_.get()); 370 video_decoder_factory_.get());
370 } 371 }
371 372
372 } // namespace webrtc 373 } // namespace webrtc
OLDNEW
« no previous file with comments | « talk/app/webrtc/peerconnection.cc ('k') | talk/app/webrtc/remoteaudiosource.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698