Struct quicksilver::graphics::Surface [−][src]
pub struct Surface { /* fields omitted */ }
A possible render target that can be drawn to the screen
Methods
impl Surface
[src]
impl Surface
pub fn new(width: u32, height: u32) -> Surface
[src]
pub fn new(width: u32, height: u32) -> Surface
Create a new surface with a given width and height
pub fn render_to<F>(&self, window: &mut Window, func: F) where
F: FnOnce(&mut Window),
[src]
pub fn render_to<F>(&self, window: &mut Window, func: F) where
F: FnOnce(&mut Window),
Render data to the surface
Do not attempt to use the surface or its image within the function, because it is undefined behavior
pub fn image(&self) -> &Image
[src]
pub fn image(&self) -> &Image
Get a reference to the Image that contains the data drawn to the Surface
Trait Implementations
impl Clone for Surface
[src]
impl Clone for Surface
fn clone(&self) -> Surface
[src]
fn clone(&self) -> Surface
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
impl Debug for Surface
[src]
impl Debug for Surface