androidx / androidx/media

Prepare second decoder in advance to avoid buffering at end of ad breaks

Open
#732 7 comments 0 reactions 1 assignee View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Java
Stars
3k
Forks
955
Avg merge
12d 14h
Merged PRs (30d)
2

Description

Version

ExoPlayer 2.19.1

More version details

It can also be reduced on ExoPlayer 2.18.5.

Devices that reproduce the issue

Not device-specific.

Devices that do not reproduce the issue

No response

Reproducible in the demo app?

Yes

Reproduction steps
  1. Add the sample below to the media.exolist.json file
{
        "name": "VMAP three empty midrolls, player buffer at ad points",
        "uri": "https://storage.googleapis.com/exoplayer-test-media-1/mkv/android-screens-lavf-56.36.100-aac-avc-main-1280x720.mkv",
        "ad_tag_uri": "https://run.mocky.io/v3/d3c23db8-aaf8-43a4-9690-3398a0f0f10f"
      }
  1. Add log to Player.onPlaybackStateChanged(@Player.State int playbackState) callback at PlayerActivity.PlayerEventListener
  2. Play the added sample video without seeking.

This issue can also be reproduced with the sample VMAP full, empty, full midrolls.
Screenshot 2023-10-17 at 10 42 54

Expected result

The ad point plays seamlessly when there are no ads, and there is no lag.
At least it shouldn’t be lag every time.

Actual result

There is almost always an onPlaybackStateChanged buffer callback at the first(10s) and third(30s) ad point, which causes the playback to freeze briefly(around 1s).
The second ad point(20s) also has a buffer callback sometimes.

Media

https://storage.googleapis.com/exoplayer-test-media-1/mkv/android-screens-lavf-56.36.100-aac-avc-main-1280x720.mkv

Bug Report
  • You will email the zip file produced by adb bugreport to android-media-github@google.com after filing this issue.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.