-
Notifications
You must be signed in to change notification settings - Fork 165
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
Poor panning-by-dragging performance with multiple layers #829
Comments
Some notes that might help your investigations: In deck.gl, layers have a Another thought is that the auto highlighting feature does require picking on mouse move, you can also turn that off via the |
Thanks @ibgreen. The issue I have is that I do want all of my When dragging with multiple large I've yet to find an approach that allows me to avoid those unnecessary computationally-expensive hooks, while preserving standard |
Had a brainwave re. a workaround right after posting: a layer subclass which disables the offending hooks, swapped in when they're unneeded (e.g. when the mode is class ViewOnlyEditableGeoJsonLayer extends EditableGeoJsonLayer {
_onpointermove() { }
_onpanmove() { }
}
// in my deck-updating logic:
const layerClass = mode == ViewMode ? ViewOnlyEditableGeoJsonLayer : EditableGeoJsonLayer;
layers.push(new layerClass(layerProps));
deckInstance.setProps({ 'layers': layers }); This seems to fix performance while preserving layer state, but is limited to my use case, so I'm inclined to leave the issue open, as I think this affects the library's ability to scale. |
|
Describe the bug
When working with large data sets (10,000s of features across multiple EditableGeoJson layers), panning [edit: by dragging] slows to a crawl, because each layer calls
this.getPicks(...)
whether its mode needs picking data or not. Worse, it's called both in_onpointermove
and_onpanmove
which both fire.I suspect the
picks
object passed to all should be replaced with a lazy object / callable function, so it can be invoked only when needed.Actual Result
Panning can slow down to a few FPS
Expected Result
Panning FPS is unaffected by large datasets
The text was updated successfully, but these errors were encountered: