turf-junkyard / turf-line-distance

MIT License
3 stars 2 forks source link

take Z values (if present) into account when calculating distance #3

Closed gendronb closed 9 years ago

tmcw commented 9 years ago

This'll need a required option of how to interpret z values - the unit of the z value in geojson is unspecified.

gendronb commented 9 years ago

Exact. Could be a "useZ" option, like this :

true => use Z values, interpreted by default as "feet" string => unit used to interpret Z values (feet, meters, ...)

morganherlocker commented 9 years ago

This is a perfectly reasonable thing to want, but I think it would overcomplicate things for 99.9% of users. This would require users to have data formatted in a very particular & non standardized way, and to understand a bunch of things about super complex trigonometry and geography (remember that this algorithm is geodesic, not planar). This would be awesome, but I think it should probably be a separate module, where it can have more assumptions and knobs.

gendronb commented 9 years ago

Closing this for now then, thanks!