平移+取消画线

This commit is contained in:
liujing
2021-04-01 15:15:41 +08:00
parent 1b113c29dd
commit 959304efe8
3 changed files with 14 additions and 6 deletions

1
.idea/gradle.xml generated
View File

@@ -91,7 +91,6 @@
</set>
</option>
<option name="resolveModulePerSourceSet" value="false" />
<option name="useQualifiedModuleNames" value="true" />
</GradleProjectSettings>
</option>
</component>

View File

@@ -19,6 +19,7 @@ import com.mogo.utils.WorkThreadHandler;
import java.util.ArrayList;
import java.util.List;
import java.util.logging.Handler;
/**
* @author liujing
@@ -90,11 +91,19 @@ public class V2XWarningMarker implements IV2XMarker {
MogoLatLng endLocation = new MogoLatLng(mMarkerEntity.getCollisionLat(), mMarkerEntity.getCollisionLon());
latLngs.add(sLocation);
latLngs.add(endLocation);
marker.startSmoothInMs(latLngs, 15000);
marker.startSmoothInMs(latLngs, 3000);
WorkThreadHandler.getInstance().postDelayed(() -> {
clearLine();
}, 3_000);
}
@Override
public void clearPOI() {
V2XServiceManager.getMarkerManager().removeMarkers(V2XConst.V2X_FRONT_WARNING_MARKER);
}
public void clearLine() {
V2XServiceManager.getMoGoWarnPolylineManager().clearLine();
}
}

View File

@@ -3,16 +3,16 @@
"lat":39.977148,
"lon":116.417478,
"distance": 2.22,
"collisionLat": 39.977131,
"collisionLon": 116.417741,
"collisionLat": 39.977094,
"collisionLon": 116.417634,
"from": 1,
"angle": 120,
"direction": 10014,
"speed":11.108121,
"targetColor": "#FF4040",
"stopLineDistance":20,
"stopLineLat": 39.977123,
"stopLineLon": 116.417537,
"stopLineLat": 39.977094,
"stopLineLon": 116.417634,
"warningContent": "小心行人",
"heading": 30
}