Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Questions about ImGuiIO::DeltaTime ? #5043

Closed
tomazos opened this issue Feb 21, 2022 · 2 comments
Closed

Questions about ImGuiIO::DeltaTime ? #5043

tomazos opened this issue Feb 21, 2022 · 2 comments
Labels

Comments

@tomazos
Copy link

tomazos commented Feb 21, 2022

Couple of quick imgui questions if you have time...

The first code comment on ImGuiIOs Configuration section says fill once. Is it not ok to modify the configuration between each frame? (example_null, at least, seems to set DisplaySize and DeltaTime prior to each NewFrame / Render. ?)

The code comment on ImGuiIO::DeltaTime states:

Time elapsed since last frame, in seconds.

Our engine has a mailbox mode where frames are continuously rendered and the most recent render is presented at vsync-time. In this mode, should I set DeltaTime to the time elapsed since last render or since last present? (ie What is DeltaTime used for?)

What should DeltaTime be set to for the first frame, since there is no last frame? Is zero okay? or is that going to break things?

Thanks

@tomazos tomazos changed the title Questions about ImGuiIO:DeltaTime ? Questions about ImGuiIO::DeltaTime ? Feb 21, 2022
@ocornut
Copy link
Owner

ocornut commented Feb 21, 2022 via email

@tomazos
Copy link
Author

tomazos commented Feb 21, 2022

Sure, thanks.

@tomazos tomazos closed this as completed Feb 21, 2022
@ocornut ocornut added the doc label Feb 21, 2022
ocornut added a commit that referenced this issue Feb 21, 2022
…4858)

+ Snuck in unrelated comments and removed the "fill once" comment (#5043)
edvn0 pushed a commit to edvn0/imgui that referenced this issue Feb 24, 2022
…4921, ocornut#4858)

+ Snuck in unrelated comments and removed the "fill once" comment (ocornut#5043)
sergeyn pushed a commit to sergeyn/imgui that referenced this issue Mar 19, 2022
…4921, ocornut#4858)

+ Snuck in unrelated comments and removed the "fill once" comment (ocornut#5043)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants