|
@@ -35,10 +35,10 @@ public class LaLonUtil {
|
|
|
double offsetLatitude = width / 111000; // 纬度方向上的偏移量(单位:米)
|
|
|
|
|
|
// 根据中心点和偏移量计算矩形四个顶点的经纬度坐标
|
|
|
- Coordinate corner1 = new Coordinate(centerLongitude - offsetLongitude, centerLatitude - offsetLatitude);
|
|
|
- Coordinate corner2 = new Coordinate(centerLongitude + offsetLongitude, centerLatitude - offsetLatitude);
|
|
|
- Coordinate corner3 = new Coordinate(centerLongitude + offsetLongitude, centerLatitude + offsetLatitude);
|
|
|
- Coordinate corner4 = new Coordinate(centerLongitude - offsetLongitude, centerLatitude + offsetLatitude);
|
|
|
+ Coordinate corner1 = new Coordinate(startLond - offsetLongitude, strLatd - offsetLatitude);
|
|
|
+ Coordinate corner2 = new Coordinate(startLond + offsetLongitude, strLatd - offsetLatitude);
|
|
|
+ Coordinate corner3 = new Coordinate(endLond + offsetLongitude, endLatd + offsetLatitude);
|
|
|
+ Coordinate corner4 = new Coordinate(endLond - offsetLongitude, endLatd + offsetLatitude);
|
|
|
PointRpcDTO pointRpcDTO1=new PointRpcDTO();
|
|
|
pointRpcDTO1.setSort("1");
|
|
|
pointRpcDTO1.setSerial("1");
|