dev #561
@ -80,7 +80,7 @@ export const getCenterPoint = (point1, point2) => {
|
||||
* @returns
|
||||
*/
|
||||
export const getDistance = (x1, y1, x2, y2) => {
|
||||
return Math.sqrt(Math.pow(x2 - x1, 2) + Math.pow(y2 - y1, 2)).toFixed(0)
|
||||
return Math.sqrt(Math.pow(x2 - x1, 2) + Math.pow(y2 - y1, 2)).toFixed(1)
|
||||
}
|
||||
|
||||
// polygon의 각 변에 해당 점과 점 사이의 거리를 나타내는 IText를 추가하는 함수
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user