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

Why queue two frame at most instread of read the latest frame? #128

Open
junlinp opened this issue Nov 8, 2024 · 1 comment
Open

Why queue two frame at most instread of read the latest frame? #128

junlinp opened this issue Nov 8, 2024 · 1 comment

Comments

@junlinp
Copy link

junlinp commented Nov 8, 2024

queuedFrame = EventHandler.shared.frameQueue.count > 0 ? EventHandler.shared.frameQueue.removeFirst() : nil

should it read the latest one frame in the queue?
two frame cache would cause 22 ms around latency when the render rate is 90Hz.

@shinyquagsire23
Copy link
Collaborator

stability reasons mostly, the buffer allows small circumstantial frame drops to be less noticable and large frame drops to be used as an opportunity to fill the buffer

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

No branches or pull requests

2 participants