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

eframe glow backend: Clear framebuffer color before calling App::update #3665

Merged
merged 4 commits into from
Nov 30, 2023

Conversation

emilk
Copy link
Owner

@emilk emilk commented Nov 30, 2023

@emilk emilk added bug Something is broken eframe Relates to epi and eframe labels Nov 30, 2023
@emilk emilk merged commit 4b1523a into master Nov 30, 2023
35 checks passed
@emilk emilk deleted the emilk/clear-before-paint branch November 30, 2023 15:37
@emilk emilk changed the title eframe glow backend: Clear render target before calling App::update eframe glow backend: Clear framebuffer color before calling App::update Nov 30, 2023
emilk added a commit that referenced this pull request Dec 18, 2023
I broke this in #3665

For some reason, when using multiple viewports, the first "clear"
doesn't take.

I don't have time to investigate further, so I am adding a hack here
which:

* For single-viewport apps, the clear is done before `App::update` so
user can paint there
* For multi-viewport apps, the clear is done after `App::update`, so
that it works

This means painting in `App::update` won't work with multi-viewports.

Ideally, users should use paint callbacks instead of painting directly
in `App::update` anyways.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is broken eframe Relates to epi and eframe
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Order of clearing and painting change in 0.24?
1 participant