Trait gstreamer::prelude::BufferPoolExt[][src]

pub trait BufferPoolExt: 'static {
    fn options(&self) -> Vec<GString>;
fn has_option(&self, option: &str) -> bool;
fn is_active(&self) -> bool;
fn set_active(&self, active: bool) -> Result<(), BoolError>;
fn set_flushing(&self, flushing: bool); }

Trait containing all BufferPool methods.

Implementors

crate::BufferPool

Required methods

fn options(&self) -> Vec<GString>[src]

Get a None terminated array of string with supported bufferpool options for self. An option would typically be enabled with [crate::BufferPool::config_add_option()].

Returns

a None terminated array of strings.

fn has_option(&self, option: &str) -> bool[src]

Check if the bufferpool supports option.

option

an option

Returns

true if the buffer pool contains option.

fn is_active(&self) -> bool[src]

Check if self is active. A pool can be activated with the Self::set_active() call.

Returns

true when the pool is active.

fn set_active(&self, active: bool) -> Result<(), BoolError>[src]

Control the active state of self. When the pool is inactive, new calls to [crate::BufferPool::acquire_buffer()] will return with crate::FlowReturn::Flushing.

Activating the bufferpool will preallocate all resources in the pool based on the configuration of the pool.

Deactivating will free the resources again when there are no outstanding buffers. When there are outstanding buffers, they will be freed as soon as they are all returned to the pool.

active

the new active state

Returns

false when the pool was not configured or when preallocation of the buffers failed.

fn set_flushing(&self, flushing: bool)[src]

Enable or disable the flushing state of a self without freeing or allocating buffers.

flushing

whether to start or stop flushing

Loading content...

Implementors

impl<O: IsA<BufferPool>> BufferPoolExt for O[src]

fn options(&self) -> Vec<GString>[src]

fn has_option(&self, option: &str) -> bool[src]

fn is_active(&self) -> bool[src]

fn set_active(&self, active: bool) -> Result<(), BoolError>[src]

fn set_flushing(&self, flushing: bool)[src]

Loading content...