GeodesicDistanceMeters
页面属性、测量与地理空间
描述
返回两组 WGS 84 纬度经度对之间的地面距离(米)
语法
Delphi
Function TPDFlib.GeodesicDistanceMeters(Latitude1, Longitude1, Latitude2, Longitude2: Double): Double;
DLL
int DLGeodesicDistanceMeters(int InstanceID, double Latitude1, double Longitude1, double Latitude2, double Longitude2, PDouble Distance);
此导出在 Windows DLL、macOS Dylib 和 Linux 共享库中可用
ActiveX
Function PDFlib::GeodesicDistanceMeters(Latitude1 As Double, Longitude1 As Double, Latitude2 As Double, Longitude2 As Double) As Double
在 IPDFlibrary21 上可用。使用生成类型库单元的 Delphi 客户可通过 CoPDFlibrary.CreateEditionTools21 获取
自动化直接返回距离。零表示重合点或无效坐标
参数
| Latitude1, Latitude2 | -90 至 90 度的纬度 |
|---|---|
| Longitude1, Longitude2 | -180 至 180 度的经度 |
| Distance | 通过 DLL 函数接收米制结果 |
返回值
Pascal 与 ActiveX 返回以米为单位的距离,重合点包括零,无效输入也返回零。DLL 函数对有效坐标(包括重合点)返回 1。无效坐标返回 0 并将可写距离结果置零
备注
正常路径在 WGS 84 椭圆体上测量。若逆解在对跑点附近不收敛,则改用平均半径球面近似。无需文档
另请参阅
PagePointToLatLon · LatLonToPagePoint · GeodesicPolygonAreaSqMeters · PageGeoViewportDistanceMeters