Welcome,
Guest
. Please
login
or
register
. Did you miss your
activation email?
French forum
Home
Help
Search
Login
Register
SFML community forums
»
Help
»
Graphics
»
Vsync limits entire loop to 60 cycles per second
Print
Pages: [
1
]
Author
Topic: Vsync limits entire loop to 60 cycles per second (Read 2401 times)
0 Members and 1 Guest are viewing this topic.
inaudax
Newbie
Posts: 7
Vsync limits entire loop to 60 cycles per second
«
on:
September 13, 2014, 07:29:12 am »
My understanding of vsync in SFML is that it is only supposed to limit the calls to the display() function of sf::RenderWindow. However, whenever I have vsync enabled the entire game loop gets limited to 60 cycles per second. Has anyone else encountered this issue?
Logged
OniLinkPlus
Hero Member
Posts: 500
Re: Vsync limits entire loop to 60 cycles per second
«
Reply #1 on:
September 13, 2014, 08:04:53 am »
This is exactly how Vsync is supposed to work. If Vsync is enabled, every time you call display(), the program goes to sleep until the next vertical sync of your monitor.
Logged
I use the latest build of SFML2
Hapax
Hero Member
Posts: 3379
My number of posts is shown in hexadecimal.
Re: Vsync limits entire loop to 60 cycles per second
«
Reply #2 on:
September 15, 2014, 10:48:10 pm »
If you need to run your 'game loop' more rapidly than the display rate, you'll need to "decouple the simulation and rendering framerates", as described in
this article about time steps
.
Logged
Selba Ward
-SFML drawables
Cheese Map
-Drawable Layered Tile Map
Kairos
-Timing Library
Grambol
*
Hapaxia Links
*
Print
Pages: [
1
]
SFML community forums
»
Help
»
Graphics
»
Vsync limits entire loop to 60 cycles per second