coordConvert method

Future<BMFCoordinate> coordConvert (
  1. {@required BMFCoordinate coordinate,
  2. @required BMF_COORD_TYPE fromType,
  3. BMF_COORD_TYPE toType}
)

经纬度坐标之间的坐标转换

iOS支持:WGS84LL->BD09LL, WGS84LL->GCJ02LL, GCJ02LL->BD09LL, BD09LL->GCJ02LL

Android支持:WGS84LL->BD09LL, COMMON->BD09LL,BD09LL->COMMON

BMFCoordinate coordinate 源经纬度

BMF_COORD_TYPE fromType 源经纬度类型

BMF_COORD_TYPE toType 目标经纬度类型,iOS必传,Android不需要传(Android对于某一个输入经纬度类型 的输出经纬度类型是固定的

输入输出坐标为其他类型时,认为是非法输入,返回的坐标中经纬度均为0 或 null

返回 转换后的经纬度坐标

Implementation

static Future<BMFCoordinate> coordConvert(
    {@required BMFCoordinate coordinate,
    @required BMF_COORD_TYPE fromType,
    BMF_COORD_TYPE toType}) async {
  var toType;
  return await BMFUtilsCalculateDispatcher.coordTransDispatcher(
      _calcChannel, coordinate, fromType,
      toType: toType);
}