#[repr(C)]pub enum VSFilterMode {
Parallel = 0,
ParallelRequests = 1,
Unordered = 2,
FrameState = 3,
}Expand description
Controls how a filter will be multithreaded, if at all.
Variants§
Parallel = 0
Completely parallel execution. Multiple threads will call a filter’s “getFrame” function, to fetch several frames in parallel.
ParallelRequests = 1
For filters that are serial in nature but can request in advance one or more frames
they need. A filter’s “getFrame” function will be called from multiple threads at a time
with activation reason VSActivationReason::Initial,
but only one thread will call it with activation reason
VSActivationReason::AllFramesReady at a time.
Unordered = 2
Only one thread can call the filter’s “getFrame” function at a time. Useful for filters that modify or examine their internal state to determine which frames to request.
While the “getFrame” function will only run in one thread at a time,
the calls can happen in any order. For example, it can be called with reason
VSActivationReason::Initial for frame 0, then again with reason
VSActivationReason::Initial for frame 1,
then with reason VSActivationReason::AllFramesReady for frame 0.
FrameState = 3
For compatibility with other filtering architectures.
DO NOT USE IN NEW FILTERS. The filter’s “getFrame” function only ever gets called from
one thread at a time. Unlike Unordered,
only one frame is processed at a time.
Trait Implementations§
Source§impl Clone for VSFilterMode
impl Clone for VSFilterMode
Source§fn clone(&self) -> VSFilterMode
fn clone(&self) -> VSFilterMode
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for VSFilterMode
Source§impl Debug for VSFilterMode
impl Debug for VSFilterMode
impl Eq for VSFilterMode
Source§impl Hash for VSFilterMode
impl Hash for VSFilterMode
Source§impl Ord for VSFilterMode
impl Ord for VSFilterMode
Source§fn cmp(&self, other: &VSFilterMode) -> Ordering
fn cmp(&self, other: &VSFilterMode) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for VSFilterMode
impl PartialEq for VSFilterMode
Source§fn eq(&self, other: &VSFilterMode) -> bool
fn eq(&self, other: &VSFilterMode) -> bool
self and other values to be equal, and is used by ==.