merge road cache

This commit is contained in:
tongchenfei
2021-03-11 14:06:17 +08:00
10 changed files with 511 additions and 355 deletions

View File

@@ -188,8 +188,7 @@ class AdasRecognizedResultDrawer extends BaseDrawer {
final long start = System.currentTimeMillis();
double[] matchedPoint = SnapshotSetDataDrawer.getInstance().matchRoad( recognizedListResult.lon,
double[] matchedPoint = SnapshotSetDataDrawer.getInstance().matchRoad( recognizedListResult.uuid, recognizedListResult.lon,
recognizedListResult.lat,
recognizedListResult.heading,
true

View File

@@ -208,14 +208,14 @@ class BaseDrawer {
* @param isRtk
* @return
*/
public double[] matchRoad( double lon, double lat, double angle, boolean isRtk ) {
public double[] matchRoad( String id, double lon, double lat, double angle, boolean isRtk ) {
final long start = System.currentTimeMillis();
double[] matchRoad = MogoApisHandler.getInstance()
.getApis()
.getMapServiceApi()
.getMapUIController()
.matchRoad( lon, lat, angle, true, isRtk );
Log.i( "timer-matchRoad", "cost " + ( System.currentTimeMillis() - start ) + "ms" );
.matchRoad( id, lon, lat, angle, true, isRtk );
Log.i("timer-matchRoad", "cost " + (System.currentTimeMillis() - start) + "ms");
return matchRoad;
}

View File

@@ -208,7 +208,8 @@ public class SimpleHandlerThreadPool {
}
}
double[] matchedPoint = SnapshotSetDataDrawer.getInstance().matchRoad( cloudRoadData.getWgslon(),
double[] matchedPoint = SnapshotSetDataDrawer.getInstance().matchRoad( cloudRoadData.getUniqueKey(),
cloudRoadData.getWgslon(),
cloudRoadData.getWgslat(),
cloudRoadData.getHeading(),
true