terriajs
terriajs copied to clipboard
Accuracy of measurement with the line tool - investigation
User feedback:
When in 2D the measure distance tool in Terria draws a straight line. Shouldn't that be the orthodromic line as google maps does? Also, the distances are quite different, 11500 km vs 14700km in Buenos Aires to Darwin. It seems that google maps is the right one (http://www.gcmap.com/mapui?P=DRW-EZE).
There are two issues here, both are in Leaflet/2D mode (there are no problems in Cesium/3D mode):
- distance is wrong
- straight line should be a great arc in Leaflet mode
For 1 - the distance, I talked to the user and what they actually did was create the distance in two stages. First they clicked on Darwin and then they clicked somewhere between Darwin and South America, then they adjusted the area visible on the screen, and then they moved the second point to Buenos Aires. There is 1 or 2 bugs here: firstly, in 3D mode we can't move points but in 2D you can, secondly when you move a point in 2D the distance is not recalculated. We should decide what to fix.
For 2 - straight line we should make it draw a great circle, hopefully there is just a function to do that in Leaflet already, or on the internet somewhere.
something from here ? https://leafletjs.com/plugins.html#measurement like this one: https://github.com/ppete2/Leaflet.PolylineMeasure !!! big win win for Terria!!! 👍👍👍
Update 15 Feb 23:
- in progress