facebook / Rapid

The OpenStreetMap editor driven by open data, AI, and supercharged features
https://rapideditor.org
ISC License
515 stars 91 forks source link

Zoom Levels To Load/Hide OSM Feature Data Isn't Aligned And Causing Performance Issues #557

Open flow-enol opened 2 years ago

flow-enol commented 2 years ago

Description

-The zoom level at which Features are is hidden is at a much smaller scale than the zoom level they start loading. The amount of data rendering at this small scale causes lag and a bad user experience.

OSM Feature Data Loads at z15 - Data Hides at z11.75

Version

2.0-alpha

What browser are you seeing the problem on? What version are you running?

Opera GX [LVL4 {core: 89.0.4447.98) (x86_64)}

Steps to reproduce

Zoom in until features begin loading - Zoom out until they hide

The browser URL at the time you encountered the bug

https://mapwith.ai/rapid-v2-alpha#background=Bing&datasets=fbRoads,msBuildings&disable_features=boundaries&map=13.52/34.0095/-117.9127

bhousel commented 2 years ago

Thanks for reporting 👍 We are still working how how to thin out the scene once it gets very dense (this also relates to the Map Filters feature #552 that we haven't finished).

In the previous code, this map features module would just start dropping features once they passed a certain threshold (e.g. 200 points). It was very simple - implemented basically by filtering the "array of everything" before we handed it off to D3.js to render.

The new code works pretty differently, so will probably be a bit more sophisticated in how we filter out stuff from the scene. I think it would be great to allow people to edit large features at lower zooms than we could support before.

W1NT3RS0LD13R commented 1 year ago

🅆1🄽🅃3🅁 🅂0🄻🄳🄴🅁 47