drawing_impeller 1002.0.1

Impeller backend for 2D graphics library
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
pub struct ImpellerSurface {
    pub(crate) surface: impellers::Surface,
}

impl drawing_api::Surface for ImpellerSurface {
    type DisplayList = crate::DisplayList;

    fn draw(&mut self, display_list: &Self::DisplayList) -> Result<(), &'static str> {
        self.surface.draw_display_list(&display_list.display_list)
    }

    fn present(self) -> Result<(), &'static str> {
        self.surface.present()
    }
}