opt
This commit is contained in:
@@ -6,6 +6,7 @@ import com.mogo.commons.utils.MortonCode;
|
||||
import com.mogo.service.adas.entity.ADASRecognizedListResult;
|
||||
import com.mogo.service.adas.entity.ADASRecognizedResult;
|
||||
import com.mogo.service.adas.entity.ADASWarnMessage;
|
||||
import com.mogo.utils.CoordinateUtils;
|
||||
import com.zhidao.support.adas.high.bean.RectInfo;
|
||||
import com.zhidao.support.adas.high.bean.WarnMessageInfo;
|
||||
|
||||
@@ -66,8 +67,14 @@ class AdasObjectUtils {
|
||||
}
|
||||
ADASRecognizedResult result = new ADASRecognizedResult();
|
||||
result.uuid = rectBean.getUuid();
|
||||
result.lat = rectBean.getLat();
|
||||
result.lon = rectBean.getLon();
|
||||
double amapCoord[] = CoordinateUtils.transformFromWGSToGCJ( rectBean.getLat(), rectBean.getLon() );
|
||||
if ( amapCoord != null ) {
|
||||
result.lat = amapCoord[0];
|
||||
result.lon = amapCoord[1];
|
||||
} else {
|
||||
result.lat = rectBean.getLat();
|
||||
result.lon = rectBean.getLon();
|
||||
}
|
||||
result.type = Integer.valueOf( rectBean.getType() );
|
||||
result.heading = rectBean.getHeading();
|
||||
result.systemTime = Long.valueOf( rectBean.getSystemTime() );
|
||||
@@ -108,7 +115,8 @@ class AdasObjectUtils {
|
||||
recognizedListResult.distanceX = model.getDistance_x();
|
||||
recognizedListResult.distanceY = model.getDistance_y();
|
||||
}
|
||||
recognizedListResult.latLonList.add( new ADASRecognizedListResult.LatLon( model.getLat(), model.getLon() ) );
|
||||
double amapCoord[] = CoordinateUtils.transformFromWGSToGCJ( model.getLat(), model.getLon() );
|
||||
recognizedListResult.latLonList.add( new ADASRecognizedListResult.LatLon( amapCoord[0], amapCoord[1] ) );
|
||||
}
|
||||
}
|
||||
if ( result.isEmpty() ) {
|
||||
|
||||
@@ -3,8 +3,10 @@ package com.mogo.service.impl.map;
|
||||
import android.content.Context;
|
||||
|
||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||
import com.mogo.map.CoordinatesTransformer;
|
||||
import com.mogo.map.IMogoMapViewInstanceHandler;
|
||||
import com.mogo.map.MogoAimless;
|
||||
import com.mogo.map.MogoCoordinatesTransformer;
|
||||
import com.mogo.map.MogoGeoSearch;
|
||||
import com.mogo.map.MogoInputtipsSearch;
|
||||
import com.mogo.map.MogoLocationClient;
|
||||
@@ -74,7 +76,7 @@ public class MogoMapService implements IMogoMapService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public IMogoAimless getAimless(Context context) {
|
||||
public IMogoAimless getAimless( Context context ) {
|
||||
return MogoAimless.getInstance( context );
|
||||
}
|
||||
|
||||
@@ -113,6 +115,11 @@ public class MogoMapService implements IMogoMapService {
|
||||
return new MogoTrafficSearch();
|
||||
}
|
||||
|
||||
@Override
|
||||
public CoordinatesTransformer getCoordinatesTransformer() {
|
||||
return MogoCoordinatesTransformer.getInstance();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void init( Context context ) {
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user