pub struct Context { /* private fields */ }
Implementations§
Source§impl Context
impl Context
Sourcepub fn get(
src_format: Sample,
src_channel_layout: ChannelLayout,
src_rate: u32,
dst_format: Sample,
dst_channel_layout: ChannelLayout,
dst_rate: u32,
) -> Result<Self, Error>
pub fn get( src_format: Sample, src_channel_layout: ChannelLayout, src_rate: u32, dst_format: Sample, dst_channel_layout: ChannelLayout, dst_rate: u32, ) -> Result<Self, Error>
Create a resampler with the given definitions.
Sourcepub fn get_with(
src_format: Sample,
src_channel_layout: ChannelLayout,
src_rate: u32,
dst_format: Sample,
dst_channel_layout: ChannelLayout,
dst_rate: u32,
options: Dictionary<'_>,
) -> Result<Self, Error>
pub fn get_with( src_format: Sample, src_channel_layout: ChannelLayout, src_rate: u32, dst_format: Sample, dst_channel_layout: ChannelLayout, dst_rate: u32, options: Dictionary<'_>, ) -> Result<Self, Error>
Create a resampler with the given definitions and custom options dictionary.
Sourcepub fn input(&self) -> &Definition
pub fn input(&self) -> &Definition
Get the input definition.
Sourcepub fn output(&self) -> &Definition
pub fn output(&self) -> &Definition
Get the output definition.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Context
impl RefUnwindSafe for Context
impl !Sync for Context
impl Unpin for Context
impl UnwindSafe for Context
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