pub trait Renderer: Debug {
type Error: Error + Send + Sync + 'static;
// Required methods
fn prepare_frame(&mut self) -> Result<(), Self::Error>;
fn render(&mut self) -> Result<(), Self::Error>;
fn resize(&mut self, extent: RenderExtent) -> Result<(), Self::Error>;
}Expand description
Renderer backend operations driven by the application loop.
Required Associated Types§
Required Methods§
Sourcefn prepare_frame(&mut self) -> Result<(), Self::Error>
fn prepare_frame(&mut self) -> Result<(), Self::Error>
Prepares renderer-owned state for the next frame.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".