pub struct AecSession { /* private fields */ }Implementations§
Source§impl AecSession
impl AecSession
pub fn new(cfg: AecConfig) -> Result<AecSession, Error>
pub fn with_residual_weights( cfg: AecConfig, weights: ResidualWeights, ) -> Result<AecSession, Error>
pub fn reset(&mut self)
pub fn delay_samples(&self) -> usize
Sourcepub fn push_reference(&mut self, far_end: &[f32])
pub fn push_reference(&mut self, far_end: &[f32])
Push far-end reference (e.g. TTS playback tap) without mic input.
Sourcepub fn process(
&mut self,
mic: &[f32],
far_end: &[f32],
) -> Result<Vec<f32>, Error>
pub fn process( &mut self, mic: &[f32], far_end: &[f32], ) -> Result<Vec<f32>, Error>
Process mic + synchronous far-end chunk.
Sourcepub fn process_mic(&mut self, mic: &[f32]) -> Result<Option<Vec<f32>>, Error>
pub fn process_mic(&mut self, mic: &[f32]) -> Result<Option<Vec<f32>>, Error>
Process mic using buffered reference ring.
Auto Trait Implementations§
impl Freeze for AecSession
impl RefUnwindSafe for AecSession
impl Send for AecSession
impl Sync for AecSession
impl Unpin for AecSession
impl UnsafeUnpin for AecSession
impl UnwindSafe for AecSession
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more