开始研发最优路线推荐功能
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
package com.mogo.module.v2x.scenario.scene.pushVR;
|
||||
|
||||
import android.graphics.Color;
|
||||
|
||||
import com.mogo.map.marker.IMogoMarker;
|
||||
import com.mogo.map.overlay.IMogoPolyline;
|
||||
import com.mogo.map.overlay.MogoPolylineOptions;
|
||||
@@ -39,10 +41,6 @@ public class V2XPushVREventMarker implements IV2XMarker<V2XPushMessageEntity> {
|
||||
if (mMogoPolyline != null) {
|
||||
mMogoPolyline.remove();
|
||||
}
|
||||
|
||||
// 绘制事件点Marker
|
||||
PushRoadConditionDrawer.getInstance().drawRoadConditionMarker(entity);
|
||||
|
||||
// 绘制引导线
|
||||
drawablePloyLine(entity);
|
||||
drawableRecommendPolyline(entity);
|
||||
@@ -67,7 +65,7 @@ public class V2XPushVREventMarker implements IV2XMarker<V2XPushMessageEntity> {
|
||||
colors.add(0xFFFA8C34);
|
||||
|
||||
// 线条粗细,渐变,渐变色值
|
||||
options.width(15).useGradient(true).color(0xFF1F7EFF);
|
||||
options.width(300).useGradient(false).color(Color.argb(255, 255, 0, 0));
|
||||
|
||||
for (double[] doubles : entity.getPolyline()) {
|
||||
options.add(doubles[0], doubles[1]);
|
||||
|
||||
@@ -7,7 +7,9 @@ import android.util.Log;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
import android.widget.CompoundButton;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.ToggleButton;
|
||||
|
||||
import androidx.constraintlayout.widget.ConstraintLayout;
|
||||
import androidx.localbroadcastmanager.content.LocalBroadcastManager;
|
||||
@@ -62,7 +64,7 @@ public class V2XTestConsoleWindow extends ConstraintLayout {
|
||||
private Button mBtnTriggerEventUgc;
|
||||
private Button mBtnTriggerTrafficSearch;
|
||||
private Button mBtnTriggerRecommendRouteEvent;
|
||||
private Button nBtnTriggerVR;
|
||||
private ToggleButton nBtnTriggerVR;
|
||||
|
||||
private Button btnTriggerRearVIPCarTip,
|
||||
btnTriggerVehicleBrakes,
|
||||
@@ -140,10 +142,11 @@ public class V2XTestConsoleWindow extends ConstraintLayout {
|
||||
break;
|
||||
}
|
||||
|
||||
nBtnTriggerVR.setOnClickListener(new OnClickListener() {
|
||||
nBtnTriggerVR.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
|
||||
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
V2XServiceManager.getMoGoStatusManager().setVrMode("nBtnTriggerVR", true);
|
||||
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
|
||||
V2XServiceManager.getMoGoStatusManager().setVrMode("nBtnTriggerVR", isChecked);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginBottom="@dimen/dp_10"
|
||||
android:orientation="horizontal"
|
||||
app:alignContent="flex_start"
|
||||
app:alignItems="center"
|
||||
@@ -30,9 +31,8 @@
|
||||
<Button
|
||||
android:id="@+id/btnTriggerOpen"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="@dimen/dp_50"
|
||||
android:layout_marginEnd="@dimen/dp_10"
|
||||
android:layout_marginBottom="@dimen/dp_10"
|
||||
android:background="#FFF"
|
||||
android:padding="@dimen/dp_10"
|
||||
android:text="隐藏测试按钮面板"
|
||||
@@ -44,9 +44,8 @@
|
||||
<Button
|
||||
android:id="@+id/btnClearRoadEvent"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="@dimen/dp_50"
|
||||
android:layout_marginEnd="@dimen/dp_10"
|
||||
android:layout_marginBottom="@dimen/dp_10"
|
||||
android:background="#6BCF23"
|
||||
android:padding="@dimen/dp_10"
|
||||
android:text="清除缓存播报"
|
||||
@@ -55,16 +54,16 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent" />
|
||||
|
||||
<Button
|
||||
<ToggleButton
|
||||
android:id="@+id/btnTriggerVR"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="@dimen/dp_50"
|
||||
android:layout_marginEnd="@dimen/dp_10"
|
||||
android:layout_marginBottom="@dimen/dp_10"
|
||||
android:background="#6BCF23"
|
||||
android:padding="@dimen/dp_10"
|
||||
android:text="开启VR模式"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textOff="开启VR模式"
|
||||
android:textOn="关闭VR模式"
|
||||
android:textSize="@dimen/dp_22"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent" />
|
||||
|
||||
Reference in New Issue
Block a user