Which unit does JTS LineString.getLength() use
문제
I'm trying to figure out which unit JTS LineString.getLength() return.
for example:
LineString foo = (initialize line string somehow)
foo.getLength() -> 7.025667228118838E-4
Are these Kilometers?, Meters?, Feet?
해결책 2
It's in degrees.
다른 팁
It depends in which unit your coordinate geometries are expressed. If your coordinates are in meters, the perimeter will also be in meters.
com.vividsolutions.jts.geom.Geometry.getLength() returns a length/perimeter in meters. com.vividsolutions.jts.geom.Geometry.getArea() returns an area in squaremeters.
제휴하지 않습니다 StackOverflow