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

Issue 1102363005: Initialize the CDM asynchronously (Closed)

Created:
5 years, 8 months ago by jrummell
Modified:
5 years, 7 months ago
CC:
binji+watch_chromium.org, bradnelson+warch_chromium.org, chromium-reviews, darin-cc_chromium.org, eme-reviews_chromium.org, feature-media-reviews_chromium.org, ihf+watch_chromium.org, jam, mcasas+watch_chromium.org, mkwst+moarreviews-renderer_chromium.org, mlamouri+watch-content_chromium.org, piman+watch_chromium.org, posciak+watch_chromium.org, raymes+watch_chromium.org, teravest+watch_chromium.org, tzik, wjia+watch_chromium.org, yusukes+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Initialize the CDM asynchronously Currently initialization happens asynchronously, but as Initialize() has no way to report success/failure, subsequent calls need to check that it succeeded. This change passes a promise to Initialize() so that the CDM can report success/failure properly. BUG=407435, 469003 TEST=EME tests pass Committed: https://crrev.com/87a2db5daf3fbada56114caa4bb61e596ad459a2 Cr-Commit-Position: refs/heads/master@{#328418}

Patch Set 1 #

Total comments: 8

Patch Set 2 : Create() changes #

Total comments: 16

Patch Set 3 : changes #

Total comments: 2

Patch Set 4 : nit #

Total comments: 2

Patch Set 5 : rebase + Android compile changes #

Unified diffs Side-by-side diffs Delta from patch set Stats (+288 lines, -204 lines) Patch
M chrome/browser/media/encrypted_media_browsertest.cc View 1 chunk +2 lines, -1 line 0 comments Download
M content/content_renderer.gypi View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download
A content/renderer/media/crypto/cdm_initialized_promise.h View 1 1 chunk +39 lines, -0 lines 0 comments Download
A content/renderer/media/crypto/cdm_initialized_promise.cc View 1 1 chunk +30 lines, -0 lines 0 comments Download
M content/renderer/media/crypto/ppapi_decryptor.h View 1 5 chunks +9 lines, -5 lines 0 comments Download
M content/renderer/media/crypto/ppapi_decryptor.cc View 1 2 5 chunks +30 lines, -16 lines 0 comments Download
M content/renderer/media/crypto/proxy_media_keys.h View 1 2 3 4 4 chunks +6 lines, -3 lines 0 comments Download
M content/renderer/media/crypto/proxy_media_keys.cc View 1 2 3 4 4 chunks +18 lines, -6 lines 0 comments Download
M content/renderer/media/crypto/render_cdm_factory.h View 1 1 chunk +1 line, -1 line 0 comments Download
M content/renderer/media/crypto/render_cdm_factory.cc View 1 2 3 4 3 chunks +27 lines, -22 lines 0 comments Download
M content/renderer/pepper/content_decryptor_delegate.h View 1 chunk +2 lines, -1 line 0 comments Download
M content/renderer/pepper/content_decryptor_delegate.cc View 2 chunks +4 lines, -2 lines 0 comments Download
M media/base/cdm_factory.h View 1 1 chunk +2 lines, -2 lines 0 comments Download
M media/blink/webmediaplayer_impl.cc View 1 2 3 4 1 chunk +3 lines, -1 line 0 comments Download
M media/cdm/ppapi/cdm_adapter.h View 1 2 2 chunks +3 lines, -2 lines 0 comments Download
M media/cdm/ppapi/cdm_adapter.cc View 1 2 3 4 5 chunks +19 lines, -58 lines 0 comments Download
M media/cdm/proxy_decryptor.cc View 1 chunk +7 lines, -8 lines 0 comments Download
M ppapi/api/private/ppp_content_decryptor_private.idl View 3 chunks +5 lines, -1 line 0 comments Download
M ppapi/c/private/ppp_content_decryptor_private.h View 5 chunks +10 lines, -6 lines 0 comments Download
M ppapi/cpp/private/content_decryptor_private.h View 1 chunk +2 lines, -1 line 0 comments Download
M ppapi/cpp/private/content_decryptor_private.cc View 2 chunks +5 lines, -4 lines 0 comments Download
M ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c View 5 chunks +50 lines, -50 lines 0 comments Download
M ppapi/proxy/ppapi_messages.h View 1 chunk +2 lines, -1 line 0 comments Download
M ppapi/proxy/ppp_content_decryptor_private_proxy.h View 1 chunk +1 line, -0 lines 0 comments Download
M ppapi/proxy/ppp_content_decryptor_private_proxy.cc View 3 chunks +9 lines, -13 lines 0 comments Download

Messages

