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

Issue 1664773002: Added VideoTrackInterface::GetSink method, for use by VideoRtpReceiver. Get rid of FrameInput. (Closed)

Created:
4 years, 10 months ago by nisse-webrtc
Modified:
4 years, 10 months ago
CC:
webrtc-reviews_webrtc.org
Base URL:
https://chromium.googlesource.com/external/webrtc.git@master
Target Ref:
refs/pending/heads/master
Project:
webrtc
Visibility:
Public.

Description

Added VideoTrackInterface::GetSink method, for use by VideoRtpReceiver. This lets us delete FrameInput. This way, the use of VideoSourceInterface::FrameInput method becomes an implementation details in VideoTrack. When VideoTrack is changed to become a VideoSink, the implementation of VideoTrack::GetSink can be changed to simply return |this|. Having an extra method which will ultimately just returning |this| looks silly, but may have some advantage when using VideoTrackProxy (which I don't fully understand), since we return the underlying object instead of proxying OnFrame calls. On top of https://codereview.webrtc.org/1668493002/ BUG=webrtc:5426

Patch Set 1 #

Patch Set 2 : Delete FrameInput method and FrameInputWrapper class. #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+116 lines, -138 lines) Patch
M talk/app/webrtc/mediastreaminterface.h View 1 chunk +1 line, -0 lines 1 comment Download
M talk/app/webrtc/mediastreamprovider.h View 2 chunks +6 lines, -3 lines 1 comment Download
M talk/app/webrtc/mediastreamtrackproxy.h View 1 chunk +1 line, -0 lines 0 comments Download
M talk/app/webrtc/rtpreceiver.cc View 1 chunk +1 line, -2 lines 1 comment Download
M talk/app/webrtc/rtpsenderreceiver_unittest.cc View 1 2 chunks +2 lines, -2 lines 0 comments Download
M talk/app/webrtc/videosource.h View 1 1 chunk +0 lines, -1 line 0 comments Download
M talk/app/webrtc/videosource.cc View 1 2 chunks +0 lines, -37 lines 0 comments Download
M talk/app/webrtc/videosource_unittest.cc View 1 2 chunks +2 lines, -0 lines 0 comments Download
M talk/app/webrtc/videosourceinterface.h View 1 1 chunk +0 lines, -1 line 0 comments Download
M talk/app/webrtc/videosourceproxy.h View 1 1 chunk +0 lines, -1 line 0 comments Download
M talk/app/webrtc/videotrack.h View 1 chunk +1 line, -0 lines 0 comments Download
M talk/app/webrtc/videotrack.cc View 1 1 chunk +5 lines, -0 lines 1 comment Download
M talk/app/webrtc/videotrack_unittest.cc View 1 5 chunks +10 lines, -10 lines 0 comments Download
M talk/app/webrtc/webrtcsession.h View 1 chunk +4 lines, -3 lines 0 comments Download
M talk/app/webrtc/webrtcsession.cc View 1 chunk +7 lines, -6 lines 0 comments Download
M talk/app/webrtc/webrtcsession_unittest.cc View 1 chunk +4 lines, -4 lines 0 comments Download
M talk/media/base/fakemediaengine.h View 4 chunks +10 lines, -8 lines 0 comments Download
M talk/media/base/mediachannel.h View 4 chunks +6 lines, -7 lines 0 comments Download
M talk/media/base/videoengine_unittest.h View 21 chunks +28 lines, -28 lines 0 comments Download
M talk/media/webrtc/webrtcvideoengine2.h View 2 chunks +6 lines, -4 lines 0 comments Download
M talk/media/webrtc/webrtcvideoengine2.cc View 4 chunks +14 lines, -13 lines 0 comments Download
M talk/media/webrtc/webrtcvideoengine2_unittest.cc View 2 chunks +2 lines, -2 lines 0 comments Download
M talk/session/media/channel.h View 3 chunks +2 lines, -2 lines 0 comments Download
M talk/session/media/channel.cc View 2 chunks +4 lines, -4 lines 0 comments Download

Messages

Total messages: 8 (4 generated)
nisse-webrtc
This is my first refactoring on the receiver side. It gets rid of the FrameInput ...
4 years, 10 months ago (2016-02-03 13:42:30 UTC) #3
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1664773002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1664773002/20001
4 years, 10 months ago (2016-02-03 13:45:26 UTC) #5
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: android_arm64_rel on tryserver.webrtc (JOB_TIMED_OUT, no build URL) ...
4 years, 10 months ago (2016-02-03 15:46:03 UTC) #7
pthatcher1
4 years, 10 months ago (2016-02-03 16:24:29 UTC) #8
You may consider pulling the renderer => sink part of this CL out into a smaller
one rather than the "add GetSink to track" part.  That might make more sense.

In either case, I like it all, except for the part I keep repeating about making
a VideoTrackInterface implement a VideoSinkInterface.

https://codereview.webrtc.org/1664773002/diff/20001/talk/app/webrtc/mediastre...
File talk/app/webrtc/mediastreaminterface.h (right):

https://codereview.webrtc.org/1664773002/diff/20001/talk/app/webrtc/mediastre...
talk/app/webrtc/mediastreaminterface.h:148: virtual VideoSourceInterface*
GetSource() const = 0;
As mentioned in the other CL, I think we can just have VideoTrackInterface
implement rtc::VideoSinkInterface<cricket::VideoFrame> and then we don't need
GetSink() and we can just use a VideoTrackInterface as a sink.

https://codereview.webrtc.org/1664773002/diff/20001/talk/app/webrtc/mediastre...
File talk/app/webrtc/mediastreamprovider.h (right):

https://codereview.webrtc.org/1664773002/diff/20001/talk/app/webrtc/mediastre...
talk/app/webrtc/mediastreamprovider.h:96:
rtc::VideoSinkInterface<cricket::VideoFrame>* sink) = 0;
You could do this in the smaller CL as well.  There's nothing blocking it, I
don't think.

https://codereview.webrtc.org/1664773002/diff/20001/talk/app/webrtc/rtpreceiv...
File talk/app/webrtc/rtpreceiver.cc (right):

https://codereview.webrtc.org/1664773002/diff/20001/talk/app/webrtc/rtpreceiv...
talk/app/webrtc/rtpreceiver.cc:89: provider_->SetVideoPlayout(ssrc_, true,
track_->GetSink());
As mentioned in the other CL, being able to just pass in track_ here would be
nicer.

https://codereview.webrtc.org/1664773002/diff/20001/talk/app/webrtc/videotrac...
File talk/app/webrtc/videotrack.cc (right):

https://codereview.webrtc.org/1664773002/diff/20001/talk/app/webrtc/videotrac...
talk/app/webrtc/videotrack.cc:63: return &renderers_;
As mentioned in the other CL, you could just implement OnFrame here by calling
renderers_->OnFrame()

Powered by Google App Engine
This is Rietveld 408576698