MediaCodec CryptoException: Operation not supported and CodecException when another video is playing in picture-in-picture
Hi
We have encountered some decryption errors in our app while another video streaming app is running in picture-in-picture mode on Google Pixel 2 phone with Android Oreo 8.1. The application running in picture-in-picture mode is Netflix. Netflix needs Android 8.1 for the picture-in-picture mode feature. The errors can be reproduced using the ExoPlayer demo app version 2.8.2.
Issue description
While another video stream is playing in picture-in-picture mode, in the ExoPlayer demo app from the Widevine Dash: MP4, H264 section select WV: Secure SD & HD(cenc,MP4,H264), and after 10 to 15 seconds of playback the first decryption error appears caused by android.media.MediaCodec$CryptoException with the message: Operation not supported in this configuration. (e1) Closing the ExoPlayer demo player window and trying to play the same stream from above again produes another decryption error: android.media.MediaCodec$CodecException: Error 0x80000000 (e2)
Reproduction steps
- On a Google Pixel 2 phone with Android Oreo 8.1, open the Netflix app, start a video playback and press the home system button. The video should continue playing in picture-in-picture mode.
- Open the ExoPlayer demo app and from the Widevine Dash: MP4, H264 section select WV: Secure SD & HD(cenc,MP4,H264).
- Wait for 10 to 15 seconds and the first decryption error (e1) should appear.
- Press the back key to close the ExoPlayer demo player window and select the same video stream again. The second decryption error (e2) should appear.
Version of ExoPlayer being used
ExoPlayer v2.8.2
Device(s) and version(s) of Android being used
Google Pixel 2 with Android Oreo 8.1.0
I have attached the console, logcat and bugreport logs for the e1 and e2 errors
Thank you.
Lucian
e1_bugreport-walleye-OPM2.171026.006.C1-2018-07-07-11-26-26.zip e1_console_log.txt e1_logcat.txt e2_bugreport-walleye-OPM2.171026.006.C1-2018-07-07-11-28-40.zip e2_console_log.txt e2_logcat.txt
@paf-wv - PTAL
we will need to reach out to QC and ask about some the decoder error that are in the logcat.
@paf-wv - Do you have an update on this issue? Thanks.
Pinged QC again.
We have been continuing to work with QC on this issue as reported on the Pixel 2. We are clarifying requirements for playing simultaneous encrypted streams. For current releases of Android, we do not test picture-in-picture for two encrypted streams, so we don't have a high degree of confidence it will work on devices in the field.
QC has provided an update that resolves this problem on Android 10 which will be available in the next quarterly platform release. If you accept this update you should find that picture-in-picture does not cause the CodecException now.