Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,7 @@ Parameters that are enabled by default have to be explicitly disabled. These (cu
| `cpu_load_color` | Set the colors for the gpu load change low, medium and high. e.g `cpu_load_color=0000FF,00FFFF,FF00FF` |
| `cpu_load_value` | Set the values for medium and high load e.g `cpu_load_value=50,90` |
| `cpu_mhz` | Show the CPUs current MHz |
| `cpu_no_label` | Remove the label before cpu_stats |
| `cpu_power`<br>`gpu_power` | Display CPU/GPU draw in watts |
| `cpu_temp`<br>`gpu_temp`<br>`gpu_junction_temp`<br>`gpu_mem_temp` | Display current CPU/GPU temperature |
| `cpu_text`<br>`gpu_text` | Override CPU and GPU text. `gpu_text` is a list in case of multiple GPUs |
Expand Down Expand Up @@ -386,6 +387,7 @@ Parameters that are enabled by default have to be explicitly disabled. These (cu
| `fps_color=` | Choose the colors that the fps changes to when `fps_color_change` is enabled. Corresponds with fps_value. Default is `b22222,fdfd09,39f900` |
| `fps_limit_method` | If FPS limiter should wait before or after presenting a frame. Choose `late` (default) for the lowest latency or `early` for the smoothest frametimes |
| `fps_limit` | Limit the apps framerate. Comma-separated list of one or more FPS values. `0` means unlimited |
| `fps_no_label` | Remove the label before fps |
| `fps_only` | Show FPS only. ***Not meant to be used with other display params*** |
| `fps_sampling_period=` | Time interval between two sampling points for gathering the FPS in milliseconds. Default is `500` |
| `fps_value` | Choose the break points where `fps_color_change` changes colors between. E.g `60,144`, default is `30,60` |
Expand All @@ -395,6 +397,7 @@ Parameters that are enabled by default have to be explicitly disabled. These (cu
| `frame_count` | Display frame count |
| `frametime` | Display frametime next to FPS text |
| `frame_timing_detailed` | Display frame timing in a more detailed chart |
| `gpu_no_label` | Remove the label before gpu_stats |
| `fsr` | Display the status of FSR (only works in gamescope) |
| `hdr` | Display the status of HDR (only works in gamescope) |
| `refresh_rate` | Display the current refresh rate (only works in gamescope) |
Expand Down
3 changes: 3 additions & 0 deletions data/MangoHud.conf
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ gpu_stats
# gpu_power
# gpu_power_limit
# gpu_text=
# gpu_no_label # works best in horizontal mode, in conjunction with the other no_label options
# gpu_load_change
# gpu_load_value=60,90
# gpu_load_color=39F900,FDFD09,B22222
Expand All @@ -101,6 +102,7 @@ cpu_stats
# cpu_temp
# cpu_power
# cpu_text=
# cpu_no_label # works best in horizontal mode, in conjunction with the other no_label options
# cpu_mhz
# cpu_load_change
# cpu_load_value=60,90
Expand Down Expand Up @@ -144,6 +146,7 @@ fps
# fps_value=30,60
# fps_color=B22222,FDFD09,39F900
# fps_text=""
# fps_no_label # works best in horizontal mode, in conjunction with the other no_label options
frametime
# frame_count
## fps_metrics takes a list of decimal values or the value avg
Expand Down
21 changes: 15 additions & 6 deletions src/hud_elements.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -283,9 +283,12 @@ void HudElements::gpu_stats(){
if (HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_gpu_stats] && gpus){
for (auto& gpu : gpus->selected_gpus()) {
ImguiNextColumnFirstItem();
HUDElements.TextColored(HUDElements.colors.gpu, "%s", gpu->gpu_text().c_str());
if (!HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_gpu_no_label])
HUDElements.TextColored(HUDElements.colors.gpu, "%s", gpu->gpu_text().c_str());
// advance only if we showed the label
if (!HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_gpu_no_label])
ImguiNextColumnOrNewRow();

ImguiNextColumnOrNewRow();
auto text_color = HUDElements.colors.text;
if (HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_gpu_load_change]){
struct LOAD_DATA gpu_data = {
Expand Down Expand Up @@ -426,8 +429,11 @@ void HudElements::cpu_stats(){
else
cpu_text = HUDElements.params->cpu_text.c_str();

HUDElements.TextColored(HUDElements.colors.cpu, "%s", cpu_text);
ImguiNextColumnOrNewRow();
if (!HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_cpu_no_label])
HUDElements.TextColored(HUDElements.colors.cpu, "%s", cpu_text);
// advance only if we showed the label
if (!HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_gpu_no_label])
ImguiNextColumnOrNewRow();
auto text_color = HUDElements.colors.text;
if (HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_cpu_load_change]){
int cpu_load_percent = int(cpuStats.GetCPUDataTotal().percent);
Expand Down Expand Up @@ -811,9 +817,12 @@ void HudElements::procmem()
void HudElements::fps(){
if (HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_fps] && !HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_fps_only]){
ImguiNextColumnFirstItem();
HUDElements.TextColored(HUDElements.colors.engine, "%s", engine_name(*HUDElements.sw_stats));
if (!HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_fps_no_label])
HUDElements.TextColored(HUDElements.colors.engine, "%s", engine_name(*HUDElements.sw_stats));
// advance only if we showed the label
if (!HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_fps_no_label])
ImguiNextColumnOrNewRow();

ImguiNextColumnOrNewRow();
if (HUDElements.params->enabled[OVERLAY_PARAM_ENABLED_fps_color_change]){
int fps = int(HUDElements.sw_stats->fps);
struct LOAD_DATA fps_data = {
Expand Down
3 changes: 3 additions & 0 deletions src/overlay_params.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -715,6 +715,9 @@ set_parameters_from_options(struct overlay_params *params)
params->enabled[OVERLAY_PARAM_ENABLED_core_bars] = false;
params->enabled[OVERLAY_PARAM_ENABLED_read_cfg] = read_cfg;
params->enabled[OVERLAY_PARAM_ENABLED_time_no_label] = false;
params->enabled[OVERLAY_PARAM_ENABLED_cpu_no_label] = false;
params->enabled[OVERLAY_PARAM_ENABLED_gpu_no_label] = false;
params->enabled[OVERLAY_PARAM_ENABLED_fps_no_label] = false;
params->enabled[OVERLAY_PARAM_ENABLED_core_type] = false;
params->options.erase("full");
}
Expand Down
3 changes: 3 additions & 0 deletions src/overlay_params.h
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,9 @@ struct Tracepoint;
OVERLAY_PARAM_BOOL(winesync) \
OVERLAY_PARAM_BOOL(present_mode) \
OVERLAY_PARAM_BOOL(time_no_label) \
OVERLAY_PARAM_BOOL(cpu_no_label) \
OVERLAY_PARAM_BOOL(gpu_no_label) \
OVERLAY_PARAM_BOOL(fps_no_label) \
OVERLAY_PARAM_BOOL(display_server) \
OVERLAY_PARAM_BOOL(cpu_efficiency) \
OVERLAY_PARAM_BOOL(gpu_efficiency) \
Expand Down