armory3d / armory3d/armory

Weird Vsync behaviour

Open
#2,913 5 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
C++
Stars
3.3k
Forks
353
Avg merge
3d 16h
Merged PRs (30d)
1

Description

**Description**
When Vsync is turned of, I expect the framerate to be uncapped. To test this I call the game update on render, as the FPS counter of the Debug View was shown to not be reliable. The FPS seems to be uncapped, but only if the window is not in Focus, and kha reports VSync to still be turned on. See the attached video. It is a bit hard to see due to the low frame rate, but the cube spins a lot faster when the window is not focused. If it were the other way around, the fps being unlocked while the game is in the background, everything would be fine.

This happens regardless if Vsync is enabled or not. All this is regarding Krom.
**To Reproduce**
Have a way to reliably measure FPS. and notice a difference beteween focused and unfocused window behaviour

**System**
Blender: 3.6.1LTS
Armory: current ArmSDK
OS: Win 10
Graphics card: GTX 1060

[vsync.zip](https://github.com/armory3d/armory/files/12209324/vsync.zip)

Contributor guide

No contributing guide indexed for this repository

Research direction

Reproduce the focused versus unfocused window behavior in Krom using the attached vsync.zip and a reliable FPS measurement, with Vsync enabled and disabled. Compare the reported VSync state and frame rate in both focus states; done means the behavior matches the expected uncapped or capped frame rate consistently.

Written by the indexing model from the issue text.

Assessment

Tech stack
blender, cpp
Domain
computer-graphics, game-dev, performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.