Skip to content

Conversation

@tkpmonke
Copy link
Contributor

same as title

this doesn't include rgfw_rawfb, yet i play on doing that soon

while (!RGFW_window_shouldClose(win) && running)
{
/* Input */
RGFW_window_checkEvents(win, RGFW_eventNoWait);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be checked to pollEvents, don't use checkEvent if you don't need the event queue.

Comment on lines 231 to 240
NK_API double
nk_RGFW_get_time() {
static time_t start = 0;
if (start == 0) {
start = time(0);
}

return difftime(time(0),start);
}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably better to use clock or something. Time is per second.

Also what is diff time? Just time - time should work.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Diff time is the difference in time between the two arguments

@ColleagueRiley
Copy link
Member

ColleagueRiley commented Aug 11, 2025

Needs to be updated to newest version. Probably better to wait for RGFW 1.8.0 to be released.

@tkpmonke
Copy link
Contributor Author

updated time function due to it being imprecise

@ColleagueRiley
Copy link
Member

Clock isn't standard across all OSes, see https://github.com/ColleagueRiley/rtime/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants