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

Issue 2006113002: Allow hw secured codecs on chromecast (Closed)

Created:
4 years, 7 months ago by yucliu1
Modified:
4 years, 2 months ago
CC:
blundell+watchlist_chromium.org, chromium-reviews, creis+watch_chromium.org, darin-cc_chromium.org, droger+watchlist_chromium.org, eme-reviews_chromium.org, feature-media-reviews_chromium.org, halliwell+watch_chromium.org, jam, lcwu+watch_chromium.org, mkwst+moarreviews-renderer_chromium.org, mlamouri+watch-content_chromium.org, nasko+codewatch_chromium.org, sdefresne+watchlist_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Allow hw secured codecs on chromecast The CL will allow chromecast see robustness configs in browser process. Audio devices will reject robustness with hardware features. 1. Add feature flag enable_hw_secure_codec, which is true on android and chromecast. 2. use_video_overlay_for_embedded_encrypted_video = true for chromecast video devices. BUG=470242 TEST=Audio device reject robustness HW_SECURE_*

Patch Set 1 #

Total comments: 4

Patch Set 2 : Nit #

Total comments: 15

Patch Set 3 : New flag, new key system property #

Total comments: 5
Unified diffs Side-by-side diffs Delta from patch set Stats (+112 lines, -48 lines) Patch
M android_webview/native/aw_settings.cc View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M chromecast/browser/android/cast_window_android.cc View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M chromecast/browser/cast_content_window.cc View 1 2 2 chunks +13 lines, -1 line 0 comments Download
M chromecast/browser/media/cast_browser_cdm_factory.cc View 1 chunk +0 lines, -3 lines 0 comments Download
M chromecast/renderer/key_systems_cast.cc View 1 2 3 chunks +56 lines, -13 lines 4 comments Download
M components/cdm/renderer/DEPS View 1 chunk +1 line, -0 lines 0 comments Download
M components/cdm/renderer/widevine_key_system_properties.h View 1 2 4 chunks +10 lines, -6 lines 0 comments Download
M components/cdm/renderer/widevine_key_system_properties.cc View 1 2 4 chunks +9 lines, -10 lines 0 comments Download
M content/common/view_messages.h View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M content/public/common/renderer_preferences.h View 1 2 1 chunk +4 lines, -0 lines 1 comment Download
M content/public/common/renderer_preferences.cc View 1 2 2 chunks +6 lines, -4 lines 0 comments Download
M content/renderer/render_frame_impl.cc View 1 2 2 chunks +2 lines, -7 lines 0 comments Download
M media/BUILD.gn View 1 chunk +1 line, -0 lines 0 comments Download
M media/base/key_systems.cc View 3 chunks +4 lines, -4 lines 0 comments Download
M media/media_options.gni View 1 chunk +3 lines, -0 lines 0 comments Download

Messages

