|
|
|
@ -82,6 +82,12 @@ parse_background_alpha(const char *str)
|
|
|
|
|
return strtof(str, NULL);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
static float
|
|
|
|
|
parse_frametime_alpha(const char *str)
|
|
|
|
|
{
|
|
|
|
|
return strtof(str, NULL);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
static KeySym
|
|
|
|
|
parse_toggle_hud(const char *str)
|
|
|
|
|
{
|
|
|
|
@ -303,6 +309,7 @@ parse_overlay_config(struct overlay_params *params,
|
|
|
|
|
params->offset_x = 0;
|
|
|
|
|
params->offset_y = 0;
|
|
|
|
|
params->background_alpha = 0.5;
|
|
|
|
|
params->frametime_alpha = 1.0;
|
|
|
|
|
params->time_format = "%T";
|
|
|
|
|
params->gpu_color = strtol("2e9762", NULL, 16);
|
|
|
|
|
params->cpu_color = strtol("2e97cb", NULL, 16);
|
|
|
|
@ -359,7 +366,7 @@ parse_overlay_config(struct overlay_params *params,
|
|
|
|
|
// Command buffer gets reused and timestamps cause hangs for some reason, force off for now
|
|
|
|
|
params->enabled[OVERLAY_PARAM_ENABLED_gpu_timing] = false;
|
|
|
|
|
// Convert from 0xRRGGBB to ImGui's format
|
|
|
|
|
std::array<unsigned *, 8> colors = {
|
|
|
|
|
std::array<unsigned *, 7> colors = {
|
|
|
|
|
¶ms->crosshair_color,
|
|
|
|
|
¶ms->cpu_color,
|
|
|
|
|
¶ms->gpu_color,
|
|
|
|
@ -367,16 +374,21 @@ parse_overlay_config(struct overlay_params *params,
|
|
|
|
|
¶ms->ram_color,
|
|
|
|
|
¶ms->engine_color,
|
|
|
|
|
¶ms->io_color,
|
|
|
|
|
¶ms->frametime_color
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
for (auto color : colors){
|
|
|
|
|
*color =
|
|
|
|
|
IM_COL32(RGBGetRValue(*color),
|
|
|
|
|
*color =
|
|
|
|
|
IM_COL32(RGBGetRValue(*color),
|
|
|
|
|
RGBGetGValue(*color),
|
|
|
|
|
RGBGetBValue(*color),
|
|
|
|
|
255);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
params->frametime_color =
|
|
|
|
|
IM_COL32(RGBGetRValue(params->frametime_color),
|
|
|
|
|
RGBGetGValue(params->frametime_color),
|
|
|
|
|
RGBGetBValue(params->frametime_color),
|
|
|
|
|
params->frametime_alpha * 255);
|
|
|
|
|
|
|
|
|
|
params->tableCols = 3;
|
|
|
|
|
|
|
|
|
@ -385,6 +397,7 @@ parse_overlay_config(struct overlay_params *params,
|
|
|
|
|
} else {
|
|
|
|
|
params->width = params->font_size * 11.7;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//increase hud width if io read and write
|
|
|
|
|
if (params->enabled[OVERLAY_PARAM_ENABLED_io_read] && params->enabled[OVERLAY_PARAM_ENABLED_io_write] && params->width == 280)
|
|
|
|
|
params->width = 15 * params->font_size;
|
|
|
|
|