Commit 79f1313d authored by Léo-Paul Géneau's avatar Léo-Paul Géneau 👾

erp5_officejs_drone_simulator: use map_size for coordinates projection

parent 032d55f1
......@@ -479,11 +479,11 @@ var MapManager = /** @class */ (function () {
lon = lon / 1000;
lon = lon * (map_dict.max_x - map_dict.min_x) +
map_dict.min_x;
lon = lon / (map_dict.width / 360.0) - 180;
lon = lon / (map_dict.map_size / 360.0) - 180;
lat = lat / 1000;
lat = lat * (map_dict.max_y - map_dict.min_y) +
map_dict.min_y;
lat = 90 - lat / (map_dict.depth / 180.0);
lat = 90 - lat / (map_dict.map_size / 180.0);
return {
x: lat,
y: lon,
......
......@@ -240,7 +240,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>1010.3592.54606.53538</string> </value>
<value> <string>1010.8830.44227.24780</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -260,7 +260,7 @@
</tuple>
<state>
<tuple>
<float>1690478004.4</float>
<float>1690793860.51</float>
<string>UTC</string>
</tuple>
</state>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment