#include <OverlapAdd.hxx>
HopSize configures the write size of the circular buffer (note that the write size is here understood as the portion of the frame that is overwritten, not added). FrameSize configures the read size of the circular buffer. BufferSize configures the overall physical size of the circular buffer. Currently, HopSize must be hop size, FrameSize must be hop size and BufferSize must be twice hop size (as it will do 50% overlap). OverlapAdd Processing class. First half of the input buffer or audio (which is of buffer size) is added to existing data in the circular buffer (ie. 'mixed in'), second half overwrites existing data. When reading, only already overlapped regions should be given as output (this overlapped region and thus the output will be of frame size).
Definition at line 63 of file OverlapAdd.hxx.
Public Member Functions | |
OverlapAdd (const OverlapAddConfig &c=OverlapAddConfig()) | |
~OverlapAdd () | |
const ProcessingConfig & | GetConfig () const |
Configuration getter. | |
bool | Do (void) |
Unsupervised Do method, not implemented. | |
bool | Do (const Audio &in, Audio &out) |
Do method. | |
Protected Attributes | |
OverlapAddConfig | mConfig |
AudioInPort | mInput |
AudioOutPort | mOutput |
Audio | mTmp |
CLAM::OverlapAdd::OverlapAdd | ( | const OverlapAddConfig & | c = OverlapAddConfig() |
) |
CLAM::OverlapAdd::~OverlapAdd | ( | ) |
Definition at line 48 of file OverlapAdd.cxx.
const ProcessingConfig& CLAM::OverlapAdd::GetConfig | ( | ) | const [inline, virtual] |
Configuration getter.
Gets the configuration parameters used to create the object.
Reimplemented from CLAM::Processing.
Definition at line 69 of file OverlapAdd.hxx.
References mConfig.
bool CLAM::OverlapAdd::Do | ( | void | ) | [virtual] |
Unsupervised Do method, not implemented.
Implements CLAM::Processing.
Definition at line 78 of file OverlapAdd.cxx.
References CLAM::InPort< Token >::Consume(), CLAM::AudioOutPort::GetAudio(), CLAM::AudioInPort::GetAudio(), mInput, mOutput, and CLAM::OutPort< Token >::Produce().
Referenced by CLAM::SMSSynthesis::Do(), CLAM::SinusoidalSynthesis::Do(), and CLAM::SMSSynthesis::SinusoidalSynthesis().
Do method.
in,: | input Audio (size must be buffer size). | |
out,: | output Audio (size must be frame size). |
Definition at line 86 of file OverlapAdd.cxx.
References CLAM_DEBUG_ASSERT, CLAM::Audio::GetSize(), mConfig, and mTmp.
OverlapAddConfig CLAM::OverlapAdd::mConfig [protected] |
AudioInPort CLAM::OverlapAdd::mInput [protected] |
AudioOutPort CLAM::OverlapAdd::mOutput [protected] |
Audio CLAM::OverlapAdd::mTmp [protected] |