pub struct Stft<S: SpectralStage> { /* private fields */ }Expand description
STFT processor implementing the DspStage contract.
Accepts arbitrary input block sizes, buffers in an input FIFO,
processes one hop at a time with a SLIDING analysis frame (each hop
consumes hop_len new samples and re-uses the previous half — the
overlap in “weighted overlap-add”), and emits exactly as many output
samples as arrived. sqrt-Hann is applied on analysis and synthesis;
with the periodic window at 50% overlap the squared windows sum to
exactly 1 (COLA), so an identity spectral stage reconstructs the
input delayed by one window length.
Implementations§
Trait Implementations§
Source§impl<S: SpectralStage> DspStage for Stft<S>
impl<S: SpectralStage> DspStage for Stft<S>
Source§fn latency_samples(&self) -> usize
fn latency_samples(&self) -> usize
Group delay this stage introduces, in samples at the bus rate
(lookahead, filter delay, block buffering). Default 0.
Auto Trait Implementations§
impl<S> Freeze for Stft<S>where
S: Freeze,
impl<S> !RefUnwindSafe for Stft<S>
impl<S> Send for Stft<S>
impl<S> Sync for Stft<S>where
S: Sync,
impl<S> Unpin for Stft<S>where
S: Unpin,
impl<S> !UnwindSafe for Stft<S>
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<S> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Applies the layer to a service and wraps it in [
Layered].