Visuals - Model UI - Lane Lines
Adjust the visual thickness of lane lines on your display. Default matches the MUTCD average of 4 inches.
This commit is contained in:
parent
374ef6d465
commit
39907b3408
@ -99,7 +99,7 @@ void update_model(UIState *s,
|
|||||||
int max_idx = get_path_length_idx(lane_lines[0], max_distance);
|
int max_idx = get_path_length_idx(lane_lines[0], max_distance);
|
||||||
for (int i = 0; i < std::size(scene.lane_line_vertices); i++) {
|
for (int i = 0; i < std::size(scene.lane_line_vertices); i++) {
|
||||||
scene.lane_line_probs[i] = lane_line_probs[i];
|
scene.lane_line_probs[i] = lane_line_probs[i];
|
||||||
update_line_data(s, lane_lines[i], 0.025 * scene.lane_line_probs[i], 0, &scene.lane_line_vertices[i], max_idx);
|
update_line_data(s, lane_lines[i], (scene.model_ui ? scene.lane_line_width : 0.025) * scene.lane_line_probs[i], 0, &scene.lane_line_vertices[i], max_idx);
|
||||||
}
|
}
|
||||||
|
|
||||||
// update road edges
|
// update road edges
|
||||||
@ -383,6 +383,7 @@ void ui_update_frogpilot_params(UIState *s) {
|
|||||||
scene.model_ui = params.getBool("ModelUI");
|
scene.model_ui = params.getBool("ModelUI");
|
||||||
scene.dynamic_path_width = scene.model_ui && params.getBool("DynamicPathWidth");
|
scene.dynamic_path_width = scene.model_ui && params.getBool("DynamicPathWidth");
|
||||||
scene.hide_lead_marker = scene.model_ui && params.getBool("HideLeadMarker");
|
scene.hide_lead_marker = scene.model_ui && params.getBool("HideLeadMarker");
|
||||||
|
scene.lane_line_width = params.getInt("LaneLinesWidth") * (scene.is_metric ? 1.0f : INCH_TO_CM) / 200.0f;
|
||||||
|
|
||||||
bool quality_of_life_controls = params.getBool("QOLControls");
|
bool quality_of_life_controls = params.getBool("QOLControls");
|
||||||
scene.reverse_cruise = quality_of_life_controls && params.getBool("ReverseCruise");
|
scene.reverse_cruise = quality_of_life_controls && params.getBool("ReverseCruise");
|
||||||
|
@ -260,6 +260,7 @@ typedef struct UIScene {
|
|||||||
float adjusted_cruise;
|
float adjusted_cruise;
|
||||||
float friction;
|
float friction;
|
||||||
float lane_detection_width;
|
float lane_detection_width;
|
||||||
|
float lane_line_width;
|
||||||
float lane_width_left;
|
float lane_width_left;
|
||||||
float lane_width_right;
|
float lane_width_right;
|
||||||
float lat_accel;
|
float lat_accel;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user