#[non_exhaustive]pub struct ApiMediaStream {Show 14 fields
pub index: u32,
pub codec_type: String,
pub codec_name: String,
pub bitrate_bps: u64,
pub duration_s: f64,
pub width: u32,
pub height: u32,
pub frames_per_second: f64,
pub rotation: i32,
pub display_aspect_ratio: String,
pub channels: u32,
pub channel_layout: String,
pub sample_rate_s: u64,
pub language_iso_639: String,
}Available on crate features
dbx_riviera and sync_routes only.Expand description
A single audio or video stream within a media file.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.index: u32§codec_type: String“audio”, “video”, etc.
codec_name: String§bitrate_bps: u64§duration_s: f64§width: u32Video-specific fields (zero / empty for audio streams).
height: u32§frames_per_second: f64§rotation: i32§display_aspect_ratio: Stringe.g. “16:9”
channels: u32Audio-specific fields (zero / empty for video streams).
channel_layout: String§sample_rate_s: u64§language_iso_639: StringISO 639 language code for the stream, when present.
Implementations§
Source§impl ApiMediaStream
impl ApiMediaStream
pub fn with_index(self, value: u32) -> Self
pub fn with_codec_type(self, value: String) -> Self
pub fn with_codec_name(self, value: String) -> Self
pub fn with_bitrate_bps(self, value: u64) -> Self
pub fn with_duration_s(self, value: f64) -> Self
pub fn with_width(self, value: u32) -> Self
pub fn with_height(self, value: u32) -> Self
pub fn with_frames_per_second(self, value: f64) -> Self
pub fn with_rotation(self, value: i32) -> Self
pub fn with_display_aspect_ratio(self, value: String) -> Self
pub fn with_channels(self, value: u32) -> Self
pub fn with_channel_layout(self, value: String) -> Self
pub fn with_sample_rate_s(self, value: u64) -> Self
pub fn with_language_iso_639(self, value: String) -> Self
Trait Implementations§
Source§impl Clone for ApiMediaStream
impl Clone for ApiMediaStream
Source§fn clone(&self) -> ApiMediaStream
fn clone(&self) -> ApiMediaStream
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ApiMediaStream
impl Debug for ApiMediaStream
Source§impl Default for ApiMediaStream
impl Default for ApiMediaStream
Source§fn default() -> ApiMediaStream
fn default() -> ApiMediaStream
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ApiMediaStream
impl<'de> Deserialize<'de> for ApiMediaStream
Source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ApiMediaStream
impl PartialEq for ApiMediaStream
Source§impl Serialize for ApiMediaStream
impl Serialize for ApiMediaStream
impl StructuralPartialEq for ApiMediaStream
Auto Trait Implementations§
impl Freeze for ApiMediaStream
impl RefUnwindSafe for ApiMediaStream
impl Send for ApiMediaStream
impl Sync for ApiMediaStream
impl Unpin for ApiMediaStream
impl UnsafeUnpin for ApiMediaStream
impl UnwindSafe for ApiMediaStream
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more