-
Notifications
You must be signed in to change notification settings - Fork 6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Get few seconds black screen when switching to empty mid roll with DRM protected video #8568
Comments
I can't reproduce what you're seeing with a Pixel 3a XL. However I suspect it might be related to switching between secure and clear decoders. Can you try adding
More info: https://exoplayer.dev/drm.html#drm-sessions-for-clear-content |
Still reproduce in demo app when I adding |
Thanks for trying that - sorry it didn't work. I took a closer look and realised the I determined I couldn't reproduce because the symptom is device specific - a colleague was able to reproduce with their Samsung device. |
The `DrmConfiguration.sessionForClearTypes` property is often used to ensure a secure decoder is used for clear ads played in encrypted content. This is because some devices show black frames when switching decoders. Before this change the DRM config isn't propagated down when constructing the ad media source, meaning `DrmSessionManager.DRM_UNSUPPORTED` is always used, which will cause playback to switch from secure to clear decoder when transitioning to an ad break (ignoring the MediaItem `sessionForClearTypes` option. Issue: #8568 #minor-release PiperOrigin-RevId: 356951124
The `DrmConfiguration.sessionForClearTypes` property is often used to ensure a secure decoder is used for clear ads played in encrypted content. This is because some devices show black frames when switching decoders. Before this change the DRM config isn't propagated down when constructing the ad media source, meaning `DrmSessionManager.DRM_UNSUPPORTED` is always used, which will cause playback to switch from secure to clear decoder when transitioning to an ad break (ignoring the MediaItem `sessionForClearTypes` option. Issue: #8568 PiperOrigin-RevId: 356951124
Thanks for your support,But I tested 2.13.1 and it still getting black frame 1 seconds when the timeline approaches empty vast ad break, and I pass I assume that
|
You're right - there's two different things interacting here and we only fixed one of them. Specifically when the mid-roll is empty we still release and re-initialize the (secure) video decoder. With
With
This is what's causing the black screen you're seeing. I foolishly only checked that the decoder was kept for the non-empty midroll when testing (because that fires first) and didn't consider there might be a secondary behaviour that only affects empty ones. Re-opening to track keeping decoders alive during empty mid-roll ads. |
The secure decoder re-initialization is fixed by removing the I'll dupe this to that (since it affects more than just empty mid-rolls) - please follow that issue for further updates. |
[REQUIRED] Issue description
Playing DRM protected video in empty mid roll will appear about 1 seconds black screen. It's easy to reproduce in demo app.
[REQUIRED] Reproduction steps
2.Click HD(cenc)
3.Found that frame become black about 1 seconds with the second empty mid roll
[REQUIRED] Version
2.13.0
[REQUIRED] Device
Samsung Galaxy S10, Android 10
The text was updated successfully, but these errors were encountered: