|
|
|
@ -26,7 +26,6 @@ static int plot_grab_y = -1;
|
|
|
|
|
static int plot_pos_y;
|
|
|
|
|
|
|
|
|
|
// how many columns for runtime?
|
|
|
|
|
static const int NSLEN = 9;
|
|
|
|
|
static const int HUD_ROWS = 3 + 2; // 2 for borders
|
|
|
|
|
static const int HUD_COLS = 30 + 2; // 2 for borders
|
|
|
|
|
|
|
|
|
@ -308,14 +307,13 @@ hud_print_finished(int* line){
|
|
|
|
|
if(ncplane_printf_yx(hud, *line, 1, "%d", e->frames) < 0){
|
|
|
|
|
return NULL;
|
|
|
|
|
}
|
|
|
|
|
if(ncplane_printf_yx(hud, *line, 7, "%*ju.%02jus",
|
|
|
|
|
NSLEN - 3, e->totalns / GIG,
|
|
|
|
|
if(ncplane_printf_yx(hud, *line, 7, "%ju.%02jus", e->totalns / GIG,
|
|
|
|
|
(e->totalns % GIG) / (GIG / 100)) < 0){
|
|
|
|
|
return NULL;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
if(ncplane_putstr_yx(hud, *line, 18, e->name) < 0){
|
|
|
|
|
return -1;
|
|
|
|
|
return NULL;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
++*line;
|
|
|
|
|
e = e->next;
|
|
|
|
@ -453,8 +451,7 @@ int hud_schedule(const char* demoname){
|
|
|
|
|
if(ncplane_printf_yx(hud, line, 1, "%d", cure->frames) < 0){
|
|
|
|
|
return -1;
|
|
|
|
|
}
|
|
|
|
|
if(ncplane_printf_yx(hud, line, 7, "%*ju.%02jus",
|
|
|
|
|
NSLEN - 3, cure->totalns / GIG,
|
|
|
|
|
if(ncplane_printf_yx(hud, line, 7, "%ju.%02jus", cure->totalns / GIG,
|
|
|
|
|
(cure->totalns % GIG) / (GIG / 100)) < 0){
|
|
|
|
|
return -1;
|
|
|
|
|
}
|
|
|
|
@ -545,8 +542,8 @@ int demo_render(struct notcurses* nc){
|
|
|
|
|
if(ncplane_printf_yx(hud, HUD_ROWS - 2, 1, "%d", running->frames) < 0){
|
|
|
|
|
return -1;
|
|
|
|
|
}
|
|
|
|
|
if(ncplane_printf_yx(hud, HUD_ROWS - 2, 7, "%*ju.%02jus",
|
|
|
|
|
NSLEN - 3, ns / GIG, (ns % GIG) / (GIG / 100)) < 0){
|
|
|
|
|
if(ncplane_printf_yx(hud, HUD_ROWS - 2, 7, "%ju.%02jus",
|
|
|
|
|
ns / GIG, (ns % GIG) / (GIG / 100)) < 0){
|
|
|
|
|
return -1;
|
|
|
|
|
}
|
|
|
|
|
if(ncplane_putstr_yx(hud, HUD_ROWS - 2, 18, running->name) < 0){
|
|
|
|
|