[−][src]Struct ffmpeg_next::software::resampling::context::Context
Implementations
impl Context
[src]
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>
[src]
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.
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>
[src]
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.
pub fn input(&self) -> &Definition
[src]
Get the input definition.
pub fn output(&self) -> &Definition
[src]
Get the output definition.
pub fn delay(&self) -> Option<Delay>
[src]
Get the remaining delay.
pub fn run(
&mut self,
input: &Audio,
output: &mut Audio
) -> Result<Option<Delay>, Error>
[src]
&mut self,
input: &Audio,
output: &mut Audio
) -> Result<Option<Delay>, Error>
Run the resampler from the given input to the given output.
When there are internal frames to process it will return Ok(Some(Delay { .. }))
.
pub fn flush(&mut self, output: &mut Audio) -> Result<Option<Delay>, Error>
[src]
Convert one of the remaining internal frames.
When there are no more internal frames Ok(None)
will be returned.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Context
[src]
impl !Sync for Context
[src]
impl Unpin for Context
[src]
impl UnwindSafe for Context
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,