render: move Error type into associated types
This commit is contained in:
@@ -29,7 +29,8 @@ pub trait Shader: Send + Sync {
|
||||
|
||||
pub trait Surfaces: Send + Sync {
|
||||
type Surface: Surface;
|
||||
fn new_surface(&mut self, area: &Rectangle<Virtual>) -> Result<Self::Surface, io::Error>;
|
||||
type Error: Debug;
|
||||
fn new_surface(&mut self, area: &Rectangle<Virtual>) -> Result<Self::Surface, Self::Error>;
|
||||
fn render_to<S: Sample>(&self, output: &mut S, frame: usize);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user