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

Make frame delay on screenshots consistently one frame on web as well #5482

Merged
merged 1 commit into from
Dec 16, 2024

Conversation

Wumpf
Copy link
Collaborator

@Wumpf Wumpf commented Dec 16, 2024

Native is already delayed by a frame because it calls handle_viewport_output -> egui_winit::process_viewport_commands after drawing. On web however, we process input including viewport commands separately from drawing.
This adds an arbitrary frame delay mechanism for web and then uses this with 1 frame delay always

Copy link
Owner

@emilk emilk left a comment

Choose a reason for hiding this comment

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

🙏

@Wumpf Wumpf added web Related to running Egui on the web exclude from changelog labels Dec 16, 2024
@Wumpf Wumpf merged commit b1d2551 into master Dec 16, 2024
47 of 48 checks passed
@Wumpf Wumpf deleted the consistent-frame-delay-on-screenshots branch December 16, 2024 14:03
Copy link

Preview available at https://egui-pr-preview.github.io/pr/5482-consistent-frame-delay-on-screenshots
Note that it might take a couple seconds for the update to show up after the preview_build workflow has completed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
exclude from changelog web Related to running Egui on the web
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants