HephAudio v3.1.0
A cross-platform C++ library for recording, playing, and processing audio on Windows, Android, Linux, iOS, and macOS.
|
base class for effects that use overlap-add method. More...
#include <OlaEffect.h>
Public Member Functions | |
virtual | ~OlaEffect ()=default |
virtual size_t | CalculateRequiredFrameCount (size_t outputFrameCount, const AudioFormatInfo &formatInfo) const |
virtual void | ResetInternalState () override |
virtual void | Process (AudioBuffer &buffer, size_t startIndex, size_t frameCount) override |
virtual size_t | GetHopSize () const |
virtual void | SetHopSize (size_t hopSize) |
virtual size_t | GetWindowSize () const |
virtual void | SetWindow (const Window &wnd) |
virtual void | Process (AudioBuffer &buffer) |
virtual void | Process (AudioBuffer &buffer, size_t startIndex) |
Public Member Functions inherited from HephAudio::DoubleBufferedAudioEffect | |
virtual | ~DoubleBufferedAudioEffect ()=default |
Public Member Functions inherited from HephAudio::AudioEffect | |
virtual | ~AudioEffect ()=default |
virtual std::string | Name () const =0 |
virtual bool | HasMTSupport () const |
virtual bool | HasRTSupport () const |
virtual size_t | GetThreadCount () const |
virtual void | SetThreadCount (size_t threadCount) |
virtual size_t | CalculateOutputFrameCount (size_t inputFrameCount, const AudioFormatInfo &formatInfo) const |
virtual size_t | CalculateAdvanceSize (size_t renderFrameCount, const AudioFormatInfo &formatInfo) const |
Protected Member Functions | |
OlaEffect () | |
OlaEffect (size_t hopSize) | |
OlaEffect (size_t hopSize, const Window &wnd) | |
virtual size_t | CalculateMaxNumberOfOverlaps () const |
virtual size_t | CalculatePastSamplesSize () const |
Protected Member Functions inherited from HephAudio::DoubleBufferedAudioEffect | |
DoubleBufferedAudioEffect () | |
virtual AudioBuffer | CreateOutputBuffer (const AudioBuffer &inputBuffer, size_t startIndex, size_t frameCount) const |
virtual void | InitializeOutputBuffer (const AudioBuffer &inputBuffer, AudioBuffer &outputBuffer, size_t startIndex, size_t frameCount) const |
Protected Member Functions inherited from HephAudio::AudioEffect | |
AudioEffect () | |
virtual void | ProcessST (const AudioBuffer &inputBuffer, AudioBuffer &outputBuffer, size_t startIndex, size_t frameCount)=0 |
virtual void | ProcessMT (const AudioBuffer &inputBuffer, AudioBuffer &outputBuffer, size_t startIndex, size_t frameCount) |
Protected Attributes | |
size_t | hopSize |
Heph::DoubleBuffer | wnd |
size_t | currentIndex |
AudioBuffer | pastSamples |
Protected Attributes inherited from HephAudio::AudioEffect | |
size_t | threadCount |
base class for effects that use overlap-add method.
|
protected |
creates a new instance and initializes it with default values.
|
explicitprotected |
creates a new instance and initializes it with the provided values.
hopSize | number of frames to advance each iteration. |
|
protected |
creates a new instance and initializes it with the provided values.
hopSize | number of frames to advance each iteration. |
wnd | window that will be applied for overlap-add. |
|
virtualdefault |
releases the resources and destroys the instance.
|
virtual |
calculates the number of frames required to obtain the number of frames desired for the output buffer.
outputFrameCount | the number of frames desired for the output buffer. |
formatInfo | the format info of the input buffer. |
Reimplemented from HephAudio::AudioEffect.
Reimplemented in HephAudio::TimeStretcher.
|
overridevirtual |
resets the variables internally used for processing.
Reimplemented from HephAudio::AudioEffect.
|
overridevirtual |
Applies the effect.
buffer | contains the audio data which will be processed. |
startIndex | index of the first audio frame to process. |
frameCount | number of frames to process. |
Reimplemented from HephAudio::DoubleBufferedAudioEffect.
Reimplemented in HephAudio::Spatializer.
|
virtual |
gets the hop size.
|
virtual |
sets the hop size.
hopSize | number of frames to advance each iteration. |
|
virtual |
gets the size of the window.
|
virtual |
sets the window.
wnd | window that will be applied for overlap-add. |
Reimplemented in HephAudio::FrequencyDomainEffect, and HephAudio::Spatializer.
|
protectedvirtual |
calculates the maximum number of overlaps
|
protectedvirtual |
calculates the size of the past samples.
|
virtual |
Applies the effect.
buffer | contains the audio data which will be processed. |
Reimplemented from HephAudio::DoubleBufferedAudioEffect.
|
virtual |
Applies the effect.
buffer | contains the audio data which will be processed. |
startIndex | index of the first audio frame to process. |
Reimplemented from HephAudio::DoubleBufferedAudioEffect.
|
protected |
number of frames to advance each iteration.
|
protected |
window that will be applied for overlap-add.
|
protected |
for real-time processing.
|
protected |
past samples for real-time processing.