[base_3.4.0-map-sdk]

This commit is contained in:
zhongchao
2023-08-18 18:42:12 +08:00
parent 10b5933c03
commit fc25630dc4
43 changed files with 644 additions and 790 deletions

View File

@@ -1,28 +1,93 @@
package com.mogo.map
import com.mogo.map.center.CenterLine
import com.mogo.eagle.core.data.map.MogoLocation
import com.zhidaoauto.map.data.road.CenterLine
interface IMogoData {
fun setDebugMode(debugMode: Boolean)
/**
* 获取行驶方向一定长度的中心线
*
* @param lon 经
* @param lat 纬
* @param angle 航向角
* @param distance 获取车道中心线的长度,> 0: 行驶方向前方距离, <0 行驶方向后方距离
* @return 中心线相关数据
* 获取车道中心线数据
* @param lon 经度
* @param lat 纬
* @param angle 角
* @param call 回调
*/
fun getCenterLineRangeInfo(lon: Double, lat: Double, angle: Float, distance: Float): CenterLine?
fun getCenterLineInfo(lon: Double, lat: Double, angle: Float, call: ((CenterLine?) -> Unit))
/**
* 按距离获取道路数据
* @param lon 经度
* @param lat 纬度
* @param angle 角度
* @param call 回调
*/
fun getCenterLineRangeInfo(
lon: Double,
lat: Double,
angle: Float,
distance: Float,
call: ((Int, com.mogo.map.center.CenterLine?) -> Unit)
call: ((CenterLine?) -> Unit)
)
/**
* 获取车道限速
* @param lon 经度
* @param lat 纬度
* @param angle 角度
* @param call 回调
*/
fun getLimitSpeed(lon: Double, lat: Double, angle: Float, call: ((Int) -> Unit))
/**
* 获取道路角度
* @param lon 经度
* @param lat 纬度
* @param angle 角度
* @param call 回调
*/
fun getRoadAngle(lon: Double, lat: Double, angle: Float, call: ((Double) -> Unit))
/**
* 获取道路宽度
*/
fun getRoadWidth(lon: Double, lat: Double, angle: Float, isGpsLocation: Boolean, isRTK: Boolean): Float
/**
* 获取行车方向
*
* @return
*/
fun getAngle(startLon: Double, startLat: Double, endLon: Double, endLat: Double): Float
/**
* 获取瓦片id
*
* @param lon 经度
* @param lat 纬度
* @return 瓦片id
*/
fun getTileId(lon: Double, lat: Double): Long
/**
* 通过cityCode,缓存城市HDMap
*/
fun cacheHDDataByCity(progress:((cityId: Int, progress: Double) -> Unit), result:((cityId: Int, state: Int) -> Unit))
/**
* 通过经纬度信息缓存城市HDMap
*/
fun cacheHDDataByCityByLonLat(location: MogoLocation, progress:((cityId: Int, progress: Double) -> Unit), result:((cityId: Int, state: Int) -> Unit))
/**
* 当前城市离线数据是否已缓存
*/
fun isCityDataCached(cache:((Boolean) -> Unit))
/**
* 取消下载 城市HDMap
*/
fun cancelDownloadCacheData()
}