Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DefaultTimeBar glitches in PlayerView #9049

Closed
ppodgorski opened this issue Jun 11, 2021 · 0 comments
Closed

DefaultTimeBar glitches in PlayerView #9049

ppodgorski opened this issue Jun 11, 2021 · 0 comments
Assignees
Labels

Comments

@ppodgorski
Copy link

Issue description

I'm observing DefaultTimeBar glitches during seeking in PlayerView (in StyledPlayerView everything works fine). The problem present since version 2.13.

Reproduction steps

Just launch any demo app with PlayerView eg. demo-gl

A full bug report captured from the device

SVID_20210611_162810_1.mp4

Version of ExoPlayer being used

2.14.0

Device(s) and version(s) of Android being used

Huawei Mate 30 Pro, Android 10.0

@ojw28 ojw28 self-assigned this Jun 11, 2021
ojw28 added a commit that referenced this issue Jun 21, 2021
The glitches were introduced in:
6c31e34528

The problem is that Listener.onEvents is called in a later looper iteration
than the listener methods that were previously used. This created a gap on
the main thread between the UI component dispatching a seek operation to the
player, and onEvents being called to update the progress bar's position.

At the start of this gap the progress bar is rendering the new position,
but its position member variable is still set to the old position. If the
progress bar is re-drawn by another message on the main thread within the
gap, it will briefly show the old position until onEvents is called.

There are multiple possible fixes to this, and the best one is probably to
modify ListenerSet to remove the gap. That's high risk though, so for now we
fix the flicker by always updating the progress immediately after the seek
is dispatched, in addition to when onEvents is called.

Issue: #9049
#minor-release
PiperOrigin-RevId: 380678388
@ojw28 ojw28 closed this as completed Jun 21, 2021
icbaker pushed a commit that referenced this issue Jul 21, 2021
The glitches were introduced in:
6c31e34528

The problem is that Listener.onEvents is called in a later looper iteration
than the listener methods that were previously used. This created a gap on
the main thread between the UI component dispatching a seek operation to the
player, and onEvents being called to update the progress bar's position.

At the start of this gap the progress bar is rendering the new position,
but its position member variable is still set to the old position. If the
progress bar is re-drawn by another message on the main thread within the
gap, it will briefly show the old position until onEvents is called.

There are multiple possible fixes to this, and the best one is probably to
modify ListenerSet to remove the gap. That's high risk though, so for now we
fix the flicker by always updating the progress immediately after the seek
is dispatched, in addition to when onEvents is called.

Issue: #9049
PiperOrigin-RevId: 380678388
@google google locked and limited conversation to collaborators Aug 21, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants