[][src]Struct glium::Frame

pub struct Frame { /* fields omitted */ }

Implementation of Surface, targeting the default framebuffer.

The back- and front-buffers are swapped when you call finish.

You must call either finish or set_finish or else the destructor will panic.

Implementations

impl Frame[src]

pub fn new(context: Rc<Context>, dimensions: (u32, u32)) -> Frame[src]

Builds a new Frame. Use the draw function on Display instead of this function.

pub fn finish(self) -> Result<(), SwapBuffersError>[src]

Stop drawing, swap the buffers, and consume the Frame.

See the documentation of SwapBuffersError about what is being returned.

pub fn set_finish(&mut self) -> Result<(), SwapBuffersError>[src]

Stop drawing, swap the buffers.

The Frame can now be dropped regularly. Calling finish() or set_finish() again will cause Err(SwapBuffersError::AlreadySwapped) to be returned.

Trait Implementations

impl Drop for Frame[src]

impl Surface for Frame[src]

Auto Trait Implementations

impl !RefUnwindSafe for Frame

impl !Send for Frame

impl !Sync for Frame

impl Unpin for Frame

impl !UnwindSafe for Frame

Blanket Implementations

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

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

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

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

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

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.