-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Clear source tiles for removed/re-added layer #3655
Conversation
Fixes #3633 by distinguishing the cases where the source tiles need to be _reloaded_ from those where they need to be _cleared_
Needs mapbox/mapbox-gl-test-suite#179 to be merged and then the test-suite dependency updated here. #monorepo |
// set up for the _previous_ version of this layer, confusing | ||
// https://github.com/mapbox/mapbox-gl-js/issues/3633 | ||
delete this._removedLayers[id]; | ||
this._updatedSources[layer.source] = 'clear'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think is going to introduce a flash in cases where remove/add
was being used to re-order the layers.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
better than introducing corrupt buffers!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will these tiles still be marked as reloading
within SourceCache
? As it is defined now, reloading
means that there is an asynchronous update underway and the tiles are still renderable.
Is there a need for another state that means there is an asynchronous update underway and the tiles are NOT renderable? Or is there a need to redefine reloading
?
cc @mourner |
^ also re: the 'flash' thing -- I think |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is ready to
Fixes #3633 by distinguishing the cases where the source tiles need to
be reloaded from those where they need to be cleared