| | |
| | | z = new BigDecimal(z).setScale(1,BigDecimal.ROUND_HALF_UP).doubleValue();*/ |
| | | return new double[]{p, t, z}; |
| | | } |
| | | /** |
| | | * 根据开始坐标点,角度,计算结束点坐标 |
| | | * @param startGlobalCoordinates |
| | | * @param startAngle 方向(以起点为中心) |
| | | * @param distance 距离(单位:m) |
| | | * @return |
| | | */ |
| | | public static GlobalCoordinates getGlobalCoordinates(GlobalCoordinates startGlobalCoordinates, double startAngle, double distance){ |
| | | return new GeodeticCalculator().calculateEndingGlobalCoordinates(Ellipsoid.WGS84, startGlobalCoordinates, startAngle, distance); |
| | | } |
| | | |
| | | public static void main(String[] args) { |
| | | // 125.097531,46.60029, 125.124731,46.584808 |