Chromium Code Reviews| Index: media/mojo/clients/mojo_cdm_factory.cc |
| diff --git a/media/mojo/clients/mojo_cdm_factory.cc b/media/mojo/clients/mojo_cdm_factory.cc |
| index 3837b0f57d238d3b1c0c3b595bf3e17cd2b928ab..7b2da3c8c942f1b4e4752b6760fc719d2d0f2627 100644 |
| --- a/media/mojo/clients/mojo_cdm_factory.cc |
| +++ b/media/mojo/clients/mojo_cdm_factory.cc |
| @@ -41,6 +41,12 @@ void MojoCdmFactory::Create( |
| return; |
| } |
| +// When MojoRenderer is used, the real Renderer is running in a remote process, |
| +// which cannot use an AesDecryptor running locally. In this case, always |
| +// create the MojoCdm, giving the remote CDM a chance to handle |key_system|. |
| +// Note: We should not run AesDecryptor in the browser process except for |
| +// testing. See http://crbug.com/441957 |
| +#if !defined(ENABLE_MOJO_RENDERER) |
|
yucliu1
2016/11/11 21:44:38
Can we have mojo cdm without mojo renderer?
xhwang
2016/11/11 21:45:54
Yes, MojoCdm can work with the existing local Rend
|
| if (CanUseAesDecryptor(key_system)) { |
| scoped_refptr<MediaKeys> cdm( |
| new AesDecryptor(security_origin, session_message_cb, session_closed_cb, |
|
yucliu1
2016/11/12 00:26:24
I remember the AesDecryptor::GetCdmId returns kInv
xhwang
2016/11/12 00:30:01
These are all remote decoders, which will not work
|
| @@ -49,6 +55,7 @@ void MojoCdmFactory::Create( |
| FROM_HERE, base::Bind(cdm_created_cb, cdm, "")); |
| return; |
| } |
| +#endif |
| mojom::ContentDecryptionModulePtr cdm_ptr; |
| service_manager::GetInterface<mojom::ContentDecryptionModule>( |