radius calculation for new panorama search based on latitude and mercator projection for google maps #36

Merged
balazs merged 1 commits from feature/more-accurate-new-selection-in-mapeditor-on-google-maps into develop 2021-05-02 18:02:29 +02:00
Member

Current state
Street View Cover layout enables accurate place selection for the MapEditor. However when searching for a panorama for the new selection, it tends to prefer road layout (blue marker on the attached image) over other view points (green marker) even if the road is further away to the selected position. Technically makes the selection of green marker impossible.

Improvement
This feature calculates the radius dynamically based on the zoom level and latitude of the selected position using Mercator projection.

  • At higher zoom levels the search radius will be lower, and it forces Google Street View to look for a panorama at the exact location.
  • At lower zoom levels it will more likely return a valid panorama due to higher search radius.
**Current state** Street View Cover layout enables accurate place selection for the MapEditor. However when searching for a panorama for the new selection, it tends to prefer road layout (blue marker on the attached image) over other view points (green marker) even if the road is further away to the selected position. Technically makes the selection of green marker impossible. **Improvement** This feature calculates the radius dynamically based on the zoom level and latitude of the selected position using Mercator projection. * At higher zoom levels the search radius will be lower, and it forces Google Street View to look for a panorama at the exact location. * At lower zoom levels it will more likely return a valid panorama due to higher search radius.
balazs added 1 commit 2021-05-02 17:13:53 +02:00
balazs requested review from bence 2021-05-02 17:14:04 +02:00
Owner

The main problem is that indoor panoramas are searched first, so it doesn't matter if an indoor panorama is closer if there is any outdoor panorama in the 100m radius. (It is not always correctly determined if a panorama is indoor or outdoor, for example paromaras that are uploaded by users are mostly classified indoor.) Indoor panoramas are found only if there is absolutely no outdoor panoramas in 100m.

Maybe this searching algorithm can be changed because it was implemented for the cases when accurate place selection was not possible and I wanted to prefer outdoor panoramas over indoor.

However the change is OK because changing the radius based on the zoom level is a good solution anyways.

The main problem is that [indoor panoramas are searched first](https://gitea.e5tv.hu/esoko/mapguesser/src/branch/develop/public/static/js/map_editor.js#L90), so it doesn't matter if an indoor panorama is closer if there is any outdoor panorama in the 100m radius. (It is not always correctly determined if a panorama is indoor or outdoor, for example paromaras that are uploaded by users are mostly classified indoor.) Indoor panoramas are found only if there is absolutely no outdoor panoramas in 100m. Maybe this searching algorithm can be changed because it was implemented for the cases when accurate place selection was not possible and I wanted to prefer outdoor panoramas over indoor. However the change is OK because changing the radius based on the zoom level is a good solution anyways.
bence approved these changes 2021-05-02 17:51:11 +02:00
balazs merged commit cc24f96395 into develop 2021-05-02 18:02:29 +02:00
bence deleted branch feature/more-accurate-new-selection-in-mapeditor-on-google-maps 2021-05-02 19:45:26 +02:00
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: esoko/mapguesser#36
No description provided.