[2.15.0] 不判断自车航向与事件航向角是否同向,由数据侧控制过滤非自车航向上的事件数据

This commit is contained in:
renwj
2023-03-29 11:27:51 +08:00
parent f32c5a3b2b
commit 93c1aacc7d
2 changed files with 2 additions and 3 deletions

View File

@@ -38,8 +38,7 @@ internal object V2NIdentifyDrawer {
}
val car = CallerChassisLocationWGS84ListenerManager.getChassisLocationWGS84()
val filtered = events.filterIsInstance(TrackedObject::class.java).filter { itx ->
val diff = DrivingDirectionUtils.getAngleDiff(car.heading, itx.heading)
diff < 40 && DrivingDirectionUtils.getDegreeOfCar2Poi(car.longitude, car.latitude, itx.longitude, itx.latitude, car.heading.toInt()) <= 90
DrivingDirectionUtils.getDegreeOfCar2Poi(car.longitude, car.latitude, itx.longitude, itx.latitude, car.heading.toInt()) <= 90
}
if (filtered.isEmpty()) {
return@Callback true

View File

@@ -55,7 +55,7 @@ class AiRoadMarker {
private val checkExpiredTask = Runnable {
val poi = this.marker.get()
val car = CallerChassisLocationWGS84ListenerManager.getChassisLocationWGS84()
if (poi != null && car != null) {
if (poi != null) {
val distance = CoordinateUtils.calculateLineDistance(car.longitude, car.latitude, poi.poi_lon, poi.poi_lat)
if (distance < 500) {
unMarker(poi)