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

feat(TimeSmoother): Smoother note falling on vsync mode #835

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

phu54321
Copy link

@phu54321 phu54321 commented Nov 18, 2024

Vsync doesn't really ensure evenly timed MainController::render() calls. They jitter, and they jitter a lot. More than you'd expect. (You can measure it yourself) This commit adds TimeSmoother that smooths jittered time when vsync is enabled. Smoothed time only takes effect on rendering. The commit does not intend to introduce any in-game internal processings.

If we don't have vsync, It is expected to have frame drops or changes in render() call interval, so TimeSmoother is not enabled when vsync is off.

Example video: Right is before, Left if after. Both vsync on 60fps display.

video

Note that because on current master branch the key input is synchronized to render() call, #829 should be merged for better vsync-ed play experience.

Vsync doesn't really ensure evenly timed `MainController::render()` calls.
They jitter, and they jitter a lot. More than you'd expect. (You can
measure it yourself) This commit adds `TimeSmoother` that *smooths*
jittered time when vsync is enabled.

If we don't have vsync, It is expected to have frame drops or changes in
render() call interval, so `TimeSmoother` is not enabled when vsync is off.
@phu54321 phu54321 changed the title feat(TimeSmoother): Smooth skin rendering on vsync mode feat(TimeSmoother): Smoother note falling on vsync mode Nov 21, 2024
@RaceDriverMIKU
Copy link

I hope it also applies whether vsync applied or not. capping FPS w/o vsync in beatoraja is also very jittery.

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

Successfully merging this pull request may close these issues.

2 participants