Total messages: 25 (7 generated)
jrummell
PTAL.
5 years, 8 months ago (2015-04-27 19:58:17 UTC) #2
sandersd (OOO until July 31)
https://codereview.chromium.org/1102363005/diff/1/media/blink/webmediaplayer_impl.cc File media/blink/webmediaplayer_impl.cc (right): https://codereview.chromium.org/1102363005/diff/1/media/blink/webmediaplayer_impl.cc#newcode700 media/blink/webmediaplayer_impl.cc:700: void WebMediaPlayerImpl::SetCdm(const CdmAttachedCB& cdm_attached_cb, I'm not very familiar with ...
5 years, 8 months ago (2015-04-27 20:17:48 UTC) #3
jrummell
Comment only. https://codereview.chromium.org/1102363005/diff/1/media/blink/webmediaplayer_impl.cc File media/blink/webmediaplayer_impl.cc (right): https://codereview.chromium.org/1102363005/diff/1/media/blink/webmediaplayer_impl.cc#newcode700 media/blink/webmediaplayer_impl.cc:700: void WebMediaPlayerImpl::SetCdm(const CdmAttachedCB& cdm_attached_cb, On 2015/04/27 20:17:48, ...
5 years, 8 months ago (2015-04-27 21:24:38 UTC) #4
sandersd (OOO until July 31)
I'm not sold on diverging the interfaces for the different CDM hosts more, but I ...
5 years, 8 months ago (2015-04-27 23:32:14 UTC) #5
ddorwin
Start with the comments in the factory. https://codereview.chromium.org/1102363005/diff/1/content/renderer/media/crypto/ppapi_decryptor.h File content/renderer/media/crypto/ppapi_decryptor.h (right): https://codereview.chromium.org/1102363005/diff/1/content/renderer/media/crypto/ppapi_decryptor.h#newcode49 content/renderer/media/crypto/ppapi_decryptor.h:49: void InitializeCdm(const ...
5 years, 8 months ago (2015-04-27 23:52:18 UTC) #6
jrummell
Updated. https://codereview.chromium.org/1102363005/diff/1/content/renderer/media/crypto/render_cdm_factory.cc File content/renderer/media/crypto/render_cdm_factory.cc (right): https://codereview.chromium.org/1102363005/diff/1/content/renderer/media/crypto/render_cdm_factory.cc#newcode120 content/renderer/media/crypto/render_cdm_factory.cc:120: ppapi_decryptor->InitializeCdm(key_system, allow_distinctive_identifier, On 2015/04/27 23:52:18, ddorwin wrote: > ...
5 years, 7 months ago (2015-04-28 18:02:45 UTC) #7
ddorwin
LG overall. Thanks. https://codereview.chromium.org/1102363005/diff/20001/content/renderer/media/crypto/ppapi_decryptor.cc File content/renderer/media/crypto/ppapi_decryptor.cc (right): https://codereview.chromium.org/1102363005/diff/20001/content/renderer/media/crypto/ppapi_decryptor.cc#newcode52 content/renderer/media/crypto/ppapi_decryptor.cc:52: if (!ppapi_decryptor) { No need to ...
5 years, 7 months ago (2015-05-04 22:46:03 UTC) #8
jrummell
Updated. https://codereview.chromium.org/1102363005/diff/20001/content/renderer/media/crypto/ppapi_decryptor.cc File content/renderer/media/crypto/ppapi_decryptor.cc (right): https://codereview.chromium.org/1102363005/diff/20001/content/renderer/media/crypto/ppapi_decryptor.cc#newcode52 content/renderer/media/crypto/ppapi_decryptor.cc:52: if (!ppapi_decryptor) { On 2015/05/04 22:46:02, ddorwin wrote: ...
5 years, 7 months ago (2015-05-05 00:54:18 UTC) #9
ddorwin
LGTM with nit. Thanks. https://codereview.chromium.org/1102363005/diff/40001/media/cdm/ppapi/cdm_adapter.cc File media/cdm/ppapi/cdm_adapter.cc (right): https://codereview.chromium.org/1102363005/diff/40001/media/cdm/ppapi/cdm_adapter.cc#newcode342 media/cdm/ppapi/cdm_adapter.cc:342: (cdm != nullptr ? "" ...
5 years, 7 months ago (2015-05-05 15:34:50 UTC) #10
jrummell
+dcheng@ for ppapi/proxy/ppapi_messages.h +bbudge@ for the rest of the Pepper code https://codereview.chromium.org/1102363005/diff/40001/media/cdm/ppapi/cdm_adapter.cc File media/cdm/ppapi/cdm_adapter.cc (right): ...
5 years, 7 months ago (2015-05-05 17:12:18 UTC) #12
bbudge
Pepper LGTM w/formatting nit https://codereview.chromium.org/1102363005/diff/60001/ppapi/cpp/private/content_decryptor_private.cc File ppapi/cpp/private/content_decryptor_private.cc (right): https://codereview.chromium.org/1102363005/diff/60001/ppapi/cpp/private/content_decryptor_private.cc#newcode42 ppapi/cpp/private/content_decryptor_private.cc:42: ->Initialize(promise_id, key_system_var.AsString(), Formatting is strange. ...
5 years, 7 months ago (2015-05-05 17:40:03 UTC) #13
dcheng
ipc changes lgtm
5 years, 7 months ago (2015-05-05 18:26:52 UTC) #14
jrummell
Thanks for the reviews. https://codereview.chromium.org/1102363005/diff/60001/ppapi/cpp/private/content_decryptor_private.cc File ppapi/cpp/private/content_decryptor_private.cc (right): https://codereview.chromium.org/1102363005/diff/60001/ppapi/cpp/private/content_decryptor_private.cc#newcode42 ppapi/cpp/private/content_decryptor_private.cc:42: ->Initialize(promise_id, key_system_var.AsString(), On 2015/05/05 17:40:03, ...
5 years, 7 months ago (2015-05-05 18:30:48 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1102363005/60001
5 years, 7 months ago (2015-05-05 18:34:04 UTC) #18
commit-bot: I haz the power
Try jobs failed on following builders: linux_android_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_android_rel_ng/builds/19482)
5 years, 7 months ago (2015-05-05 19:05:00 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1102363005/80001
5 years, 7 months ago (2015-05-05 20:51:34 UTC) #23
commit-bot: I haz the power
Committed patchset #5 (id:80001)
5 years, 7 months ago (2015-05-05 22:27:47 UTC) #24
commit-bot: I haz the power
5 years, 7 months ago (2015-05-05 22:28:36 UTC) #25
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/87a2db5daf3fbada56114caa4bb61e596ad459a2
Cr-Commit-Position: refs/heads/master@{#328418}

Powered by Google App Engine
This is Rietveld 408576698