2025-01-03, 03:21 PM
(This post was last modified: 2025-01-03, 03:57 PM by theguymadmax. Edited 2 times in total.)
It seems that the file is initially attempted to play directly, but after a short time, an error occurs. This causes the system to fall back to transcoding the file, which then fails.
I experience the same issue when using ExoPlayer clients, such as the Jellyfin for ATV client, with 7.1 FLAC audio. I often see the following error in the debug logs:
As a workaround, I have to enable "Prefer FFMpeg for audio playback" in the Developer options on the Android TV client.
Edit: I found the same issue here. Unfortunately, there was no solution provided, only the workaround I mentioned.
I experience the same issue when using ExoPlayer clients, such as the Jellyfin for ATV client, with 7.1 FLAC audio. I often see the following error in the debug logs:
Code:
Audio codec error
androidx.media3.decoder.DecoderInputBuffer$InsufficientCapacityException: Buffer too small (32768 < 35493)
at androidx.media3.decoder.DecoderInputBuffer.createReplacementByteBuffer(DecoderInputBuffer.java:244)
at androidx.media3.decoder.DecoderInputBuffer.ensureSpaceForWrite(DecoderInputBuffer.java:195)
at androidx.media3.exoplayer.source.SampleDataQueue.readSampleData(SampleDataQueue.java:292)
at androidx.media3.exoplayer.source.SampleDataQueue.readToBuffer(SampleDataQueue.java:130)
at androidx.media3.exoplayer.source.SampleQueue.read(SampleQueue.java:440)
at androidx.media3.exoplayer.source.ProgressiveMediaPeriod.readData(ProgressiveMediaPeriod.java:539)
at androidx.media3.exoplayer.source.ProgressiveMediaPeriod$SampleStreamImpl.readData(ProgressiveMediaPeriod.java:1025)
at androidx.media3.exoplayer.BaseRenderer.readSource(BaseRenderer.java:557)
at androidx.media3.exoplayer.mediacodec.MediaCodecRenderer.feedInputBuffer(MediaCodecRenderer.java:1357)
at androidx.media3.exoplayer.mediacodec.MediaCodecRenderer.render(MediaCodecRenderer.java:877)
at androidx.media3.exoplayer.ExoPlayerImplInternal.doSomeWork(ExoPlayerImplInternal.java:1138)
at androidx.media3.exoplayer.ExoPlayerImplInternal.handleMessage(ExoPlayerImplInternal.java:562)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:223)
at android.os.HandlerThread.run(HandlerThread.java:67)
As a workaround, I have to enable "Prefer FFMpeg for audio playback" in the Developer options on the Android TV client.
Edit: I found the same issue here. Unfortunately, there was no solution provided, only the workaround I mentioned.