Merge remote-tracking branch 'origin/master' into develop

pull/445/head
jackun 3 years ago
commit 53cca5e723
No known key found for this signature in database
GPG Key ID: 119DB3F1D05A9ED3

@ -204,6 +204,8 @@ Example: `MANGOHUD_CONFIG=cpu_temp,gpu_temp,position=top-right,height=500,font_s
Because comma is also used as option delimiter and needs to be escaped for values with a backslash, you can use `+` like `MANGOHUD_CONFIG=fps_limit=60+30+0` instead.
Note: Width and Height are set automatically based on the font_size, but can be overridden.
Note: RAPL is currently used for Intel CPUs to show power draw with `cpu_power` which may be unreadable for non-root users due to [vulnerability](https://platypusattack.com/). The corresponding `energy_uj` file has to be readable by corresponding user, e.g. by running `chmod o+r /sys/class/powercap/intel-rapl\:0/energy_uj` as root, else the power shown will be *0 W*, though having the file readable may potentially be a security vulnerability persisting until system reboots.
## Vsync
### OpenGL Vsync
- `-1` = Adaptive sync

@ -5,13 +5,13 @@
################ PERFORMANCE #################
### Limit the application FPS. Comma-separated list of one or more FPS values (e.g. 0,30,60). 0 means unlimited (unless v-synced).
### Limit the application FPS. Comma-separated list of one or more FPS values (e.g. 0,30,60). 0 means unlimited (unless VSynced).
# fps_limit=
### VSYNC [0-3] 0 = adaptive; 1 = off; 2 = mailbox; 3 = on
### VSync [0-3] 0 = adaptive; 1 = off; 2 = mailbox; 3 = on
# vsync=
### OpenGL VSYNC [0-N] 0 = off; >=1 = wait for N v-blanks, N > 1 acts as a fps limiter (fps = display refresh rate / N)
### OpenGL VSync [0-N] 0 = off; >=1 = wait for N v-blanks, N > 1 acts as a FPS limiter (FPS = display refresh rate / N)
# gl_vsync=
################### VISUAL ###################
@ -19,8 +19,8 @@
### Custom text centered useful for a header
# custom_text_center =
### Legacy Layout
legacy_layout
### Legacy layout
# legacy_layout = false
### Display the current CPU information
cpu_stats
@ -47,6 +47,7 @@ gpu_stats
### Display FPS and frametime
fps
# fps_sampling_period=
frametime
### Display loaded MangoHud architecture
@ -71,7 +72,7 @@ frame_timing
### Time formatting examples
# time_format = %H:%M
# time_format = [ %T %F ]
# time_format = %X # locally formatted time, because of limited glyph range, missing characters may show as '?' (e.g. japanese)
# time_format = %X # locally formatted time, because of limited glyph range, missing characters may show as '?' (e.g. Japanese)
### Change the hud font size (default is 24)
font_size=24
@ -109,10 +110,12 @@ position=top-left
# swap
# vram
### Display Wine version
### Display MangoHud, engine or Wine version
# version
# engine_version
# wine
### Disable / hide the hud by deafult
### Disable / hide the hud by default
# no_display
### Hud position offset
@ -152,25 +155,25 @@ background_alpha=0.5
# pci_dev = 0:0a:0.0
### Blacklist
#blacklist =
# blacklist =
################## INTERACTION #################
### Change toggle keybinds for the hud & logging
#toggle_hud=Shift_R+F12
#toggle_fps_limit=Shift_L+F1
#toggle_logging=Shift_L+F2
#reload_cfg=Shift_L+F4
#upload_log=Shift_L+F3
# toggle_hud=Shift_R+F12
# toggle_fps_limit=Shift_L+F1
# toggle_logging=Shift_L+F2
# reload_cfg=Shift_L+F4
# upload_log=Shift_L+F3
################## LOG #################
### Automatically start the log after X seconds
# autostart_log = 1
### Set amount of time in second that the logging will run for
### Set amount of time in seconds that the logging will run for
# log_duration
### Set location of the output files (Required for logging)
### Set location of the output files (required for logging)
# output_folder = /home/<USERNAME>/mangologs
### Permit uploading logs directly to Flightlessmango.com
### Permit uploading logs directly to FlightlessMango.com
# permit_upload=1
### Define a '+'-separated list of percentiles shown in the benchmark results.
### Use "AVG" to get a mean average. Default percentiles are 97+AVG+1+0.1

@ -19,7 +19,7 @@ if [ "$MANGOHUD_DLSYM" = "1" ]; then
MANGOHUD_LIB_NAME="@ld_libdir_mangohud_abs@libMangoHud_dlsym.so:${MANGOHUD_LIB_NAME}"
fi
# Preload using the plain filesnames of the libs, the dynamic linker will
# Preload using the plain filenames of the libs, the dynamic linker will
# figure out whether the 32 or 64 bit version should be used, and will search
# for it in the correct directory
LD_PRELOAD="${LD_PRELOAD}:${MANGOHUD_LIB_NAME}"

@ -14,7 +14,7 @@ if [ "$#" -eq 0 ]; then
fi
# Execute the program under a clean environment
# pass through the overriden LD_PRELOAD environment variables
# pass through the overridden LD_PRELOAD environment variables
LD_PRELOAD="${LD_PRELOAD}:${MANGOHUD_LIB_NAME}"
exec env MANGOHUD=1 LD_PRELOAD="${LD_PRELOAD}" "$@"

@ -15,7 +15,7 @@ if [ "$#" -eq 0 ]; then
fi
# Execute the program under a clean environment
# pass through the overriden LD_PRELOAD environment variables
# pass through the overridden LD_PRELOAD environment variables
LD_PRELOAD="${LD_PRELOAD}:${MANGOHUD_LIB_NAME}"
LD_LIBRARY_PATH="${XDG_DATA_HOME}/MangoHud"

@ -78,7 +78,7 @@ dependencies() {
if [[ $(pip3 show meson; echo $?) == 1 || $(pip3 show mako; echo $?) == 1 ]]; then
$SU_CMD pip3 install 'meson>=0.54' mako
fi
if [[ ! -f /usr/local/bin/glslangValidator ]]; then
if ! which glslangValidator >/dev/null; then
wget https://github.com/KhronosGroup/glslang/releases/download/SDK-candidate-26-Jul-2020/glslang-master-linux-Release.zip
unzip glslang-master-linux-Release.zip bin/glslangValidator
$SU_CMD install -m755 bin/glslangValidator /usr/local/bin/

@ -7,7 +7,7 @@ project('MangoHud',
cc = meson.get_compiler('c')
cpp = meson.get_compiler('cpp')
prog_python = import('python').find_installation('python3')
prog_python = import('python').find_installation('python3', modules: ['mako'])
null_dep = dependency('', required : false)
mangohud_version = vcs_tag(

@ -407,7 +407,7 @@ parse_font_glyph_ranges(const char *str)
static bool
parse_help(const char *str)
{
fprintf(stderr, "Layer params using VK_LAYER_MESA_OVERLAY_CONFIG=\n");
fprintf(stderr, "Layer params using MANGOHUD_CONFIG=\n");
#define OVERLAY_PARAM_BOOL(name) \
fprintf(stderr, "\t%s=0|1\n", #name);
#define OVERLAY_PARAM_CUSTOM(name)
@ -461,7 +461,7 @@ parse_string(const char *s, char *out_param, char *out_value)
}
if (*s && !i) {
fprintf(stderr, "mesa-overlay: syntax error: unexpected '%c' (%i) while "
fprintf(stderr, "MANGOHUD: syntax error: unexpected '%c' (%i) while "
"parsing a string\n", *s, *s);
fflush(stderr);
}

@ -615,11 +615,11 @@ void init_system_info(){
const char* mangohud_recursion = getenv("MANGOHUD_RECURSION");
if (!mangohud_recursion) {
setenv("MANGOHUD_RECURSION", "1", 1);
driver = exec("glxinfo -B | grep 'OpenGL version' | sed 's/^.*: //' | cut -d' ' --output-delimiter=$'\n' -f1- | grep -v '(' | grep -v ')' | tr '\n' ' ' | cut -c 1-");
driver = exec("glxinfo -B | grep 'OpenGL version' | sed 's/^.*: //' | sed 's/([^()]*)//g' | tr -s ' '");
trim(driver);
unsetenv("MANGOHUD_RECURSION");
} else {
driver = "MangoHud glxinfo recurssion detected";
driver = "MangoHud glxinfo recursion detected";
}
// Get WINE version

Loading…
Cancel
Save