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

White flickering on resize in version 3.x.x #2971

Closed
there-it-is opened this issue Aug 11, 2023 · 4 comments · Fixed by #2986
Closed

White flickering on resize in version 3.x.x #2971

there-it-is opened this issue Aug 11, 2023 · 4 comments · Fixed by #2986
Labels
need more info Further information is requested

Comments

@there-it-is
Copy link

there-it-is commented Aug 11, 2023

maplibre-gl-js version:
3.3.0 and 3.2.0
browser:
Firefox & Chrome

Steps to Trigger Behavior

  1. Resize your browser with a full screen map

Expected Behavior

Does not flicker.
Especially because the behaviour in 2.4.0 on resize was better. Only the resized area was rerendered but not the complete map.

Actual Behavior

In Firefox is flickers very heavy on resize. In Chrome it gets completely white for a short time.

Thank you

@HarelM
Copy link
Collaborator

HarelM commented Aug 11, 2023

This has changed recently to better support container resize and not just window resize.
The following PR is the relevant one I believe: #2157.
It might be that there's a need to throttle this event, IDK.
Feel free to suggest a solution.

@HarelM HarelM added the need more info Further information is requested label Aug 11, 2023
@neodescis
Copy link
Collaborator

neodescis commented Aug 12, 2023

It does seem to behave a lot nicer if a debounce is used; I tried it with 50 milliseconds. Should it be configurable? We could change the trackResize option to take a boolean or a number, and default to 50 milliseconds if true or something like that.

@HarelM
Copy link
Collaborator

HarelM commented Aug 12, 2023

I'm not sure this should be configurable, but then hardcoded stuff tend to make their way to being configurable... IDK...

@neodescis
Copy link
Collaborator

neodescis commented Aug 12, 2023

I agree. I'll start with 25 or 50 in a PR, whatever seems like it works best, and we can go from there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
need more info Further information is requested
Projects
None yet
3 participants