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

Issue 840473002: media: Support creation and SetCdm() for mojo based CDM. (Closed)

Created:
5 years, 11 months ago by xhwang
Modified:
5 years, 6 months ago
Reviewers:
ddorwin
CC:
chromium-reviews, feature-media-reviews_chromium.org, qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org, abarth-chromium, Aaron Boodman, darin (slow to review), ben+mojo_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

media: Support creation and SetCdm() for mojo based CDM. - Add mojo::ContentDecryptionModuleFactory interface which helps request a ContentDecryptionModule service. This is needed because we need to pass in some information (e.g. key system and cdm ID) to request the correct service. - MojoCdmFactory is the proxy of mojo::ContentDecryptionModuleFactory. It is used when --enable-mojo-media-renderer is specified for HTMLViewer. - MojoCdmFactoryService implements mojo::ContentDecryptionModuleFactory. It uses MojoCdmServiceContext to help create MojoCdmServices. - MojoCdmServiceContext creates, owns and manages MojoCdmServices. It is owned by MojoMediaApplication and is passed to MojoRendererService so that when SetCdm(cdm_id) is called, MojoCdmService can find the correct CDM for |cdm_id| through MojoCdmServiceContext. - SetCdm() is implemented in MojoRenderer{Impl|Service}. BUG=432998 TEST=Clear Key supported in the media mojo app for prefixed EME API.

Patch Set 1 #

Total comments: 2

Patch Set 2 : #

Total comments: 16

Patch Set 3 : comments addressed/replied #

Total comments: 3

Patch Set 4 : rebase after ~2 month #

Patch Set 5 : make_scoped_ptr #

Patch Set 6 : Add CdmContextProvider. #

Patch Set 7 : Handle creation failure and add more logs. #

Patch Set 8 : Fix MojoRendererService hosted in browser process. #

Patch Set 9 : Fix TODO. #

Total comments: 22

Patch Set 10 : rebase only; compiles but needs more polish... #

Unified diffs Side-by-side diffs Delta from patch set Stats (+538 lines, -90 lines) Patch
M components/html_viewer/html_document.cc View 1 2 3 4 5 6 7 8 9 2 chunks +17 lines, -2 lines 0 comments Download
M components/html_viewer/setup.h View 1 2 3 4 5 6 7 8 9 2 chunks +4 lines, -0 lines 0 comments Download
M components/html_viewer/setup.cc View 1 2 3 4 5 6 7 8 9 3 chunks +5 lines, -6 lines 0 comments Download
M components/html_viewer/web_media_player_factory.cc View 1 2 3 4 5 6 7 8 9 1 chunk +4 lines, -4 lines 0 comments Download
M content/browser/frame_host/render_frame_host_impl.cc View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -1 line 0 comments Download
M media/base/cdm_context.h View 1 2 3 4 5 6 7 8 9 1 chunk +20 lines, -0 lines 0 comments Download
M media/base/cdm_context.cc View 1 2 3 4 5 1 chunk +10 lines, -2 lines 0 comments Download
M media/mojo/interfaces/BUILD.gn View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -0 lines 0 comments Download
M media/mojo/interfaces/content_decryption_module.mojom View 1 2 3 4 5 6 7 8 9 2 chunks +5 lines, -13 lines 0 comments Download
A media/mojo/interfaces/content_decryption_module_factory.mojom View 1 2 1 chunk +20 lines, -0 lines 0 comments Download
M media/mojo/interfaces/media_renderer.mojom View 1 2 3 4 5 6 7 8 9 1 chunk +4 lines, -0 lines 0 comments Download
M media/mojo/services/BUILD.gn View 1 2 3 4 5 6 7 8 9 3 chunks +7 lines, -0 lines 0 comments Download
M media/mojo/services/mojo_cdm.h View 1 2 3 4 5 6 7 8 9 4 chunks +11 lines, -1 line 0 comments Download
M media/mojo/services/mojo_cdm.cc View 1 2 3 4 5 6 7 8 9 12 chunks +23 lines, -0 lines 0 comments Download
A + media/mojo/services/mojo_cdm_factory.h View 1 2 3 4 5 6 7 8 9 2 chunks +14 lines, -9 lines 0 comments Download
A media/mojo/services/mojo_cdm_factory.cc View 1 2 3 4 5 6 7 8 9 1 chunk +49 lines, -0 lines 0 comments Download
A media/mojo/services/mojo_cdm_factory_service.h View 1 2 3 4 5 6 7 8 9 1 chunk +41 lines, -0 lines 0 comments Download
A media/mojo/services/mojo_cdm_factory_service.cc View 1 2 3 4 5 6 7 8 9 1 chunk +38 lines, -0 lines 0 comments Download
M media/mojo/services/mojo_cdm_service.h View 1 2 3 4 5 6 7 8 9 3 chunks +26 lines, -7 lines 0 comments Download
M media/mojo/services/mojo_cdm_service.cc View 1 2 3 4 5 6 7 8 9 9 chunks +57 lines, -27 lines 0 comments Download
A media/mojo/services/mojo_cdm_service_context.h View 1 2 3 4 5 6 7 8 9 1 chunk +47 lines, -0 lines 0 comments Download
A media/mojo/services/mojo_cdm_service_context.cc View 1 2 3 4 5 6 7 8 9 1 chunk +54 lines, -0 lines 0 comments Download
M media/mojo/services/mojo_media_application.cc View 1 2 3 4 5 6 7 8 9 2 chunks +24 lines, -6 lines 0 comments Download
M media/mojo/services/mojo_renderer_impl.cc View 1 2 3 4 5 6 7 8 9 1 chunk +8 lines, -2 lines 0 comments Download
M media/mojo/services/mojo_renderer_service.h View 1 2 3 4 5 6 7 8 9 3 chunks +17 lines, -8 lines 0 comments Download
M media/mojo/services/mojo_renderer_service.cc View 1 2 3 4 5 6 7 8 9 6 chunks +31 lines, -2 lines 0 comments Download

Messages

Total messages: 17 (3 generated)
xhwang
PTAL https://codereview.chromium.org/840473002/diff/1/media/mojo/services/mojo_media_application.cc File media/mojo/services/mojo_media_application.cc (right): https://codereview.chromium.org/840473002/diff/1/media/mojo/services/mojo_media_application.cc#newcode19 media/mojo/services/mojo_media_application.cc:19: static void EnableLoggingFromArgs(const std::vector<std::string>& args) { This is ...
5 years, 11 months ago (2015-01-05 23:52:38 UTC) #2
ddorwin
I reviewed through mojo_cdm_factory_service.cc. I'll wait until we resolve the cdm_id question before reviewing further. ...
5 years, 11 months ago (2015-01-06 00:57:28 UTC) #3
xhwang
+jamesr: Please see my comment in content_decryption_module_factory.mojom. Also, I am adding the ContentDecryptionModuleFactory interface so ...
5 years, 11 months ago (2015-01-06 19:54:54 UTC) #5
ddorwin
Reviewed the same files. Let's see what jamesr says about sync output params. https://codereview.chromium.org/840473002/diff/20001/media/mojo/interfaces/content_decryption_module_factory.mojom File ...
5 years, 11 months ago (2015-01-07 00:37:14 UTC) #6
jamesr
https://codereview.chromium.org/840473002/diff/20001/media/mojo/interfaces/content_decryption_module_factory.mojom File media/mojo/interfaces/content_decryption_module_factory.mojom (right): https://codereview.chromium.org/840473002/diff/20001/media/mojo/interfaces/content_decryption_module_factory.mojom#newcode13 media/mojo/interfaces/content_decryption_module_factory.mojom:13: int32 cdm_id, On 2015/01/06 19:54:54, xhwang wrote: > On ...
5 years, 11 months ago (2015-01-07 02:22:06 UTC) #7
xhwang
On 2015/01/07 02:22:06, jamesr wrote: > https://codereview.chromium.org/840473002/diff/20001/media/mojo/interfaces/content_decryption_module_factory.mojom > File media/mojo/interfaces/content_decryption_module_factory.mojom (right): > > https://codereview.chromium.org/840473002/diff/20001/media/mojo/interfaces/content_decryption_module_factory.mojom#newcode13 > ...
5 years, 11 months ago (2015-01-07 07:07:13 UTC) #8
jamesr
On 2015/01/07 07:07:13, xhwang wrote: > On 2015/01/07 02:22:06, jamesr wrote: > > > https://codereview.chromium.org/840473002/diff/20001/media/mojo/interfaces/content_decryption_module_factory.mojom ...
5 years, 11 months ago (2015-01-08 01:40:55 UTC) #9
xhwang
On 2015/01/08 01:40:55, jamesr wrote: > On 2015/01/07 07:07:13, xhwang wrote: > > On 2015/01/07 ...
5 years, 11 months ago (2015-01-20 22:26:56 UTC) #10
jamesr
Thanks for writing up the doc but I'm afraid I haven't had time to look ...
5 years, 11 months ago (2015-01-22 01:04:16 UTC) #12
xhwang
On 2015/01/22 01:04:16, jamesr wrote: > Thanks for writing up the doc but I'm afraid ...
5 years, 11 months ago (2015-01-23 00:51:02 UTC) #13
xhwang
ddorwin: I have rebased my CL and it is now ready for review. Thanks!
5 years, 9 months ago (2015-03-19 21:59:38 UTC) #14
ddorwin
https://codereview.chromium.org/840473002/diff/160001/media/base/cdm_context.h File media/base/cdm_context.h (right): https://codereview.chromium.org/840473002/diff/160001/media/base/cdm_context.h#newcode52 media/base/cdm_context.h:52: // Note: |cdm_id| is irrelevant to GetCdmId() of the ...
5 years, 7 months ago (2015-05-15 19:10:08 UTC) #15
xhwang
Parts of this CL is obsolete. So I am splitting this CL to smaller CLs ...
5 years, 6 months ago (2015-06-01 21:21:25 UTC) #16
xhwang
5 years, 6 months ago (2015-06-24 16:13:28 UTC) #17
This CL has been rebased, refactored and split into multiple smaller CLs, most
of which have been landed. As such, I'll close this CL now.

Powered by Google App Engine
This is Rietveld 408576698