[8.0.0]去掉提前减速语音提示
This commit is contained in:
@@ -238,42 +238,42 @@ class TrafficLightDispatcher : IMoGoAutopilotIdentifyListener, IMoGoTrafficLight
|
||||
}
|
||||
}
|
||||
|
||||
if(AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)
|
||||
&& AppIdentityModeUtils.isTaxi(FunctionBuildConfig.appIdentityMode) && !isPrompted){
|
||||
//车辆行驶中,若判断当前绿灯自车无法通过,在绿灯剩余5s且下一灯态为红/黄灯时,提示“蘑菇提醒您及时减速,避免路口急刹”
|
||||
if(light.state == FusionTrafficLightOuterClass.FusionLightState.STATE_GREEN_FUSION && light.duration < 5){
|
||||
CallerMapRoadListenerManager.getStopLineDistance()?.let { dis->
|
||||
if(currentSpeed*light.duration < dis){
|
||||
//语音播放:蘑菇提醒您及时减速,避免路口急刹
|
||||
AIAssist.getInstance(mContext).speakTTSVoice(
|
||||
"${SkinResources.getInstance().getString(R.string.operation_platform_name)}提醒您及时减速,避免路口急刹")
|
||||
isPrompted = true
|
||||
}
|
||||
}
|
||||
}
|
||||
//车辆行驶中,若判断当前绿灯自车基于当前速度需提速10%以上才可通过时,提示“蘑菇提醒您及时减速,避免路口急刹”
|
||||
if(light.state == FusionTrafficLightOuterClass.FusionLightState.STATE_GREEN_FUSION){
|
||||
CallerMapRoadListenerManager.getStopLineDistance()?.let{distance->
|
||||
if(currentSpeed*light.duration*1.1 < distance){
|
||||
//语音播放:蘑菇提醒您及时减速,避免路口急刹
|
||||
AIAssist.getInstance(mContext).speakTTSVoice(
|
||||
"${SkinResources.getInstance().getString(R.string.operation_platform_name)}提醒您及时减速,避免路口急刹")
|
||||
isPrompted = true
|
||||
}
|
||||
}
|
||||
}
|
||||
//车辆行驶中,若判断当前红灯自车基于当前速度需降低60%以上才可通过时,提示“蘑菇提醒您及时减速,避免路口急刹”
|
||||
if(light.state ==FusionTrafficLightOuterClass.FusionLightState.STATE_RED_FUSION){
|
||||
CallerMapRoadListenerManager.getStopLineDistance()?.let{distance->
|
||||
if(currentSpeed*0.4*light.duration > distance){
|
||||
//语音播放:蘑菇提醒您及时减速,避免路口急刹
|
||||
AIAssist.getInstance(mContext).speakTTSVoice(
|
||||
"${SkinResources.getInstance().getString(R.string.operation_platform_name)}提醒您及时减速,避免路口急刹")
|
||||
isPrompted = true
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// if(AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)
|
||||
// && AppIdentityModeUtils.isTaxi(FunctionBuildConfig.appIdentityMode) && !isPrompted){
|
||||
// //车辆行驶中,若判断当前绿灯自车无法通过,在绿灯剩余5s且下一灯态为红/黄灯时,提示“蘑菇提醒您及时减速,避免路口急刹”
|
||||
// if(light.state == FusionTrafficLightOuterClass.FusionLightState.STATE_GREEN_FUSION && light.duration < 5){
|
||||
// CallerMapRoadListenerManager.getStopLineDistance()?.let { dis->
|
||||
// if(currentSpeed*light.duration < dis){
|
||||
// //语音播放:蘑菇提醒您及时减速,避免路口急刹
|
||||
// AIAssist.getInstance(mContext).speakTTSVoice(
|
||||
// "${SkinResources.getInstance().getString(R.string.operation_platform_name)}提醒您及时减速,避免路口急刹")
|
||||
// isPrompted = true
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// //车辆行驶中,若判断当前绿灯自车基于当前速度需提速10%以上才可通过时,提示“蘑菇提醒您及时减速,避免路口急刹”
|
||||
// if(light.state == FusionTrafficLightOuterClass.FusionLightState.STATE_GREEN_FUSION){
|
||||
// CallerMapRoadListenerManager.getStopLineDistance()?.let{distance->
|
||||
// if(currentSpeed*light.duration*1.1 < distance){
|
||||
// //语音播放:蘑菇提醒您及时减速,避免路口急刹
|
||||
// AIAssist.getInstance(mContext).speakTTSVoice(
|
||||
// "${SkinResources.getInstance().getString(R.string.operation_platform_name)}提醒您及时减速,避免路口急刹")
|
||||
// isPrompted = true
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// //车辆行驶中,若判断当前红灯自车基于当前速度需降低60%以上才可通过时,提示“蘑菇提醒您及时减速,避免路口急刹”
|
||||
// if(light.state ==FusionTrafficLightOuterClass.FusionLightState.STATE_RED_FUSION){
|
||||
// CallerMapRoadListenerManager.getStopLineDistance()?.let{distance->
|
||||
// if(currentSpeed*0.4*light.duration > distance){
|
||||
// //语音播放:蘑菇提醒您及时减速,避免路口急刹
|
||||
// AIAssist.getInstance(mContext).speakTTSVoice(
|
||||
// "${SkinResources.getInstance().getString(R.string.operation_platform_name)}提醒您及时减速,避免路口急刹")
|
||||
// isPrompted = true
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user