Commit Graph

19 Commits

Author SHA1 Message Date
TryTwo 9f56a3f6f1 ImGui: Add font path and size options to InterfacePane and adjust common ImGui draws that break from variable sizes. 2025-05-26 02:03:55 -07:00
Mihai Brodschi bad78cfed4 Core, VideoCommon: Fix crash at shutdown due to destructor ordering
Previously, PerformanceTracker registered a callback to be updated on
emulation state changes. PerformanceTrackers live in a global variable
(g_perf_metrics) within libvideocommon. The callback was stored in a
global variable in libcore. This created a race condition at shutdown
between these libraries, when the PerfTracker's destructor tried to
unregister the callback.
Notify the PerfTracker directly from libcore, without callbacks, since
Core.cpp already references g_perf_metrics explicitly. Also rename
Core::CallOnStateChangedCallbacks to NotifyStateChanged to better
reflect what it's doing.
2025-04-28 07:11:53 +03:00
Tilka 5523b9a01b
Merge pull request #13487 from Dentomologist/performancemetrics_fix_window_arrangement
PerformanceMetrics: Fix window arrangement
2025-04-25 01:40:58 +01:00
Dentomologist ec49ea5be3 PerformanceMetrics: Fix window arrangement
Fix overlays stacking on top of each other or not moving to the edge of
the screen when enabling or disabling overlays while emulation is
active.

This change only applies when Config::GFX_MOVABLE_PERFORMANCE_METRICS is
False.
2025-04-05 14:22:17 -07:00
Jordan Woyak c42dab6388 Core: Move CountPerformanceMarker to VideoInterface to eliminate a Throttle call. PerformanceMetrics: Fixes/Cleanups. 2025-04-02 23:23:51 -05:00
Joshua Vandaële 3a1a60d4f8
Fix shadowed variable warnings and missing declarations
- PPCSymbolDB:  Resolve shadowed variable warnings
- PerformanceMetrics:  Resolve shadowed variable warnings
- SWEfbInterface: Add missing declarations
2025-03-27 21:48:08 +01:00
JMC47 28f1beeca8
Merge pull request #13398 from jordan-woyak/perf-tracker
PerformanceTracker: Eliminate mutex. General cleanups.
2025-03-23 15:21:11 -04:00
Jordan Woyak 46e0952e97 PerformanceTracker: Use SPSCQueue and atomic to eliminate need for a mutex. Clean up some math. 2025-03-15 14:40:00 -05:00
Jordan Woyak 2690a62949 Core: Remove unused GetActualEmulationSpeed function and related variables/functions. 2025-03-14 03:10:13 -05:00
Jordan Woyak e1745f682f PerformanceMetrics: Eliminated a mutex. Code cleanups. 2025-03-14 03:10:13 -05:00
Dentomologist 0645a267d9 PerformanceMetrics: Add clamping, resetting on resize, and setting
Clamp overlays to the render window (with some padding), reset their
positions when the render window changes sizes, and add a setting to
enable moving the overlays (off by default, .ini only for now).
2025-02-24 13:17:57 -08:00
Admiral H. Curtiss 05f217bd0b
Merge pull request #13330 from Dentomologist/performancemetrics_allow_moving_overlays
PerformanceMetrics: Allow users to move overlays
2025-02-06 21:56:57 +01:00
Dentomologist 4b8e36cba9 PerformanceMetrics: Allow users to move overlays
Allow users to move the FPS, VPS, Speed, and Performance Graph overlays.
2025-02-02 19:40:01 -08:00
Dentomologist f94e6cb73e PerformanceMetrics: Call ImGui::End() unconditionally
Move ImGui::End() calls out of if(ImGui::Begin()) blocks.

Quoting from ImGui::Begin's function comment in imgui.cpp:
"You always need to call ImGui::End() even if false is returned."

In practice this didn't cause problems because the windows don't have
title bars and thus can't be collapsed, and so the block containing
::End would always run, but let's do it the right way.
2025-02-02 14:14:56 -08:00
Admiral H. Curtiss 069280ddc6
HW/VideoInterface: Refactor to class. 2023-03-11 12:50:35 +01:00
Sam Belliveau ebf114aef5 Tie Speed to CPU Speed and not VPS 2023-01-29 13:33:48 -05:00
Sam Belliveau bc1cc9eeb4 CoreTiming: Throttle Before Every Event Using Chrono 2023-01-06 17:21:17 -05:00
Sam Belliveau 9143eb00fb
PerformanceMetrics: Fix Line Width Issue on Non HiDPI Screens 2023-01-06 20:27:17 +01:00
Sam Belliveau 673f81c18a New FrameTime/VBlank Analyzer + Graph 2022-12-23 19:52:53 -05:00