forked from IQ.Lvbs/IQ.Pilot
IQ.Pilot Release Commit @ ba009d5
This commit is contained in:
@@ -14,6 +14,7 @@ from iqpilot.selfdrive.ui.mici.onroad import blend_colors
|
||||
from iqpilot.system.ui.lib.application import gui_app
|
||||
from iqpilot.system.ui.lib.shader_polygon import draw_polygon, Gradient
|
||||
from iqpilot.system.ui.widgets import Widget
|
||||
from iqpilot.ui.theme import NeonTheme
|
||||
|
||||
CLIP_MARGIN = 500
|
||||
MIN_DRAW_DISTANCE = 10.0
|
||||
@@ -297,7 +298,10 @@ class ModelRenderer(Widget):
|
||||
def _get_ll_color(self, prob: float, adjacent: bool, left: bool):
|
||||
alpha = np.clip(prob, 0.0, 0.7)
|
||||
if adjacent:
|
||||
_base_color = LANE_LINE_COLORS.get(ui_state.status, LANE_LINE_COLORS[UIStatus.DISENGAGED])
|
||||
if gui_app.iqpilot_ui() and ui_state.status == UIStatus.ENGAGED:
|
||||
_base_color = NeonTheme.glow()
|
||||
else:
|
||||
_base_color = LANE_LINE_COLORS.get(ui_state.status, LANE_LINE_COLORS[UIStatus.DISENGAGED])
|
||||
color = rl.Color(_base_color.r, _base_color.g, _base_color.b, int(alpha * 255))
|
||||
|
||||
# turn adjacent lls orange if torque is high
|
||||
|
||||
Reference in New Issue
Block a user