RoanH / KeysPerSecond

A keys-per-second meter & counter. Written for osu! but should work for other rhythm games too.
https://osu.ppy.sh/forum/t/552405/
GNU General Public License v3.0
347 stars 28 forks source link

Window Capture on the program freezes during recording and only works in preview/not recording (OBS), help? #54

Closed Synth-ix closed 2 years ago

Synth-ix commented 2 years ago

I've had this problem for a little bit and I need some support on how to fix this issue, please and thank you!

RoanH commented 2 years ago

That's not really enough information to say anything with certainty, but I do have one idea. For me OBS is able to capture the KeysPerSecond window just fine using a window capture (method automatic), so assuming OBS is up to date it is probably not the cause.

Are you perhaps trying to record the window while playing a game in exclusive full screen mode at the same time and while only having one monitor? When you only have one display and are doing something in exclusive full screen mode then Windows will prevent all other programs from updating their window (because it thinks you can't see them anyway). I don't have a perfect solution for this, but from my testing it seems like just having a second monitor attached completely prevents this behaviour, so in this case you could even try to connect your phone as an extra display or something.

Synth-ix commented 2 years ago

Hm, osu! doesn't have an exclusive fullscreen option from what I know of, so it might be OBS updates required to fix this glitch. I'll check it out.

Edit: I remembered how I transferred my old KPS counter save from my old setup through USB, the file type is kpsconfig3. That means its outdated. Looks like I'll have to remake it, that'll HOPEFULLY fix this problem. Again, I'll check.

Synth-ix commented 2 years ago

RESULT: Ok, I updated OBS, updated my KPS counter, checked for anything else on osu! that might've caused it. But when I rewatched the footage it suddenly updated AS SOON as I exited out of osu! to end recording.

Is there something the game's hiding? Or is it solely just cause OBS is fucking up? I mean, I also have gosu!memory running at the same time, and that worked just fine, it's just KeysPerSecond that stays frozen mid-recording. I'm not sure what else that needs to be done.

RoanH commented 2 years ago

osu! by default runs in exclusive full screen mode (windowed is the opposite, and full screen windowed is visually mostly the same as exclusive full screen). But if it updates right as you exit then it is probably Windows freezing all updates like I said in my first comment. The only way around that is to attach an extra display or to make Windows think you have an extra display attached. I'm not aware of any other methods to prevent Windows from stopping other programs from updating when a different program is running in exclusive full screen mode (though there might be a way, it's just not easy to search for solutions).

Synth-ix commented 2 years ago

Okay, I figured something out! Turns out osu! also has an option to toggle off "fullscreen" which is exclusive, as you explained. But as long as your resolution is native to your screen entirely, then it might as well act like inexclusive fullscreen! I feel like the input delay could differ based on how well a PC can render the screen, yet it was more fortunate on my end, since I basically didn't experience any change at all.

tl;dr: when i recorded the footage, it actually worked this time! thanks for the help and suggestions!

RoanH commented 2 years ago

Yep, you're correct. Performance of full screen windowed is usually pretty good, but as you as said could potentially negatively affect performance (but recording software is going to be a bigger issue on that front anyway). Good to hear that the performance is fine for you making it a viable solution. Thanks for using KeysPerSecond :)