-
-
Notifications
You must be signed in to change notification settings - Fork 58
Closed
Labels
Description
Instead of converting from one draw state API to another, an idea is to use a simplified draw state that cover the use cases we have today.
pub struct DrawState {
pub blend: Blend,
pub stencil: Option<Stencil>,
pub scissor: Option<[u32; 4]>,
}
impl Default for DrawState {
fn default() -> Self {
DrawState {
blend: Blend::Alpha,
stencil: None,
scissor: None,
}
}
}
pub enum Blend {
Alpha,
Add,
Multiply,
Invert,
}
pub enum Stencil {
Clip(u8),
Inside(u8),
Outside(u8),
}