A class for managing and processing audio blocks with overlap and hop sizes.
More...
#include <Splicer.hpp>
|
| | Splicer (Eigen::Index newBlockSize, Eigen::Index newHopSize) |
| | Constructor sets the block size and hop size for the splicer.
|
| void | pushBlock (const Eigen::ArrayXd &block) |
| | Pushes a new audio block into the buffer.
|
| double | getSample () |
| | Retrieves the next sample from the buffer.
|
| Eigen::Index | getBlockSize () const |
| | Gets the current block size.
|
| Eigen::Index | getOverlapSize () const |
| | Gets the current overlap size.
|
| Eigen::Index | getHopSize () const |
| | Gets the current hop size.
|
| Eigen::Index | getBufferSize () const |
| | Gets the current buffer size.
|
A class for managing and processing audio blocks with overlap and hop sizes.
The Splicer class provides functionality to set block sizes, push audio blocks into a buffer, and retrieve individual samples while maintaining overlap and hop size constraints.
◆ Splicer()
| Splicer::Splicer |
( |
Eigen::Index | newBlockSize, |
|
|
Eigen::Index | newHopSize ) |
Constructor sets the block size and hop size for the splicer.
Degenerate sizes are clamped to safe minimums (blockSize >= 1, 1 <= hopSize <= blockSize) instead of asserted, so owners may construct a Splicer from an invalid configuration (see NsgfCqtCommon::isValid()); such an instance is safe to hold but splices only silence.
- Parameters
-
| newBlockSize | The size of the audio block. |
| newHopSize | The hop size (step size) between consecutive blocks. |
◆ getBlockSize()
| Eigen::Index jsa::cicuetea::Splicer::getBlockSize |
( |
| ) |
const |
|
inline |
Gets the current block size.
- Returns
- The size of the audio block.
◆ getBufferSize()
| Eigen::Index jsa::cicuetea::Splicer::getBufferSize |
( |
| ) |
const |
|
inline |
Gets the current buffer size.
- Returns
- The size of the internal buffer.
◆ getHopSize()
| Eigen::Index jsa::cicuetea::Splicer::getHopSize |
( |
| ) |
const |
|
inline |
Gets the current hop size.
- Returns
- The hop size (step size) between consecutive blocks.
◆ getOverlapSize()
| Eigen::Index jsa::cicuetea::Splicer::getOverlapSize |
( |
| ) |
const |
|
inline |
Gets the current overlap size.
- Returns
- The size of the overlap between consecutive blocks.
◆ getSample()
| double Splicer::getSample |
( |
| ) |
|
Retrieves the next sample from the buffer.
- Returns
- A double representing the next audio sample.
◆ pushBlock()
| void Splicer::pushBlock |
( |
const Eigen::ArrayXd & | block | ) |
|
Pushes a new audio block into the buffer.
- Parameters
-
| block | An Eigen array representing the audio block to be added. |
The documentation for this class was generated from the following files:
- /home/runner/work/CiCueTea/CiCueTea/Include/Splicer.hpp
- /home/runner/work/CiCueTea/CiCueTea/Source/Splicer.cpp