3dgeo-heidelberg / pytreedb

Python package providing a file and object-based database to store tree objects.
Other
28 stars 4 forks source link

Webfrontend: Select by map extent jumps #67

Closed bhoefle-3dgeo closed 2 years ago

bhoefle-3dgeo commented 2 years ago

The new and cool function "select by map extent" somehow alters the extent and it appears that it moves and even zooms out a little bit. the exact current map extent should be used and should stay when clicking on the button. Is it a coordinate rounding issue?

annachiu7 commented 2 years ago

I'm not sure how to replicate this issue. Actually, the exact bounds are sent to backend for geometric query with an accuracy of 15 decimal points. I think the appearance of extent altering comes from the new query - although the trees in these bounds are still the same, but the map is refreshed to better display those trees.

bhoefle-3dgeo commented 2 years ago

You can replicate it by zooming in to a bunch of trees and then press "Select by map extent" multiple times. Then it will change the map view extent and also add trees. Actually it should stay the same map extent and also the trees shown in the map extent should be the ones that are selected by this operation.

Could it be that by using "pan" on the map view, the trees are not reloaded and this might cause this effect. This could explain that more trees appear in the map view but not that the map extent is changed.

Is there a divergence between map view and map boundary in this library?

This bug was reproduced in Firefox and Chrome using the latest commit version.