Total messages: 18 (6 generated)
yucliu1
The patch would allow chromecast see correct CdmConfig::use_hw_secure_codecs on browser side and reject robustness >= ...
4 years, 7 months ago (2016-05-23 23:17:39 UTC) #3
esprehn
I think jochen@ might be a better reviewer for this?
4 years, 7 months ago (2016-05-23 23:34:40 UTC) #5
jrummell
media/ LGTM https://codereview.chromium.org/2006113002/diff/1/components/cdm/renderer/widevine_key_system_properties.cc File components/cdm/renderer/widevine_key_system_properties.cc (right): https://codereview.chromium.org/2006113002/diff/1/components/cdm/renderer/widevine_key_system_properties.cc#newcode138 components/cdm/renderer/widevine_key_system_properties.cc:138: #elif BUILDFLAG(ENABLE_HW_SECURE_CODEC) Should this be it's own ...
4 years, 7 months ago (2016-05-24 18:27:50 UTC) #6
yucliu1
https://codereview.chromium.org/2006113002/diff/1/components/cdm/renderer/widevine_key_system_properties.cc File components/cdm/renderer/widevine_key_system_properties.cc (right): https://codereview.chromium.org/2006113002/diff/1/components/cdm/renderer/widevine_key_system_properties.cc#newcode138 components/cdm/renderer/widevine_key_system_properties.cc:138: #elif BUILDFLAG(ENABLE_HW_SECURE_CODEC) On 2016/05/24 18:27:50, jrummell wrote: > Should ...
4 years, 7 months ago (2016-05-24 21:22:36 UTC) #7
ddorwin
https://codereview.chromium.org/2006113002/diff/20001/chromecast/browser/cast_content_window.cc File chromecast/browser/cast_content_window.cc (right): https://codereview.chromium.org/2006113002/diff/20001/chromecast/browser/cast_content_window.cc#newcode121 chromecast/browser/cast_content_window.cc:121: prefs->use_video_overlay_for_embedded_encrypted_video = true; This is currently related directly to ...
4 years, 7 months ago (2016-05-24 22:05:41 UTC) #9
yucliu1
https://codereview.chromium.org/2006113002/diff/20001/chromecast/browser/cast_content_window.cc File chromecast/browser/cast_content_window.cc (right): https://codereview.chromium.org/2006113002/diff/20001/chromecast/browser/cast_content_window.cc#newcode121 chromecast/browser/cast_content_window.cc:121: prefs->use_video_overlay_for_embedded_encrypted_video = true; On 2016/05/24 22:05:41, ddorwin wrote: > ...
4 years, 7 months ago (2016-05-24 22:26:33 UTC) #10
halliwell
https://codereview.chromium.org/2006113002/diff/20001/chromecast/browser/cast_content_window.cc File chromecast/browser/cast_content_window.cc (right): https://codereview.chromium.org/2006113002/diff/20001/chromecast/browser/cast_content_window.cc#newcode121 chromecast/browser/cast_content_window.cc:121: prefs->use_video_overlay_for_embedded_encrypted_video = true; On 2016/05/24 22:26:33, yucliu1 wrote: > ...
4 years, 7 months ago (2016-05-24 22:51:02 UTC) #11
ddorwin
https://codereview.chromium.org/2006113002/diff/20001/chromecast/browser/cast_content_window.cc File chromecast/browser/cast_content_window.cc (right): https://codereview.chromium.org/2006113002/diff/20001/chromecast/browser/cast_content_window.cc#newcode121 chromecast/browser/cast_content_window.cc:121: prefs->use_video_overlay_for_embedded_encrypted_video = true; On 2016/05/24 22:51:02, halliwell wrote: > ...
4 years, 7 months ago (2016-05-24 23:11:50 UTC) #13
yucliu1
https://codereview.chromium.org/2006113002/diff/20001/chromecast/renderer/key_systems_cast.cc File chromecast/renderer/key_systems_cast.cc (right): https://codereview.chromium.org/2006113002/diff/20001/chromecast/renderer/key_systems_cast.cc#newcode90 chromecast/renderer/key_systems_cast.cc:90: codecs, // Hardware-secure codecs. On 2016/05/24 23:11:50, ddorwin wrote: ...
4 years, 7 months ago (2016-05-25 00:43:21 UTC) #14
yucliu1
1. Add new flag hw_secure_codec_allowed. 2. Handle robustness config rule in chromecast's own widevine key ...
4 years, 7 months ago (2016-05-27 02:18:07 UTC) #15
ddorwin
I think there might be a much simpler solution. See the comment in /renderer_preferences.h. https://codereview.chromium.org/2006113002/diff/20001/components/cdm/renderer/widevine_key_system_properties.h ...
4 years, 6 months ago (2016-05-27 21:33:01 UTC) #16
yucliu1
4 years, 6 months ago (2016-06-14 00:17:46 UTC) #18
Sorry for the delay.

The simplest way to satisfy the requirement to reject hardware secured codec for
audio devices is to just change the widevine cdm configs. The drawback is that
browser side won't be able to know anything about user specified robustness
string through CdmConfig::use_hw_secure_codec. Given we don't rely on that flag
now, I'll go with the simple method (change widevine config).

I'll submit a new CL later.

https://codereview.chromium.org/2006113002/diff/40001/chromecast/renderer/key...
File chromecast/renderer/key_systems_cast.cc (right):

https://codereview.chromium.org/2006113002/diff/40001/chromecast/renderer/key...
chromecast/renderer/key_systems_cast.cc:133: EmeRobustness max_video_robustness
= EmeRobustness::INVALID;
On 2016/05/27 21:33:00, ddorwin wrote:
> This will cause all configurations to fail because EMPTY > INVALID.
> 
> We might want to DCHECK in the WidevineKeySystemProperties that the values are
>
> INVALID. It should only be returned when the string conversion fails.

This is guarded under DISABLE_DISPLAY. All video related config should be
rejected.

Powered by Google App Engine
This is Rietveld 408576698