[][src]Struct quicksilver::graphics::Surface

pub struct Surface { /* fields omitted */ }

A possible render target that can be drawn to the screen

Methods

impl Surface[src]

pub fn new(width: u32, height: u32) -> Result<Surface>[src]

Create a new surface with a given width and height

pub fn render_to(
    &self,
    window: &mut Window,
    func: impl FnOnce(&mut Window) -> Result<()>
) -> Result<()>
[src]

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]

Get a reference to the Image that contains the data drawn to the Surface

Trait Implementations

impl Clone for Surface[src]

impl Debug for Surface[src]

Auto Trait Implementations

impl !Send for Surface

impl !Sync for Surface

impl Unpin for Surface

impl UnwindSafe for Surface

impl !RefUnwindSafe for Surface

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> SetParameter for T

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<SS, SP> SupersetOf<SS> for SP where
    SS: SubsetOf<SP>, 
[src]

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

impl<T> Downcast for T where
    T: Any