Struct adder_codec_rs::utils::simulproc::SimulProcessor
source · pub struct SimulProcessor<W: Write + 'static> {
pub source: Framed<W>,
/* private fields */
}
Expand description
A struct for simultaneously transcoding a video source to ADΔER and reconstructing a framed video from ADΔER
Fields§
§source: Framed<W>
Framed transcoder hook
Implementations§
source§impl<W: Write + 'static> SimulProcessor<W>
impl<W: Write + 'static> SimulProcessor<W>
sourcepub fn new<T>(
source: Framed<W>,
ref_time: DeltaT,
output_path: &str,
frame_max: i32,
num_threads: usize,
codec_version: u8,
time_mode: TimeMode
) -> Result<SimulProcessor<W>, Box<dyn Error>>where
T: Clone + Sync + Send + 'static + FrameValue + Default + Copy + FrameValue<Output = T> + Serialize + Zero,
pub fn new<T>( source: Framed<W>, ref_time: DeltaT, output_path: &str, frame_max: i32, num_threads: usize, codec_version: u8, time_mode: TimeMode ) -> Result<SimulProcessor<W>, Box<dyn Error>>where T: Clone + Sync + Send + 'static + FrameValue + Default + Copy + FrameValue<Output = T> + Serialize + Zero,
Create a new SimulProcessor
Arguments
source
:Framed<W>
sourceref_time
: ticks per source frameoutput_path
: path to output fileframe_max
: max number of frames to transcodenum_threads
: number of threads to usecodec_version
: codec versiontime_mode
: time mode
returns: Result<SimulProcessor<W>, Box<dyn Error, Global>>
Examples
TODO: add examples
Auto Trait Implementations§
impl<W> !RefUnwindSafe for SimulProcessor<W>
impl<W> Send for SimulProcessor<W>
impl<W> Sync for SimulProcessor<W>
impl<W> Unpin for SimulProcessor<W>where W: Unpin,
impl<W> !UnwindSafe for SimulProcessor<W>
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
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> Pointable for T
impl<T> Pointable for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self
from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self
is actually part of its subset T
(and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset
but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self
to the equivalent element of its superset.