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

Issue 2389473002: Media Remoting: Add RemotingController. (Closed)

Created:
4 years, 2 months ago by xjz
Modified:
4 years, 2 months ago
CC:
blink-reviews, blink-reviews-api_chromium.org, chromium-reviews, chromoting-reviews_chromium.org, creis+watch_chromium.org, darin-cc_chromium.org, dglazkov+blink, eric.carlson_apple.com, feature-media-reviews_chromium.org, jam, kinuko+watch, mlamouri+watch-content_chromium.org, mlamouri+watch-blink_chromium.org, nasko+codewatch_chromium.org, Srirama
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Media Remoting: Add RemotingController. Add a RemotingController which does the following: 1) Implements media::mojom::RemotingSource interface, and sends/Receives messages from/to a media::mojom::Remoter; 2) Monitors player events as a MediaPlayerObserver; 3) May trigger the switch of the media renderer between local playback and remoting. BUG=643964 Committed: https://crrev.com/d3fe45a5f7f8395c26b5f75f0574487eb7618639 Cr-Commit-Position: refs/heads/master@{#424791}

Patch Set 1 #

Total comments: 58

Patch Set 2 : Addressed xhwang's comments. Rebased. #

Patch Set 3 : Fix bug on Android. #

Total comments: 39

Patch Set 4 : Addressed xhwang's comments. #

Patch Set 5 : Not use RemotingRendererFactory for Android. #

Patch Set 6 : Add building flag. #

Total comments: 12

Patch Set 7 : Use BUILDFLAG. #

Total comments: 8

Patch Set 8 : Addressed comments. #

Patch Set 9 : Rebased. #

Total comments: 11

Patch Set 10 : Remove changes in Blink from this CL. #

Patch Set 11 : Rebased. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+760 lines, -23 lines) Patch
M content/renderer/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 1 chunk +4 lines, -0 lines 0 comments Download
M content/renderer/render_frame_impl.h View 1 2 3 4 5 6 7 8 9 10 4 chunks +12 lines, -0 lines 0 comments Download
M content/renderer/render_frame_impl.cc View 1 2 3 4 5 6 7 8 9 10 7 chunks +45 lines, -7 lines 0 comments Download
M media/BUILD.gn View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M media/base/BUILD.gn View 1 2 chunks +3 lines, -0 lines 0 comments Download
A media/base/media_observer.h View 1 2 3 4 5 6 7 8 9 1 chunk +33 lines, -0 lines 0 comments Download
A + media/base/media_observer.cc View 1 1 chunk +3 lines, -3 lines 0 comments Download
M media/base/pipeline_impl.cc View 1 2 3 4 5 6 7 8 1 chunk +4 lines, -1 line 0 comments Download
M media/base/pipeline_metadata.h View 1 2 3 1 chunk +11 lines, -3 lines 0 comments Download
A media/base/pipeline_metadata.cc View 1 2 3 1 chunk +16 lines, -0 lines 0 comments Download
M media/blink/webmediaplayer_impl.h View 1 2 3 4 5 6 7 8 9 10 4 chunks +9 lines, -3 lines 0 comments Download
M media/blink/webmediaplayer_impl.cc View 1 2 3 4 5 6 7 8 9 10 4 chunks +12 lines, -1 line 0 comments Download
M media/blink/webmediaplayer_impl_unittest.cc View 1 1 chunk +1 line, -1 line 0 comments Download
M media/blink/webmediaplayer_params.h View 1 4 chunks +9 lines, -1 line 0 comments Download
M media/blink/webmediaplayer_params.cc View 1 2 chunks +4 lines, -2 lines 0 comments Download
M media/media_options.gni View 1 2 3 4 5 6 7 8 1 chunk +7 lines, -0 lines 0 comments Download
M media/remoting/BUILD.gn View 1 2 3 4 5 2 chunks +19 lines, -2 lines 0 comments Download
A + media/remoting/DEPS View 0 chunks +-1 lines, --1 lines 0 comments Download
A media/remoting/remoting_controller.h View 1 2 3 4 5 6 7 1 chunk +110 lines, -0 lines 0 comments Download
A media/remoting/remoting_controller.cc View 1 2 3 4 5 6 7 1 chunk +209 lines, -0 lines 0 comments Download
A media/remoting/remoting_controller_unittest.cc View 1 2 3 4 5 6 7 1 chunk +172 lines, -0 lines 0 comments Download
A media/remoting/remoting_renderer_factory.h View 1 1 chunk +39 lines, -0 lines 0 comments Download
A media/remoting/remoting_renderer_factory.cc View 1 chunk +38 lines, -0 lines 0 comments Download

