pub struct AudioResampler { /* private fields */ }
Expand description

Audio resampler.

Resampler operation

  1. Push an audio frame to the resampler.
  2. Take all frames from the resampler until you get None.
  3. If there are more frames to be resampled, continue with 1.
  4. Flush the resampler.
  5. Take all frames from the resampler until you get None.

Timestamps of the output frames will be in 1 / target_sample_rate time base.

Implementations§

Get a builder for the audio resampler.

Push a given frame to the resampler.

Panics

The method panics if the operation is not expected (i.e. another operation needs to be done).

Push a given frame to the resampler.

Flush the resampler.

Panics

The method panics if the operation is not expected (i.e. another operation needs to be done).

Flush the resampler.

Take a frame from the resampler (if available).

Trait Implementations§

Executes the destructor for this type. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.