Commit Graph

954 Commits (abbe5233ee07b4caf55fa4fc7b9f49a08d250bdc)

Author SHA1 Message Date
FlightlessMango 5d3c0ff686 mangoapp: make sure logger is inited 2 years ago
FlightlessMango d5c409beed mangoapp: temporarily remove vram mhz 2 years ago
FlightlessMango 37e18279e7 mangoapp: use amdgpu metrics 2 years ago
FlightlessMango 498687c33d mangoapp: let gamescope decide when to send updates 3 years ago
FlightlessMango f7dffb03a1 mangoapp: bump width 3 years ago
FlightlessMango 77e4d51d87 calculate and show mins in benchmark 3 years ago
FlightlessMango 3366120364 Move calc benchmark into logger 3 years ago
FlightlessMango 7071900a79 Disable fps_only when using full param 3 years ago
FlightlessMango 496fa0babc mangoapp: shutdown and reinit based on no_display 3 years ago
FlightlessMango 6c0965c27b Write a log summary 3 years ago
FlightlessMango a1b7b55a54 Use hudelements params in logging 3 years ago
FlightlessMango 92151565fc mangoapp: disable some options 3 years ago
flightlessmango 01cdc6cdc2
Merge pull request #664 from Joshua-Ashton/gamescope-external
mangoapp: Use GAMESCOPE_EXTERNAL_OVERLAY
3 years ago
FlightlessMango 941d5e6977 mangoapp: close if no_display 3 years ago
FlightlessMango b0fc3d348a mangoapp: notifier 3 years ago
FlightlessMango 4cd2ba539f mangoapp: cleaning up 3 years ago
jackun 4a33838bcd
Add extra parentheses to make compiler happy 3 years ago
Joshua Ashton 80042e00a3 mangoapp: Rename to "mangoapp overlay window" 3 years ago
Joshua Ashton 0be5e9a72f mangoapp: Use GAMESCOPE_EXTERNAL_OVERLAY
Don't replace the STEAM_OVERLAY
3 years ago
Alessandro Toia 4f02e20205 Blacklist: add EADesktop.exe and EALauncher.exe 3 years ago
Alessandro Toia 6717ad9ecf Remove the FPS text from fps_only param 3 years ago
Alessandro Toia 15fc641fc3 Add fps_only param to disable showing the engine name 3 years ago
FlightlessMango 9758d2a286 Try to get correct amd gpu when multiple 3 years ago
FlightlessMango e7c59c55a2 Rewrite reading core mhz files 3 years ago
Constantine a04230ad29 Set VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT when creating swapchain
Fixes #582
3 years ago
FlightlessMango cfd802c063 Incorrect param used in calc benchmark 3 years ago
FlightlessMango aab8730f69 exec: make sure LD_PRELOAD is unset 3 years ago
FlightlessMango 7212c79feb Logging: push param to benchmark calc 3 years ago
Tatsuyuki Ishi ada173e67f overlay: avoid quadratic behavior
Using a vector with erase(begin()) results in a copy of the full array
every time. This is inefficient and in the case of HUD graphs, was having
quadratic complexity which can noticeably affect performance.

This patch replaces most of the operations with an O(1) alternative,
keeping the total cost under a linear bound. While on this, also refactor
the size of graph array into a constant.
3 years ago
FlightlessMango 337ecbc4cf use scaling_cur_freq for cpu core mhz 3 years ago
FlightlessMango ee7f3fbfd2 Mangoapp: frametime message queue 3 years ago
FlightlessMango 52ae70f650 read_line: return empty line if ifstream fails 3 years ago
FlightlessMango ac58c30bbc Use driverInfo for driver name/version instead 3 years ago
FlightlessMango e7de7b5b93 Get device name before system info 3 years ago
FlightlessMango 9434033083 Don't use read_line as it causes issue with splitgate 3 years ago
FlightlessMango f2dcf3f4b2 Rewrite of exec() 3 years ago
FlightlessMango 23ed317536 mangoapp: shm struct + gamescope engine 3 years ago
FlightlessMango fbda58c907 Some windows fixes 3 years ago
Stephan Lachnit 4983056600 fix regression in hw_info_updater
Calling std::unique_lock in update() will cause a delay if
update_hw_info() takes longer than the period when update() is called.
To fix this, a try_to_lock tag is added. update() will only update if
the lock is aquired, else the update call is skipped.

