Trait Node

Source
pub trait Node: Sized + Sealed {
    type FrameType: Frame;

    // Required methods
    fn api(&self) -> Api;
    fn as_ptr(&self) -> *mut VSNode;
    fn get_frame_filter(
        &self,
        n: i32,
        ctx: &mut FrameContext,
    ) -> Self::FrameType;

    // Provided methods
    fn set_linear_filter(&mut self) -> i32 { ... }
    fn set_cache_mode(&mut self, mode: CacheMode) { ... }
    fn set_cache_options(
        &mut self,
        fixed_size: i32,
        max_size: i32,
        max_history_size: i32,
    ) { ... }
    fn get_frame(&self, n: i32) -> Result<Self::FrameType, CString> { ... }
    fn get_frame_async<D, F, Fr>(&self, _n: i32, _data: &mut D)
       where F: Fn(D, Fr, i32) -> Result<(), String>,
             Fr: Frame { ... }
}

Required Associated Types§

Required Methods§

Source

fn api(&self) -> Api

Source

fn as_ptr(&self) -> *mut VSNode

Source

fn get_frame_filter(&self, n: i32, ctx: &mut FrameContext) -> Self::FrameType

Provided Methods§

Source

fn set_linear_filter(&mut self) -> i32

Source

fn set_cache_mode(&mut self, mode: CacheMode)

Source

fn set_cache_options( &mut self, fixed_size: i32, max_size: i32, max_history_size: i32, )

Source

fn get_frame(&self, n: i32) -> Result<Self::FrameType, CString>

§Errors

Return the internal error message if the frame is not ready.

Source

fn get_frame_async<D, F, Fr>(&self, _n: i32, _data: &mut D)
where F: Fn(D, Fr, i32) -> Result<(), String>, Fr: Frame,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§