pub struct FormatProperties(pub spa_format);

Tuple Fields§

§0: spa_format

Implementations§

source§

impl FormatProperties

source

pub const MediaType: Self = _

media type (Id enum spa_media_type)

source

pub const MediaSubtype: Self = _

media subtype (Id enum spa_media_subtype)

source

pub const AudioFormat: Self = _

audio format, (Id enum spa_audio_format)

source

pub const AudioFlags: Self = _

optional flags (Int)

source

pub const AudioRate: Self = _

sample rate (Int)

source

pub const AudioChannels: Self = _

number of audio channels (Int)

source

pub const AudioPosition: Self = _

channel positions (Id enum spa_audio_position)

source

pub const AudioIec958Codec: Self = _

codec used (IEC958) (Id enum spa_audio_iec958_codec)

source

pub const AudioBitorder: Self = _

bit order (Id enum spa_param_bitorder)

source

pub const AudioInterleave: Self = _

Interleave bytes (Int)

source

pub const VideoFormat: Self = _

video format (Id enum spa_video_format)

source

pub const VideoModifier: Self = _

format modifier (Long), use only with DMA-BUF and omit for other buffer types

source

pub const VideoSize: Self = _

size (Rectangle)

source

pub const VideoFramerate: Self = _

frame rate (Fraction)

source

pub const VideoMaxFramerate: Self = _

maximum frame rate (Fraction)

source

pub const VideoViews: Self = _

number of views (Int)

source

pub const VideoInterlaceMode: Self = _

(Id enum spa_video_interlace_mode)

source

pub const VideoPixelAspectRatio: Self = _

(Rectangle)

source

pub const VideoMultiviewMode: Self = _

(Id enum spa_video_multiview_mode)

source

pub const VideoMultiviewFlags: Self = _

(Id enum spa_video_multiview_flags)

source

pub const VideoChromaSite: Self = _

/Id enum spa_video_chroma_site)

source

pub const VideoColorRange: Self = _

/Id enum spa_video_color_range)

source

pub const VideoColorMatrix: Self = _

/Id enum spa_video_color_matrix)

source

pub const VideoTransferFunction: Self = _

/Id enum spa_video_transfer_function)

source

pub const VideoColorPrimaries: Self = _

/Id enum spa_video_color_primaries)

source

pub const VideoProfile: Self = _

(Int)

source

pub const VideoLevel: Self = _

(Int)

source

pub const VideoH264StreamFormat: Self = _

(Id enum spa_h264_stream_format)

source

pub const VideoH264Alignment: Self = _

(Id enum spa_h264_alignment)

source

pub fn is_audio(&self) -> bool

source

pub fn is_video(&self) -> bool

source

pub fn is_image(&self) -> bool

source

pub fn is_binary(&self) -> bool

source

pub fn is_stream(&self) -> bool

source

pub fn is_application(&self) -> bool

source

pub fn from_raw(raw: spa_format) -> Self

Obtain a FormatProperties from a raw spa_format variant.

source

pub fn as_raw(&self) -> spa_format

Get the raw spa_sys::spa_format representing this FormatProperties.

Trait Implementations§

source§

impl Clone for FormatProperties

source§

fn clone(&self) -> FormatProperties

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for FormatProperties

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl PartialEq for FormatProperties

source§

fn eq(&self, other: &FormatProperties) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialOrd for FormatProperties

source§

fn partial_cmp(&self, other: &FormatProperties) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl Copy for FormatProperties

source§

impl Eq for FormatProperties

source§

impl StructuralPartialEq for FormatProperties

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.