Messages

Total messages: 87 (40 generated)
xjz
xhwang: PTAL media/base/* and media/blink/*. esprehn: PTAL content/renderer/* and third_party/WebKit/*. miu: PTAL all :) Thanks ...
4 years, 2 months ago (2016-10-01 00:36:41 UTC) #4
esprehn
What's the plan for moving the media code into blink? This is again making the ...
4 years, 2 months ago (2016-10-01 00:41:52 UTC) #5
miu
On 2016/10/01 00:41:52, esprehn wrote: > What's the plan for moving the media code into ...
4 years, 2 months ago (2016-10-01 02:26:07 UTC) #6
miu
PS1 lgtm. Note: PS1 is identical to the final patchset of a "WIP" code review ...
4 years, 2 months ago (2016-10-01 02:42:50 UTC) #7
xhwang
This definitely looks better! Here are my first round of comments. https://codereview.chromium.org/2389473002/diff/1/media/base/mediaplayer_observer.h File media/base/mediaplayer_observer.h (right): ...
4 years, 2 months ago (2016-10-01 07:12:16 UTC) #8
xhwang
BTW, I only skimmed media/remoting/* since I am not familiar with the logic there.
4 years, 2 months ago (2016-10-01 07:12:59 UTC) #9
xhwang
On 2016/10/01 07:12:59, xhwang wrote: > BTW, I only skimmed media/remoting/* since I am not ...
4 years, 2 months ago (2016-10-02 16:26:43 UTC) #10
xhwang
On 2016/10/01 02:26:07, miu wrote: > On 2016/10/01 00:41:52, esprehn wrote: > > What's the ...
4 years, 2 months ago (2016-10-03 20:43:06 UTC) #12
xjz
Addressed xhwang's comments. PTAL https://codereview.chromium.org/2389473002/diff/1/media/base/mediaplayer_observer.h File media/base/mediaplayer_observer.h (right): https://codereview.chromium.org/2389473002/diff/1/media/base/mediaplayer_observer.h#newcode5 media/base/mediaplayer_observer.h:5: #ifndef MEDIA_BASE_MEDIAPLAYER_OBSERVER_H_ On 2016/10/01 07:12:14, ...
4 years, 2 months ago (2016-10-03 22:31:09 UTC) #13
xhwang
Looking pretty good! I just have some more comments (mostly nits). There are some comments ...
4 years, 2 months ago (2016-10-04 06:30:30 UTC) #22
xjz
Addressed xhwang's comments. PTAL. https://codereview.chromium.org/2389473002/diff/1/media/base/pipeline_metadata.h File media/base/pipeline_metadata.h (right): https://codereview.chromium.org/2389473002/diff/1/media/base/pipeline_metadata.h#newcode23 media/base/pipeline_metadata.h:23: PipelineMetadata& operator=(const PipelineMetadata&); On 2016/10/04 ...
4 years, 2 months ago (2016-10-04 19:21:30 UTC) #23
xjz
Addressed xhwang's comments. PTAL https://codereview.chromium.org/2389473002/diff/40001/content/renderer/render_frame_impl.cc File content/renderer/render_frame_impl.cc (right): https://codereview.chromium.org/2389473002/diff/40001/content/renderer/render_frame_impl.cc#newcode2714 content/renderer/render_frame_impl.cc:2714: std::move(remoting_controller))); On 2016/10/04 19:21:29, xjz ...
4 years, 2 months ago (2016-10-04 22:13:02 UTC) #24
xjz
Add building flag to enable media remoting in PS#6. PTAL
4 years, 2 months ago (2016-10-05 01:06:41 UTC) #25
xhwang
Looking good. I only have a few more comments/nits. sandersd: Could you please have a ...
4 years, 2 months ago (2016-10-05 05:27:53 UTC) #27
xjz
Addressed xhwang's comments. PTAL. sandersd@: PTAL content::RenderFrameImpl::createMediaPlayer(), where WMPI::ScheduleRestart() is set as a callback to ...
4 years, 2 months ago (2016-10-05 17:24:24 UTC) #28
xhwang
Nice work! LGTM from my side with two last nits. Please wait for sandersd@'s response ...
4 years, 2 months ago (2016-10-05 17:36:42 UTC) #29
xjz
ping esprehn@: Does the changes to third_party/WebKit/* LGTY? The purpose of the changes there is ...
4 years, 2 months ago (2016-10-05 17:40:35 UTC) #30
miu
PS7 lgtm % nits: https://codereview.chromium.org/2389473002/diff/120001/content/renderer/render_frame_impl.cc File content/renderer/render_frame_impl.cc (right): https://codereview.chromium.org/2389473002/diff/120001/content/renderer/render_frame_impl.cc#newcode2725 content/renderer/render_frame_impl.cc:2725: std::unique_ptr<media::RendererFactory> media_renderer_factory( nit: This is ...
4 years, 2 months ago (2016-10-05 19:13:57 UTC) #31
sandersd (OOO until July 31)
> sandersd@: PTAL content::RenderFrameImpl::createMediaPlayer(), where > WMPI::ScheduleRestart() is set as a callback to RemotingController to ...
4 years, 2 months ago (2016-10-05 21:28:29 UTC) #32
miu
On 2016/10/05 21:28:29, sandersd wrote: > I would prefer something more like the delegate, where ...
4 years, 2 months ago (2016-10-05 21:40:53 UTC) #33
sandersd (OOO until July 31)
On 2016/10/05 21:40:53, miu wrote: > On 2016/10/05 21:28:29, sandersd wrote: > > I would ...
4 years, 2 months ago (2016-10-05 21:46:01 UTC) #34
xjz
Thanks miu@, xhwang@, and sandersd@! Addressed comments in PS8. https://codereview.chromium.org/2389473002/diff/100001/media/remoting/remoting_controller.cc File media/remoting/remoting_controller.cc (right): https://codereview.chromium.org/2389473002/diff/100001/media/remoting/remoting_controller.cc#newcode165 media/remoting/remoting_controller.cc:165: ...
4 years, 2 months ago (2016-10-05 23:39:02 UTC) #35
esprehn
foolip@ Can you help them with the full screen code? This patch doesn't feel right, ...
4 years, 2 months ago (2016-10-08 03:33:04 UTC) #45
xjz
Thanks esprehn@. What we want to do here is to notify WebMediaPlayer when user clicks ...
4 years, 2 months ago (2016-10-08 03:53:54 UTC) #46
dcheng
https://cs.chromium.org/chromium/src/third_party/WebKit/Source/web/FullscreenController.cpp?rcl=1475882812&l=65 may be a good starting point for this. FullscreenController::didEnterFullscreen() knows exactly what element is ...
4 years, 2 months ago (2016-10-08 05:02:32 UTC) #48
xjz
Thanks dcheng@! If the video element itself goes to full screen, WebMediaPlayer can get notified ...
4 years, 2 months ago (2016-10-08 05:13:00 UTC) #49
dcheng
On 2016/10/08 05:13:00, xjz wrote: > Thanks dcheng@! > > If the video element itself ...
4 years, 2 months ago (2016-10-08 06:06:29 UTC) #50
foolip
https://codereview.chromium.org/2389473002/diff/160001/media/base/media_observer.h File media/base/media_observer.h (right): https://codereview.chromium.org/2389473002/diff/160001/media/base/media_observer.h#newcode19 media/base/media_observer.h:19: // Called when the media element or its ancestor ...
4 years, 2 months ago (2016-10-10 08:35:22 UTC) #51
foolip
https://codereview.chromium.org/2389473002/diff/160001/third_party/WebKit/Source/web/FullscreenController.cpp File third_party/WebKit/Source/web/FullscreenController.cpp (right): https://codereview.chromium.org/2389473002/diff/160001/third_party/WebKit/Source/web/FullscreenController.cpp#newcode92 third_party/WebKit/Source/web/FullscreenController.cpp:92: Traversal<HTMLVideoElement>::descendantsOf(*element)) { On 2016/10/10 08:35:22, foolip wrote: > On ...
4 years, 2 months ago (2016-10-10 08:39:08 UTC) #52
xjz
On 2016/10/10 08:35:22, foolip wrote: > https://codereview.chromium.org/2389473002/diff/160001/media/base/media_observer.h > File media/base/media_observer.h (right): > > https://codereview.chromium.org/2389473002/diff/160001/media/base/media_observer.h#newcode19 > ...
4 years, 2 months ago (2016-10-10 17:48:48 UTC) #53
xjz
Thanks all for reviewing. It seems I may need re-think how to get notification when ...
4 years, 2 months ago (2016-10-10 19:31:02 UTC) #58
xhwang
A few thoughts on the ancestroEnteredFullscreen(). What if the video occupies the full window/tab (e.g. ...
4 years, 2 months ago (2016-10-10 20:12:02 UTC) #61
xjz
Thanks xhwang@. Replied in line. On 2016/10/10 20:12:02, xhwang wrote: > A few thoughts on ...
4 years, 2 months ago (2016-10-11 01:18:18 UTC) #64
xjz
esprehn@: need owner's approval on changes in content/*. PTAL Thanks!
4 years, 2 months ago (2016-10-11 01:30:22 UTC) #65
foolip
On 2016/10/10 17:48:48, xjz wrote: > Foolip@: Do you know if there is a way ...
4 years, 2 months ago (2016-10-11 09:38:52 UTC) #66
esprehn
This lgtm to me, but the plumbing between blink isn't clear to me, how does ...
4 years, 2 months ago (2016-10-11 21:42:23 UTC) #67
esprehn
On 2016/10/11 at 21:42:23, esprehn wrote: > This lgtm to me, but the plumbing between ...
4 years, 2 months ago (2016-10-11 22:03:41 UTC) #68
xjz
On 2016/10/11 21:42:23, esprehn wrote: > This lgtm to me, but the plumbing between blink ...
4 years, 2 months ago (2016-10-11 22:06:35 UTC) #69
xjz
On 2016/10/11 22:03:41, esprehn wrote: > On 2016/10/11 at 21:42:23, esprehn wrote: > > This ...
4 years, 2 months ago (2016-10-11 22:08:22 UTC) #70
esprehn
On 2016/10/11 at 22:06:35, xjz wrote: > On 2016/10/11 21:42:23, esprehn wrote: > > This ...
4 years, 2 months ago (2016-10-11 22:08:33 UTC) #71
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2389473002/200001
4 years, 2 months ago (2016-10-11 22:09:09 UTC) #74
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/278680)
4 years, 2 months ago (2016-10-11 22:20:42 UTC) #76
xjz
jam@: need approval for media/remoting/DEPS. Thanks!
4 years, 2 months ago (2016-10-11 22:29:29 UTC) #78
jam
lgtm
4 years, 2 months ago (2016-10-12 15:48:53 UTC) #79
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2389473002/200001
4 years, 2 months ago (2016-10-12 16:42:55 UTC) #81
commit-bot: I haz the power
Committed patchset #11 (id:200001)
4 years, 2 months ago (2016-10-12 18:27:03 UTC) #83
commit-bot: I haz the power
4 years, 2 months ago (2016-10-12 18:29:06 UTC) #85
Message was sent while issue was closed.
Patchset 11 (id:??) landed as
https://crrev.com/d3fe45a5f7f8395c26b5f75f0574487eb7618639
Cr-Commit-Position: refs/heads/master@{#424791}

Powered by Google App Engine
This is Rietveld 408576698