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

Call redraw while resizing windows #15915

Open
alice-i-cecile opened this issue Oct 15, 2024 · 5 comments
Open

Call redraw while resizing windows #15915

alice-i-cecile opened this issue Oct 15, 2024 · 5 comments
Labels
A-Windowing Platform-agnostic interface layer to run your app in C-Bug An unexpected or incorrect behavior D-Straightforward Simple bug fixes and API improvements, docs, test and examples S-Ready-For-Implementation This issue is ready for an implementation PR. Go for it! X-Uncontroversial This work is generally agreed upon

Comments

@alice-i-cecile
Copy link
Member

Would it be possible to call redraw while we're resizing, so window gets updated immediately, rather than just stretching until we're done?

Originally posted by @MiniaczQ in #15814 (review)

@alice-i-cecile alice-i-cecile added C-Bug An unexpected or incorrect behavior A-Windowing Platform-agnostic interface layer to run your app in S-Ready-For-Implementation This issue is ready for an implementation PR. Go for it! X-Uncontroversial This work is generally agreed upon D-Straightforward Simple bug fixes and API improvements, docs, test and examples labels Oct 15, 2024
@BenjaminBrienen
Copy link
Contributor

I think this should be configurable behavior, and I'd be fine with either being the default.

@mrec
Copy link

mrec commented Oct 15, 2024

I remember @raphlinus posting about this being a bit hairy on Windows some years back, though things may have improved since then.

Ref: rust-windowing/winit#786

FWIW his issues were with doing it perfectly smoothly though, not with doing it at all.

@alice-i-cecile
Copy link
Member Author

alice-i-cecile commented Oct 15, 2024

Yeah, especially as a configurable behavior I'm fine with a bit of jank vs not doing it at all. This is much less important for Bevy than for Raph's focus on traditional desktop apps.

@doup
Copy link
Contributor

doup commented Nov 16, 2024

I think I'm in the right issue, I noticed that window resizes don't lag anymore… but now it stretches in a funny way. I just wanted to share a video:

bevy-resize-wobble.mp4

This case is worse though (wait until the end of the video), when the resize is triggered by doble-clicking on the title bar (macOS) there is a huge delay until it refreshes. In this case I'm not moving the cursor after the resize which, I think, makes it worse:

bevy-resize-render-lag.mp4

@MiniaczQ
Copy link
Contributor

It appears to be the discrepancy between layout engine and window stretching to fit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Windowing Platform-agnostic interface layer to run your app in C-Bug An unexpected or incorrect behavior D-Straightforward Simple bug fixes and API improvements, docs, test and examples S-Ready-For-Implementation This issue is ready for an implementation PR. Go for it! X-Uncontroversial This work is generally agreed upon
Projects
None yet
Development

No branches or pull requests

5 participants