Notify the client when ExoPlayer fallbacks to a different codec.

PiperOrigin-RevId: 377602447
This commit is contained in:
olly 2021-06-04 23:30:02 +01:00 committed by bachinger
parent efdd55fad5
commit 71fb7411ce

View file

@ -1038,6 +1038,7 @@ public abstract class MediaCodecRenderer extends BaseRenderer {
DecoderInitializationException exception =
new DecoderInitializationException(
inputFormat, e, mediaCryptoRequiresSecureDecoder, codecInfo);
onCodecError(exception);
if (preferredDecoderInitializationException == null) {
preferredDecoderInitializationException = exception;
} else {