pub trait App {
type RenderContext;
// Required methods
fn update(&mut self, ctx: &mut Context) -> Result<()>;
fn render(
&mut self,
ctx: &mut Self::RenderContext,
blending_factor: f64
) -> Result<()>;
// Provided method
fn handle(&mut self, _event: &Event<()>) -> Result<()> { ... }
}
Expand description
Application trait.
Required Associated Types§
sourcetype RenderContext
type RenderContext
Will be provided in render()
.