imgui does not accept io.DeltaTime=0
madebr opened this issue · 0 comments
madebr commented
After bumping to imgui 1.83.0, imguitest
occasionally crashes with an assertion error:
imguitest: /home/maarten/programming/librw/skeleton/imgui/imgui.cpp:7147: void ImGui::ErrorCheckNewFrameSanityChecks(): Assertion `(g.IO.DeltaTime > 0.0f || g.FrameCount == 0) && "Need a positive DeltaTime!"' failed.
https://github.com/ocornut/imgui/blob/cc40ae2101acd1fb4e0585a46198e6fd12960617/imgui.cpp#L7195
I traced it back to io.DeltaTime
being zero.
When using linux+gl3+sdl2, this value is derived from SDL_GetTicks
:
Lines 300 to 303 in b164e49
io.DeltaTime
is set here:
librw/skeleton/imgui/imgui_impl_rw.cpp
Line 190 in b164e49
My old machine is too fast