ArcGIS for JS 获取两点之间的距离

1  distance: function (p1, p2) {
2             var result = Math.sqrt(Math.pow(Math.abs(p1.x - p2.x), 2) + Math.pow(Math.abs(p1.y - p2.y), 2));
3             return result;
4         }
原文地址:https://www.cnblogs.com/gotoschool/p/14147767.html