gis-common 5.1.12 → 5.1.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/gis-common.es.js +10 -25
- package/dist/gis-common.umd.js +1 -1
- package/dist/utils/CommUtil.d.ts +1 -1
- package/dist/utils/GeoUtil.d.ts +2 -18
- package/package.json +1 -1
package/dist/utils/CommUtil.d.ts
CHANGED
package/dist/utils/GeoUtil.d.ts
CHANGED
|
@@ -120,15 +120,6 @@ export default class {
|
|
|
120
120
|
* @returns 墨卡托坐标对象,包含x和y属性
|
|
121
121
|
*/
|
|
122
122
|
static lonlatToMercator(lng: number, lat: number): Coordinate;
|
|
123
|
-
/**
|
|
124
|
-
* 根据百分比获取坐标
|
|
125
|
-
*
|
|
126
|
-
* @param start 起点坐标
|
|
127
|
-
* @param end 终点坐标
|
|
128
|
-
* @param percent 百分比,取值范围0-1
|
|
129
|
-
* @returns 返回插值后的坐标
|
|
130
|
-
*/
|
|
131
|
-
static interpolate({ x: x1, y: y1, z: z1 }: Coordinate, { x: x2, y: y2, z: z2 }: Coordinate, percent: number): Coordinate;
|
|
132
123
|
/**
|
|
133
124
|
* 计算三角形面积
|
|
134
125
|
*
|
|
@@ -146,22 +137,15 @@ export default class {
|
|
|
146
137
|
*/
|
|
147
138
|
static getPolygonCentroid(coords: Coordinate[] | LngLat[]): Coordinate;
|
|
148
139
|
/**
|
|
149
|
-
*
|
|
140
|
+
* 根据百分比获取坐标
|
|
150
141
|
*
|
|
151
142
|
* @param pA 线段起点,可以是Coordinate类型(包含x,y属性)或LngLat类型(包含lng,lat属性)
|
|
152
143
|
* @param pB 线段终点,可以是Coordinate类型(包含x,y属性)或LngLat类型(包含lng,lat属性)
|
|
153
144
|
* @param ratio 插值比例,0表示在起点pA,1表示在终点pB,0-1之间表示两点间的插值点
|
|
154
145
|
* @returns 返回插值点坐标,类型与输入参数保持一致
|
|
155
146
|
*/
|
|
156
|
-
static
|
|
147
|
+
static interpolate(pA: Coordinate | LngLat, pB: Coordinate | LngLat, ratio: number): {
|
|
157
148
|
x: number;
|
|
158
149
|
y: number;
|
|
159
|
-
lng?: undefined;
|
|
160
|
-
lat?: undefined;
|
|
161
|
-
} | {
|
|
162
|
-
lng: number;
|
|
163
|
-
lat: number;
|
|
164
|
-
x?: undefined;
|
|
165
|
-
y?: undefined;
|
|
166
150
|
};
|
|
167
151
|
}
|