Notify window before presentation

This commit is contained in:
Héctor Ramón Jiménez 2025-03-18 18:22:39 +01:00
parent 363b0e903a
commit 31b98ee3eb
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
5 changed files with 29 additions and 2 deletions

View file

@ -80,6 +80,7 @@ pub trait Compositor: Sized {
viewport: &Viewport,
background_color: Color,
overlay: &[T],
on_pre_present: impl FnOnce(),
) -> Result<(), SurfaceError>;
/// Screenshots the current [`Renderer`] primitives to an offscreen texture, and returns the bytes of
@ -193,6 +194,7 @@ impl Compositor for () {
_viewport: &Viewport,
_background_color: Color,
_overlay: &[T],
_on_pre_present: impl FnOnce(),
) -> Result<(), SurfaceError> {
Ok(())
}