Enum drm_fourcc::DrmFormat[][src]

#[repr(u32)]pub enum DrmFormat {
    Abgr1555,
    Abgr16161616f,
    Abgr2101010,
    Abgr4444,
    Abgr8888,
    Argb1555,
    Argb16161616f,
    Argb2101010,
    Argb4444,
    Argb8888,
    Ayuv,
    Bgr233,
    Bgr565,
    Bgr888,
    Bgra1010102,
    Bgra4444,
    Bgra5551,
    Bgra8888,
    Bgrx1010102,
    Bgrx4444,
    Bgrx5551,
    Bgrx8888,
    C8,
    Gr1616,
    Gr88,
    Nv12,
    Nv16,
    Nv21,
    Nv24,
    Nv42,
    Nv61,
    P010,
    P012,
    P016,
    P210,
    R16,
    R8,
    Rg1616,
    Rg88,
    Rgb332,
    Rgb565,
    Rgb888,
    Rgba1010102,
    Rgba4444,
    Rgba5551,
    Rgba8888,
    Rgbx1010102,
    Rgbx4444,
    Rgbx5551,
    Rgbx8888,
    Uyvy,
    Vuy101010,
    Vuy888,
    Vyuy,
    X0l0,
    X0l2,
    Xbgr1555,
    Xbgr16161616f,
    Xbgr2101010,
    Xbgr4444,
    Xbgr8888,
    Xrgb1555,
    Xrgb16161616f,
    Xrgb2101010,
    Xrgb4444,
    Xrgb8888,
    Xvyu16161616,
    Xvyu2101010,
    Xyuv8888,
    Y0l0,
    Y0l2,
    Y210,
    Y212,
    Y216,
    Y410,
    Y412,
    Y416,
    Yuv410,
    Yuv411,
    Yuv420,
    Yuv422,
    Yuv444,
    Yuyv,
    Yvu410,
    Yvu411,
    Yvu420,
    Yvu422,
    Yvu444,
    Yvyu,
}

Variants

Abgr1555
Abgr16161616f
Abgr2101010
Abgr4444
Abgr8888
Argb1555
Argb16161616f
Argb2101010
Argb4444
Argb8888
Ayuv
Bgr233
Bgr565
Bgr888
Bgra1010102
Bgra4444
Bgra5551
Bgra8888
Bgrx1010102
Bgrx4444
Bgrx5551
Bgrx8888
C8
Gr1616
Gr88
Nv12
Nv16
Nv21
Nv24
Nv42
Nv61
P010
P012
P016
P210
R16
R8
Rg1616
Rg88
Rgb332
Rgb565
Rgb888
Rgba1010102
Rgba4444
Rgba5551
Rgba8888
Rgbx1010102
Rgbx4444
Rgbx5551
Rgbx8888
Uyvy
Vuy101010
Vuy888
Vyuy
X0l0
X0l2
Xbgr1555
Xbgr16161616f
Xbgr2101010
Xbgr4444
Xbgr8888
Xrgb1555
Xrgb16161616f
Xrgb2101010
Xrgb4444
Xrgb8888
Xvyu16161616
Xvyu2101010
Xyuv8888
Y0l0
Y0l2
Y210
Y212
Y216
Y410
Y412
Y416
Yuv410
Yuv411
Yuv420
Yuv422
Yuv444
Yuyv
Yvu410
Yvu411
Yvu420
Yvu422
Yvu444
Yvyu

Implementations

impl DrmFormat[src]

pub fn string_form(&self) -> String[src]

Get the string representation of the format’s fourcc.

Trait Implementations

impl Clone for DrmFormat[src]

impl Copy for DrmFormat[src]

impl Debug for DrmFormat[src]

impl Display for DrmFormat[src]

impl Eq for DrmFormat[src]

impl PartialEq<DrmFormat> for DrmFormat[src]

impl StructuralEq for DrmFormat[src]

impl StructuralPartialEq for DrmFormat[src]

impl TryFrom<u32> for DrmFormat[src]

type Error = UnrecognizedFourcc

The type returned in the event of a conversion error.

fn try_from(value: u32) -> Result<Self, Self::Error>[src]

Convert from an u32

assert_eq!(DrmFormat::try_from(875710274).unwrap(), DrmFormat::Bgr888);

assert!(DrmFormat::try_from(0).is_err());

// If the u32 is in the valid format to be a fourcc, you can see its string form
assert_eq!(DrmFormat::try_from(828601953).unwrap_err().string_form(), Some("avc1".to_string()));

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.