Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImGui: Make input recording frame count thread-safe #12175

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

TheTechnician27
Copy link
Contributor

@TheTechnician27 TheTechnician27 commented Jan 8, 2025

Description of Changes

Make the communication between the EE (input recording) and the GS (displaying the frame count via ImGui) thread-safe. Additionally fixes a bug where the frame count was +1 what it should actually be. See #10793, which this is a follow-up to. (This fixes a small bug from that as well.)

Rationale behind Changes

Good to have the correct value displayed (previously we would run into an issue where we would say that we're on a frame that doesn't exist yet; for example, if we'd written 580 frames to an input recording and were actively recording, we'd be on frame 581). And make the code operate in a way that's not subject to a potential race condition.

Suggested Testing Steps

Test input recording to make sure 1) the correct value is displayed and 2) nothing is broken.

Fixes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG]: Total input counter is not updated upon loading state (input recording)
1 participant