Signed-off-by: Stephan Lachnit <stephanlachnit@debian.org>
3 years ago
FlightlessMango 45be485a13 mangohud control 3 years ago
FlightlessMango 5fee3bc5e3 Change _params to pointer 3 years ago
FlightlessMango 872c3f03a4 Show highest cpu freq instead of cumulative 3 years ago
FlightlessMango da573e8eba mangoapp: fix not respecting nvctrl option 3 years ago
FlightlessMango cb3682633e Mangoapp: include unistd for sleep 3 years ago
FlightlessMango b001eb4714 Move _params init to overlay.cpp 3 years ago
FlightlessMango cd215854ce Mangoapp: meson option 3 years ago
Joshua Ashton fb619147e4 Set overlay atom to tell gamescope to render over 3 years ago
FlightlessMango 4e3a40c6ef mangoapp + gamescope shm 3 years ago
jackun a91f1c7cf7
Iterate through libraries for possible locations of dlopen/dlsym functions
glibc 2.34 moves `dlopen` and `dlsym` from libdl.so to libc.so
3 years ago
jackun abf146f73c
Set correct swapchain_stats etc references for hw updater 3 years ago
jackun 9b6a39dfe9
sed s/gnu_linux/linux/g 3 years ago
jackun 90e48f95ca
Use unversioned `fmt::format_error` 3 years ago
jackun 6584f23a6c
Use `ghc::filesystem` to iterate over /proc/self/map_files 3 years ago
jackun c452609718
Fix hw update thread waiting for initial update signal 3 years ago
jackun ced84ec526
Try to find `dlopen`/`dlsym` from libc.so too (musl libc, glibc 2.34+) 3 years ago
FlightlessMango 947f287a5e
Only create hw_info_thread once 3 years ago
jackun 729ccc83bd
Use spdlog's 'fmt' to format media player metadata
Usage:
  media_player_format={title};{artist};{album}

