add func of tracker select of origin and obu sourve
This commit is contained in:
@@ -624,6 +624,31 @@ class DebugSettingView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
|
||||
// 初始化 tracker感知数据源 数据
|
||||
trackerProvider.check(
|
||||
when (FunctionBuildConfig.debugTrackerProvider) {
|
||||
0 -> {
|
||||
R.id.trackerProviderOrigin
|
||||
}
|
||||
1 -> {
|
||||
R.id.trackerProviderObu
|
||||
}
|
||||
else -> R.id.trackerProviderOrigin
|
||||
}
|
||||
)
|
||||
trackerProvider.setOnCheckedChangeListener { _, checkedId ->
|
||||
when (checkedId) {
|
||||
R.id.trackerProviderOrigin -> {
|
||||
FunctionBuildConfig.debugTrackerProvider = 0
|
||||
// update tracker provider view
|
||||
}
|
||||
R.id.trackerProviderObu -> {
|
||||
FunctionBuildConfig.debugTrackerProvider = 1
|
||||
// update tracker provider view
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// 初始化 ADAS感知数据是否绘制 选择情况
|
||||
tbIsDrawIdentifyData.isChecked = FunctionBuildConfig.isDrawIdentifyData
|
||||
|
||||
@@ -1729,6 +1729,35 @@
|
||||
|
||||
</RadioGroup>
|
||||
|
||||
<RadioGroup
|
||||
android:id="@+id/trackerProvider"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintTop_toBottomOf="@id/rgGpsProvider">
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/trackerProviderOrigin"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:padding="@dimen/dp_10"
|
||||
android:text="使用工控感知数据"
|
||||
android:textColor="#000"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/trackerProviderObu"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:padding="@dimen/dp_10"
|
||||
android:text="使用debugOBU感知数据"
|
||||
android:textColor="#000"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
</RadioGroup>
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@ class MapIdentifySubscriber private constructor() : IMoGoSubscriber,
|
||||
|
||||
override fun onAutopilotIdentifyDataUpdate(trafficData: List<TrackedObject>?) {
|
||||
try {
|
||||
if (FunctionBuildConfig.isDrawIdentifyData) {
|
||||
if (FunctionBuildConfig.isDrawIdentifyData && FunctionBuildConfig.debugTrackerProvider == 0) {
|
||||
ThreadUtils.getSinglePool().execute {
|
||||
IdentifyFactory.renderAdasRecognizedResult(trafficData)
|
||||
}
|
||||
@@ -56,10 +56,10 @@ class MapIdentifySubscriber private constructor() : IMoGoSubscriber,
|
||||
|
||||
override fun onAutopilotIdentifyPlanningObj(planningObjects: List<MessagePad.PlanningObject>?) {
|
||||
try {
|
||||
if (FunctionBuildConfig.isDrawIdentifyData) {
|
||||
ThreadUtils.getSinglePool()
|
||||
.execute {
|
||||
IdentifyFactory.renderPlanningWarningObj(planningObjects) }
|
||||
if (FunctionBuildConfig.isDrawIdentifyData && FunctionBuildConfig.debugTrackerProvider == 0) {
|
||||
ThreadUtils.getSinglePool().execute {
|
||||
IdentifyFactory.renderPlanningWarningObj(planningObjects)
|
||||
}
|
||||
} else {
|
||||
IdentifyFactory.clearOldMarker()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user