Instead of using timer and calling refresh on GlConrol, new rendering loop should be made. Loop repeats indefinitely (until program is closed) in background thread and perform following steps:
Check for changes (like settings and visual objects)
Render frame
Wait for next frame
There should be two waiting modes:
Busy spin which favors timing precision over CPU utilization
Thread.Sleep based which saves battery power but doesn't sacrifices timing precision
Instead of using timer and calling refresh on GlConrol, new rendering loop should be made. Loop repeats indefinitely (until program is closed) in background thread and perform following steps:
There should be two waiting modes: