Enum cogl::FrameEvent[][src]

#[non_exhaustive]
pub enum FrameEvent {
    Sync,
    Complete,
    // some variants omitted
}

Identifiers that are passed to CoglFrameCallback functions (registered using Onscreen::add_frame_callback) that mark the progression of a frame in some way which usually means that new information will have been accumulated in the frame’s corresponding FrameInfo object.

The last event that will be sent for a frame will be a FrameEvent::Complete event and so these are a good opportunity to collect statistics about a frame since the FrameInfo should hold the most data at this point.

<note>A frame may not be completed before the next frame can start so applications should avoid needing to collect all statistics for a particular frame before they can start a new frame.</note>

Variants (Non-exhaustive)

Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Sync

Notifies that the system compositor has acknowledged a frame and is ready for a new frame to be created.

Complete

Notifies that a frame has ended. This is a good time for applications to collect statistics about the frame since the FrameInfo should hold the most data at this point. No other events should be expected after a FrameEvent::Complete event.

Trait Implementations

impl Clone for FrameEvent[src]

impl Copy for FrameEvent[src]

impl Debug for FrameEvent[src]

impl Display for FrameEvent[src]

impl Eq for FrameEvent[src]

impl Hash for FrameEvent[src]

impl Ord for FrameEvent[src]

impl PartialEq<FrameEvent> for FrameEvent[src]

impl PartialOrd<FrameEvent> for FrameEvent[src]

impl StructuralEq for FrameEvent[src]

impl StructuralPartialEq for FrameEvent[src]

Auto Trait Implementations

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> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[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.