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

Unified Diff: webrtc/api/rtpreceiver.cc

Issue 1766653002: Replace SetCapturer and SetCaptureDevice by SetSource. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Work-in-progress, after applying 1790633002. Created 4 years, 9 months 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 side-by-side diff with in-line comments
Download patch
Index: webrtc/api/rtpreceiver.cc
diff --git a/webrtc/api/rtpreceiver.cc b/webrtc/api/rtpreceiver.cc
index 15906120f6d431fbb3e0bec5406062163630c18e..f8b505781a2bc7b61579e032563046ac543692e6 100644
--- a/webrtc/api/rtpreceiver.cc
+++ b/webrtc/api/rtpreceiver.cc
@@ -81,10 +81,6 @@ VideoRtpReceiver::VideoRtpReceiver(MediaStreamInterface* stream,
rtc::Thread::Current(),
VideoTrack::Create(track_id, source_.get()))) {
source_->SetState(MediaSourceInterface::kLive);
- // TODO(perkj): It should be enough to set the source state. All tracks
- // belonging to the same source should get its state from the source.
- // I.e. if a track has been cloned from a remote source.
- track_->set_state(webrtc::MediaStreamTrackInterface::kLive);
provider_->SetVideoPlayout(ssrc_, true, &broadcaster_);
stream->AddTrack(track_);
}
@@ -102,9 +98,6 @@ void VideoRtpReceiver::Stop() {
}
source_->SetState(MediaSourceInterface::kEnded);
source_->OnSourceDestroyed();
- // TODO(perkj): It should be enough to set the source state. All tracks
- // belonging to the same source should get its state from the source.
- track_->set_state(MediaStreamTrackInterface::kEnded);
provider_->SetVideoPlayout(ssrc_, false, nullptr);
provider_ = nullptr;
}

Powered by Google App Engine
This is Rietveld 408576698