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

Don't use pauseable placement when fadeDuration is 0 #7609

Closed
ChrisLoer opened this issue Nov 21, 2018 · 1 comment
Closed

Don't use pauseable placement when fadeDuration is 0 #7609

ChrisLoer opened this issue Nov 21, 2018 · 1 comment
Assignees

Comments

@ChrisLoer
Copy link
Contributor

When the global fadeDuration option is set to 0, we run collision detection on every frame, and short-circuit collision fade animations. This makes every frame significantly more expensive to render, but also is supposed to guarantee that when tiles load they have all their symbols fully drawn on the first frame.

Our short-circuiting logic doesn't take account for the fact that we will split collision detection between multiple frames if it takes longer than 2ms. So when a new tile loads, we'll immediately start running collision detection, but if it doesn't finish within 2ms, we'll go ahead and render the tile for a frame and then finish collision detection on the next frame.

I think we should just always do full placement when fadeDuration === 0. It's more expensive, but I think it's what people expect.

cc @tristen @mzdraper @ansis

@ChrisLoer ChrisLoer self-assigned this Nov 21, 2018
ChrisLoer added a commit that referenced this issue Nov 21, 2018
Fixes issue #7609: fadeDuration 0 didn't ensure every symbol would render immediately, if collision detection took longer than 2ms.
ChrisLoer added a commit that referenced this issue Nov 21, 2018
Fixes issue #7609: fadeDuration 0 didn't ensure every symbol would render immediately, if collision detection took longer than 2ms.
@ChrisLoer
Copy link
Contributor Author

Fixed in #7610.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant