androidx / androidx/media

One or two black frames when using `switchTargetView`

Open
#1,994 3 comments 0 reactions 1 assignee View on GitHub

@oceanjules is already working on this.

Since Dec 23, 2024.

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

Description

Version

Media3 1.5.0

More version details

No response

Devices that reproduce the issue

Pixel 6 running API 35 (Android 15)

Devices that do not reproduce the issue

No response

Reproducible in the demo app?

Not tested

Reproduction steps

I need to transfer playback from one player view to another. I use Player.switchTargetView for this purpose. This results in one or two black frames when switching to the new player. Interestingly enough, I don't see this when switching back to the original player view.

I've also tried the attaching the new player view for a while to let the surfaces be created before doing this. Also, I'm using a texture view for this.

I don't have a video of the issue but you can observe the same behavior in this video: https://bsky.app/profile/halilibo.com/post/3la3cc6rdhm25

Expected result

There should be no black frames when switching player views.

Actual result

There are a few black frames when switching player views.

Media

I will share the media later (after the holidays)

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.