pub unsafe trait Component {
    // Required method
    fn is_valid(format: VideoFormat) -> bool;
}
Expand description

A trait for possible pixel components.

Safety

Implementing this trait allows retrieving slices of pixel data from the frame for the target type, so the target type must be valid for the given format.

Required Methods§

source

fn is_valid(format: VideoFormat) -> bool

Returns whether this component is valid for this format.

Implementations on Foreign Types§

source§

impl Component for u16

source§

impl Component for u8

source§

impl Component for u32

source§

impl Component for f32

Implementors§