Semi-colon breaks to new line, might change.
3 years ago
FlightlessMango 3ac7772a55 Add universal param 3 years ago
jackun ac11beef9b
[dbus] Don't stop D-Bus thread or remove filter if not completely deiniting 3 years ago
jackun 31e879215a
[dbus] Also check if gamemode is enabled with D-Bus 3 years ago
jackun 7e3a56d356
[dbus] Raise TRAP if wrong primitive type but allow to continue 3 years ago
jackun d1617818cd
Fix OpenGL gpu_name 3 years ago
jackun a431c092eb
Separate libdrm and libdrm_amdgpu loader 3 years ago
jackun 822e325d11
Add get_basename, fix win32 build
std::string::substr likes to throw
3 years ago
jackun 9df9df0f4f
Fix some tangling printfs 3 years ago
jackun 94a7705554
Fix integer overflow on 32 bit, for `procmem` 3 years ago
jackun 5767426192
Nope, ERROR level has higher priority, doh 3 years ago
jackun c79e01830d
Clean up battery.{h,cpp} header includes 3 years ago
jackun 866fd8bc24
Add per process memory usage (`procmem` etc) 3 years ago
jackun 891abdf3b9
Skip setting up vulkan render if HUD is hidden 3 years ago
jackun b20d2492bc
Limit keybind check to about 10hz 3 years ago
jackun 355c521f12
Misc small clean ups and fixes 3 years ago
jackun a82e27d978
Use spdlog macros so logging can be completely disabled during compile-time 3 years ago
jackun 46c2183b5d
Use engine type enum in `engine_version()` 3 years ago
jackun 7d3b6b946d
Don't reinit stuff when re-creating swapchain
Partial revert of e13e98e03a
3 years ago
jackun 6c604f379c
Fix parse_pciids when trying to open pci.ids from alternate location 3 years ago
jackun 944202f273
Fix #ifdef scope in `overlay_DestroyInstance` 3 years ago
jackun d41ad84260
Poll amdgpu regs at 120ticks/s regardless of sampling period 3 years ago
jackun 2f807a4c0d
Add `spdlog` wrap and logging 3 years ago
jackun c093f9823e
Use libdrm_amdgpu for amdgpu sensor info, if available
Using plain `open` as `drmOpen` needs bus id check which needs interface 1.4 ioctl which gives EPERM cause only DRM_MASTER can call it :(

https://github.com/clbr/radeontop/issues/48#issuecomment-493792404
3 years ago
jackun 88d801bd7e
Move functions not directly related to vulkan from vulkan.cpp to overlay.cpp 3 years ago
jackun 8244d7f288
Fix vulkan driver's patch version 3 years ago
Joshua Martin 3b0b6fbc42
Add position options to place the overlay halfway down the screen (#561) 3 years ago
jackun b6dab97d08
[OpenGL] Some code clean-ups 3 years ago
jackun f8bb948de2
More quotation glyphs 3 years ago
Lukáš Horáček 213953089d
Detect ToGL 3 years ago
Lukáš Horáček f1eae93253
Use map_files instead of lsof for wined3d detection 3 years ago
jackun 750d2cddb5
Make engine type per instance 3 years ago
FlightlessMango e39513cfa4 still check PengineName if engine OpenGL 3 years ago
FlightlessMango 3f120b1fc5 don't set engine to vulkan if already set 3 years ago
Alessandro Toia 0bc6d33a24 Fix frame spikes when using battery parameter 3 years ago
Alessandro Toia 570bef468b Cosmetic changes to engine detection 3 years ago
FlightlessMango 5330573c8c don't rely on std in engine detection 3 years ago
FlightlessMango 94dda243a5 Battery: header include filesystem.h 3 years ago
FlightlessMango 226330c0d7 Battery: assume unknown status is charging 3 years ago
jackun 9da427d093
Include u2019 (RIGHT SINGLE QUOTATION MARK) glyph by default 3 years ago
jackun 0ee101e0ac
Fix MPRIS ticker, microseconds to nanoseconds 3 years ago
FlightlessMango a50bbbac22 add battery, fps_limit and resolution to legacy layout 3 years ago
jackun 37d8c75c78 Skip calculating IO stats for first sample
Or you get high read/write speeds averaged over process' whole lifetime.
3 years ago
flightlessmango 428ddf4e8a
Merge pull request #536 from flightlessmango/battery_test
Battery info and font awesome icons
3 years ago
FlightlessMango 2e5fc31711 use vulkan to determine if zink 3 years ago
FlightlessMango 92282bcec2 convert frametime from ns to us 3 years ago
Joshua Ashton 815097718e Use nanoseconds to calculate fps
No need to round this earlier on.

Removes an unnecessary implicit float -> double conversion in the calculation also
3 years ago
Joshua Ashton 1f0119bc91 Use raw clocks if available
Avoids NTP synchronization having impact on frametime pacing.
3 years ago
medusalix 560930214a Fix CPU power calculations 3 years ago
Alessandro Toia 5c48b4729c Change param to battery, add param for icon, hide power when plugged in 3 years ago
jackun a0a57038c1
Fix redefinition of 'open'
musl pulls in fcntl.h from somewhere
3 years ago
Alessandro Toia 105ad9c2be Check for batteries only once 3 years ago
Alessandro Toia 500a65dd52 Only display battery stats if a battery is present 3 years ago
Alessandro Toia a533883a39 Check if there are battieres before attempting to retrieve stats 3 years ago
Alessandro Toia 8960a54813 Change battery path list to array 3 years ago
Alessandro Toia 6833ee3593 Check if battery(s) are fully charged 3 years ago
Alessandro Toia 6c69f68f7f Iterate over n batteries to find energy consumption 3 years ago
Alessandro Toia e63a5bd472 Iterate over n batteries to find percent 3 years ago
Alessandro Toia 62db1495d6 Scale down icons if font is small 3 years ago
Alessandro Toia 5656001639 Add forkawesome from compressed Base85 TTF 3 years ago
Alessandro Toia 552a85aaaa Only update battery stats if a battery is present 3 years ago
Alessandro Toia c6074b0f4d Check if there are batteries before checking if they are charging 3 years ago
Alessandro Toia 8980ff46bc When plugged in change battery icon according to percent 3 years ago
Alessandro Toia 5adb4500c7 Install forkawesome font file 3 years ago
Alessandro Toia b89b9b8109 Add ForkAwesome Icons 3 years ago
Alessandro Toia 1ab25220c6 Add param to check battery power and percent 3 years ago
FlightlessMango a90c897feb Check battery info 3 years ago
Alessandro Toia d556e8e357 Improve Zink detection 3 years ago
Alessandro Toia 36ec9ef41a Add round_corners param 3 years ago
jackun 47865573a8
Add option to prepend libdir to library's path in vulkan manifest
"\$LIB" technically breaks json but on the other hand vulkan loader
currently doesn't handle "\\$LIB"
Help with issue #468
3 years ago
jackun 765024227c
[OpenGL] Framerate limit in eglSwapBuffers 3 years ago
Alessandro Toia ddfcb01c30 Add detection of Zink 3 years ago
jackun a724e5e294
Fix engine name not showing with `engine_version` without `fps` also enabled 3 years ago
jackun 34f964eab9
Use aligned buffer size with vkMapMemory too 3 years ago
Alessandro Toia 856c333e09 Fix wine param not properly detecting proton experimental 3 years ago
Alessandro Toia 272b035ca8 Fix wine param not detecting proton experimental 3 years ago
jackun 0f6ead57d7
[OpenGL] Bind framebuffer for all GL ES versions 3 years ago
jackun e62d6e3337
[OpenGL] Save/restore last GL_DRAW_FRAMEBUFFER if using `gl_bind_framebuffer` 3 years ago
jackun 714f3853f7
[OpenGL] Support apitrace in debug build
Try to load `glxtrace.so` instead of `libGL.so.1`.
Assumes `glxtrace.so` lives outside of usual library paths and is only preloaded.
3 years ago
jackun afa50a17c4
[OpenGL] Add gl_size_query, gl_bind_framebuffer, gl_dont_flip options for workarounds
`gl_size_query = viewport` - specify what to use for getting display size. Options are "viewport", "scissorbox" or disabled. Defaults to using glXQueryDrawable.
`gl_bind_framebuffer = 0` - (re)bind given framebuffer before MangoHud gets drawn. Helps with Crusader Kings 3.
`gl_dont_flip = 1` - don't swap origin if using GL_UPPER_LEFT. Helps with Ryujinx.
3 years ago
jackun 54d6a8e889
Unset LD_LIBRARY_PATH if using absolute paths in LD_PRELOAD
$LIB in LD_LIBRARY_PATH makes `ldconfig` unhappy.
3 years ago
jackun ea07d1e080
Remove ".exe" from wine executable's name
Fixes ad4e1ac35f
3 years ago
jackun ad4e1ac35f
Try to get wine executable's name from /proc/self/comm 3 years ago
jackun 4d4444e1c5
Allow overriding config file options with MANGOHUD_CONFIG if using legacy layout 3 years ago
jackun 4f3133c5da
Fix log file using `wine-preloader` etc instead of executable's filename 3 years ago
Lukáš Horáček 8f3ecb81df Divide IO stats by time difference since last update
This should prevent IO stats reaching high numbers when application stops responding resulting into MangoHud not updating.
3 years ago
jackun 30cdc912a8
Rework blending equation to preserve alpha in output buffer
bda12e5fdd
3 years ago
jackun 118c54072f
[OpenGL] Disable primitive restart 3 years ago
jackun 8e7564ab1a
[OpenGL] Disable stencil test 3 years ago
jackun bdd87f5eff
Use SetTexID instead 3 years ago
jackun 76b571bc11
[OpenGL] Fix glClipControl(GL_UPPER_LEFT) rendering 3 years ago
jackun 6c737dc734
Round up buffer allocation sizes to `nonCoherentAtomSize`.
For some Vega APUs. Or don't use VK_WHOLE_SIZE?
3 years ago
jackun f77a73ce8a
Fix scoped_lock clash with >= c++17 3 years ago
jackun 3e77dd6e0b
[OpenGL] Add eglSwapBuffers to hook list 3 years ago