Frame limiting
#2229
Replies: 1 comment 1 reply
-
I would make sure VSync is off to frame limit on the window. But to be honest, for your application the approach I would use would be using a cumulative delta time to determine when to switch to the next frame. e.g. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am trying to make a very simple video player in OpenGL (and Vulkan afterwards). I decode each frame using the FFmpeg.Autogen library and send the pixel data as a
byte*
and the frame dimensions to a queue in my OpenGL renderer class. Each frame gets dequeued in theRender
event where a texture gets updated with the new pixel data. The issue is that the playback is extremely fast. I have tried usingThread.Sleep
, setting theIWindow
's propertiesFramesPerSecond
andUpdatesPerSecond
to 30 or 60, experimenting with delta time and apparently nothing works. Also, no code exists that demonstrates how to implement a frame limiter in the examples folder.Beta Was this translation helpful? Give feedback.
All reactions