pub struct SourceFormat {
pub canvas: Canvas,
pub framerate: Rational,
pub time_base: TimeBase,
pub sample_rate: u32,
pub duration: SceneDuration,
}Expand description
Format contract between a SceneSource and a SceneSink.
Everything a sink needs to set up encoders / muxers / windows before the first frame arrives.
Fields§
§canvas: Canvas§framerate: Rational§time_base: TimeBase§sample_rate: u32§duration: SceneDurationWhether the source has a known end. Finite(n) lets sinks
size output containers; Indefinite signals a streaming
source that runs until externally stopped.
Implementations§
Source§impl SourceFormat
impl SourceFormat
Sourcepub fn from_scene(scene: &Scene) -> Self
pub fn from_scene(scene: &Scene) -> Self
Build from a scene’s current state. The renderer consumes
this at init() time so downstream encoder settings match
the scene’s declarations.
Trait Implementations§
Source§impl Clone for SourceFormat
impl Clone for SourceFormat
Source§fn clone(&self) -> SourceFormat
fn clone(&self) -> SourceFormat
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for SourceFormat
impl RefUnwindSafe for SourceFormat
impl Send for SourceFormat
impl Sync for SourceFormat
impl Unpin for SourceFormat
impl UnsafeUnpin for SourceFormat
impl UnwindSafe for SourceFormat
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