google / google/ExoPlayer

Stuttering audio when playing downloaded, encrypted dash content

Open
#10,682 6 comments 0 reactions 1 assignee Claimed by @icbaker View on GitHub
bug: device specific
Dominant language
Java
Stars
21.9k
Forks
6k
PR merge metrics
No merged PRs in 30d

Description

### ExoPlayer Version

2.18.1

### Devices that reproduce the issue

Samsung S7 edge running Android 8
Moto g power running Android 11

### Devices that do not reproduce the issue

Samsung s9 running Android 10
Samsung s10+ running Android 11
Pixel 4a running Android 13

### Reproducible in the demo app?

Not tested

### Reproduction steps

When playing downloaded audio at a speed greater than 1.0x and the device screen is off. After a few seconds audio stuttering will start to happen. I didn't test this in the demo app since background audio playback is not supported there, But I did put together a sample project using media from the demo app to reproduce the issue. The sample project can be found at https://github.com/ericharlow/AndroidAudioStutteringExample.

The sample app will download and then start playback of the content. Once playback starts, simply turn the screen off and wait a few seconds to 30 seconds for the stuttering to begin.

Any recommendations on how to stop the stuttering?

### Expected result

Audio playing in the background does not stutter.

### Actual result

Audio playing in the background does stutter and audio buffer underruns are observed.

### Media

I pulled media from the demo app.

https://storage.googleapis.com/wvmedia/cenc/h264/tears/tears.mpd
https://proxy.uat.widevine.com/proxy?video_id=2015_tears&provider=widevine_test

### Bug Report

- [X] You will email the zip file produced by `adb bugreport` to dev.exoplayer@gmail.com after filing this issue.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.