回放
This commit is contained in:
parent
ea23209348
commit
b1cb459bd9
@ -219,8 +219,8 @@ static inline void fill_rect(NVGcontext* vg, const Rect1& r, const NVGcolor* col
|
||||
if (stroke_width > 0) {
|
||||
nvgStrokeWidth(vg, stroke_width);
|
||||
if (stroke_color) nvgStrokeColor(vg, *stroke_color);
|
||||
else nvgStrokeColor(vg, nvgRGB(0, 0, 0));
|
||||
nvgStroke(vg);
|
||||
else nvgStrokeColor(vg, nvgRGB(0, 0, 0));
|
||||
nvgStroke(vg);
|
||||
}
|
||||
}
|
||||
|
||||
@ -696,11 +696,11 @@ public:
|
||||
else if (longActive) {
|
||||
if (xState == 3 || xState == 5) { //XState.e2eStop, XState.e2eStopped
|
||||
if (v_ego < 1.0) {
|
||||
sprintf(str, "%s", (trafficState >= 1000) ? "信号错误" : "信号等待");
|
||||
sprintf(str, "%s", (trafficState >= 1000) ? "신호오류" : "신호대기");
|
||||
ui_draw_text(s, x, disp_y, str, disp_size, COLOR_WHITE, BOLD);
|
||||
}
|
||||
else {
|
||||
ui_draw_text(s, x, disp_y, "信号减速中", disp_size, COLOR_WHITE, BOLD);
|
||||
ui_draw_text(s, x, disp_y, "신호감속중", disp_size, COLOR_WHITE, BOLD);
|
||||
}
|
||||
#if 0
|
||||
else if (getStopDist() > 0.5) {
|
||||
@ -712,7 +712,7 @@ public:
|
||||
#endif
|
||||
}
|
||||
else if (xState == 4) { //XState.e2ePrepare
|
||||
ui_draw_text(s, x, disp_y, "E2E模式", disp_size, COLOR_WHITE, BOLD);
|
||||
ui_draw_text(s, x, disp_y, "E2E주행중", disp_size, COLOR_WHITE, BOLD);
|
||||
}
|
||||
else if (xState == 0 || xState == 1 || xState == 2) { //XState.lead
|
||||
draw_dist = true;
|
||||
@ -1028,17 +1028,17 @@ protected:
|
||||
ui_draw_text(s, bx, by + 25 * scale - 6 * (1 - scale), str, 60 * scale, COLOR_BLACK, BOLD, 0.0f, 0.0f);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
int drawTurnInfoHud(const UIState* s) {
|
||||
if (s->fb_w < 1200) return -1;
|
||||
#ifdef __UI_TEST
|
||||
active_carrot = 2;
|
||||
nGoPosDist = 500000;
|
||||
nGoPosTime = 4 * 60 * 60;
|
||||
szSdiDescr = "儿童保护区域(学校区域起始路段)";
|
||||
szSdiDescr = "어린이 보호구역(스쿨존 시작 구간)";
|
||||
xTurnInfo = 1;
|
||||
xDistToTurn = 1000;
|
||||
szPosRoadName = "九文川1街17号";
|
||||
szPosRoadName = "구문천 1길 17";
|
||||
#endif
|
||||
|
||||
//if (active_carrot <= 1) return;
|
||||
@ -1080,9 +1080,9 @@ protected:
|
||||
case 4: ui_draw_image(s, { bx - icon_size / 2, by - icon_size / 2, icon_size, icon_size }, "ic_lane_change_r", 1.0f); break;
|
||||
case 7: ui_draw_image(s, { bx - icon_size / 2, by - icon_size / 2, icon_size, icon_size }, "ic_turn_u", 1.0f); break;
|
||||
case 6: ui_draw_text(s, bx, by + 20, "TG", 35, COLOR_WHITE, BOLD); break;
|
||||
case 8: ui_draw_text(s, bx, by + 20, "目的地", 35, COLOR_WHITE, BOLD); break;
|
||||
case 8: ui_draw_text(s, bx, by + 20, "목적지", 35, COLOR_WHITE, BOLD); break;
|
||||
default:
|
||||
sprintf(str, "减速:%d", xTurnInfo);
|
||||
sprintf(str, "감속:%d", xTurnInfo);
|
||||
ui_draw_text(s, bx, by + 20, str, 35, COLOR_WHITE, BOLD);
|
||||
break;
|
||||
}
|
||||
@ -1111,7 +1111,7 @@ protected:
|
||||
int remaining_minutes = (int)nGoPosTime / 60;
|
||||
local->tm_min += remaining_minutes;
|
||||
mktime(local);
|
||||
sprintf(str, "到达: %.1f分(%02d:%02d)", (float)nGoPosTime / 60., local->tm_hour, local->tm_min);
|
||||
sprintf(str, "도착: %.1f분(%02d:%02d)", (float)nGoPosTime / 60., local->tm_hour, local->tm_min);
|
||||
ui_draw_text(s, tbt_x + 190, tbt_y + 80, str, 50, COLOR_WHITE, BOLD);
|
||||
sprintf(str, "%.1fkm", nGoPosDist / 1000.);
|
||||
ui_draw_text(s, tbt_x + 190 + 120, tbt_y + 130, str, 50, COLOR_WHITE, BOLD);
|
||||
@ -1127,7 +1127,7 @@ public:
|
||||
return -1;
|
||||
}
|
||||
const auto carrot_man = sm["carrotMan"].getCarrotMan();
|
||||
|
||||
|
||||
active_carrot = carrot_man.getActiveCarrot();
|
||||
|
||||
if (active_carrot > 1) {
|
||||
@ -1151,7 +1151,7 @@ public:
|
||||
szSdiDescr = QString::fromStdString(carrot_man.getSzSdiDescr());
|
||||
szPosRoadName = QString::fromStdString(carrot_man.getSzPosRoadName());
|
||||
szTBTMainText = QString::fromStdString(carrot_man.getSzTBTMainText());
|
||||
|
||||
|
||||
}
|
||||
else {
|
||||
//xTurnInfo = -1;
|
||||
@ -1930,7 +1930,7 @@ public:
|
||||
int max_z = lane_lines[2].getZ().size();
|
||||
float z_offset = 0.0;
|
||||
foreach(const QString & pair, pairs) {
|
||||
QStringList xy = pair.split(","); // ","로 x와 y 구분
|
||||
QStringList xy = pair.split(","); // ","로 x와 y 구분
|
||||
if (xy.size() == 3) {
|
||||
//printf("coords = x: %.1f, y: %.1f, d:%.1f\n", xy[0].toFloat(), xy[1].toFloat(), xy[2].toFloat());
|
||||
float x = xy[0].toFloat();
|
||||
@ -2114,7 +2114,7 @@ public:
|
||||
void drawHud(UIState* s) {
|
||||
int show_device_state = params.getInt("ShowDeviceState");
|
||||
blink_timer = (blink_timer + 1) % 16;
|
||||
disp_timer = (disp_timer + 1) % 64;
|
||||
disp_timer = (disp_timer + 1) % 64;
|
||||
nvgTextAlign(s->vg, NVG_ALIGN_CENTER | NVG_ALIGN_BOTTOM);
|
||||
|
||||
int x = 140;// 120;
|
||||
@ -2195,7 +2195,7 @@ public:
|
||||
const SubMaster& sm = *(s->sm);
|
||||
|
||||
// draw gap info
|
||||
char driving_mode_str[32] = "经济";
|
||||
char driving_mode_str[32] = "연비";
|
||||
int driving_mode = myDrivingMode;// params.getInt("MyDrivingMode");
|
||||
NVGcolor mode_color = COLOR_GREEN_ALPHA(210);
|
||||
NVGcolor text_color = COLOR_WHITE;
|
||||
@ -2365,7 +2365,7 @@ public:
|
||||
}
|
||||
if (show_datetime == 1 || show_datetime == 3) {
|
||||
//strftime(str, sizeof(str), "%m-%d-%a", local);
|
||||
const char* weekdays_ko[] = { "日", "一", "二", "三", "四", "五", "六" };
|
||||
const char* weekdays_ko[] = { "일", "월", "화", "수", "목", "금", "토" };
|
||||
strftime(str, sizeof(str), "%m-%d", local); // 날짜만 가져옴
|
||||
int weekday_index = local->tm_wday; // tm_wday: 0=일, 1=월, ..., 6=토
|
||||
snprintf(str + strlen(str), sizeof(str) - strlen(str), "(%s)", weekdays_ko[weekday_index]);
|
||||
@ -2663,7 +2663,7 @@ void ui_draw(UIState *s, ModelRenderer* model_renderer, int w, int h) {
|
||||
int path_x = drawPathEnd.getPathX();
|
||||
int path_y = drawPathEnd.getPathY();
|
||||
drawDesire.draw(s, path_x, path_y - 135);
|
||||
|
||||
|
||||
|
||||
drawPlot.draw(s);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user