google / google/ExoPlayer

Sometimes only audio is playing , video is black when using in RecyclerView

Open
#9,173 2 comments 1 reaction 1 assignee Claimed by @marcbaechinger View on GitHub
needs triage question
Dominant language
Java
Stars
21.9k
Forks
6k
PR merge metrics
No merged PRs in 30d

Description

I've checked previously closed similar issues but the discussion there didn't solve my issue.

The scenario is that I'm creating maximum 3 players to preload the videos. Player is assigned to UI cell when it is at center of screen. So, if user scrolls the recyclerView then urls for next videos are updated in existing players and matching player is set to new centered position. In normal case it is working fine but if I scroll up or down frequently then on view recycling when new content is updated then player shows a blink effect and sometimes completely goes black. The audio plays but video doesn't. If I make the player in playerView null and reassign the same player again. Then it works fine unless it is detached and attached again.

- ExoPlayer version number : 2.14.1
- Android version : 9 , 10
- Android device Huawei Y9 2019 , Pixel 3 respectively

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.