ASPiK SDK
|
The PSMVocoder object implements a phase vocoder pitch shifter. Phase locking and peak tracking are optional. More...
#include <fxobjects.h>
Public Member Functions | |
virtual bool | reset (double _sampleRate) |
virtual bool | canProcessAudioFrame () |
void | setPitchShift (double semitones) |
int | findPreviousNearestPeak (int peakIndex) |
void | findPeaksAndRegionsOfInfluence () |
virtual double | processAudioSample (double input) |
PSMVocoderParameters | getParameters () |
void | setParameters (const PSMVocoderParameters ¶ms) |
virtual bool | reset (double _sampleRate) |
virtual bool | canProcessAudioFrame () |
void | setPitchShift (double semitones) |
int | findPreviousNearestPeak (int peakIndex) |
void | findPeaksAndRegionsOfInfluence () |
virtual double | processAudioSample (double input) |
PSMVocoderParameters | getParameters () |
void | setParameters (const PSMVocoderParameters ¶ms) |
virtual bool | reset (double _sampleRate) |
virtual bool | canProcessAudioFrame () |
void | setPitchShift (double semitones) |
int | findPreviousNearestPeak (int peakIndex) |
void | findPeaksAndRegionsOfInfluence () |
virtual double | processAudioSample (double input) |
PSMVocoderParameters | getParameters () |
void | setParameters (const PSMVocoderParameters ¶ms) |
virtual bool | reset (double _sampleRate) |
virtual bool | canProcessAudioFrame () |
void | setPitchShift (double semitones) |
int | findPreviousNearestPeak (int peakIndex) |
void | findPeaksAndRegionsOfInfluence () |
virtual double | processAudioSample (double input) |
PSMVocoderParameters | getParameters () |
void | setParameters (const PSMVocoderParameters ¶ms) |
![]() | |
virtual void | setSampleRate (double _sampleRate) |
virtual void | enableAuxInput (bool enableAuxInput) |
virtual double | processAuxInputAudioSample (double xn) |
virtual bool | processAudioFrame (const float *inputFrame, float *outputFrame, uint32_t inputChannels, uint32_t outputChannels) |
virtual void | setSampleRate (double _sampleRate) |
virtual void | enableAuxInput (bool enableAuxInput) |
virtual double | processAuxInputAudioSample (double xn) |
virtual bool | processAudioFrame (const float *inputFrame, float *outputFrame, uint32_t inputChannels, uint32_t outputChannels) |
virtual void | setSampleRate (double _sampleRate) |
virtual void | enableAuxInput (bool enableAuxInput) |
virtual double | processAuxInputAudioSample (double xn) |
virtual bool | processAudioFrame (const float *inputFrame, float *outputFrame, uint32_t inputChannels, uint32_t outputChannels) |
virtual void | setSampleRate (double _sampleRate) |
virtual void | enableAuxInput (bool enableAuxInput) |
virtual double | processAuxInputAudioSample (double xn) |
virtual bool | processAudioFrame (const float *inputFrame, float *outputFrame, uint32_t inputChannels, uint32_t outputChannels) |
Protected Attributes | |
PSMVocoderParameters | parameters |
object parameters | |
PhaseVocoder | vocoder |
vocoder to perform PSM | |
double | alphaStretchRatio = 1.0 |
alpha stretch ratio = hs/ha | |
const double | hs = PSM_FFT_LEN / 4 |
hs = N/4 — 75% overlap | |
double | ha = PSM_FFT_LEN / 4 |
ha = N/4 — 75% overlap | |
double | phi [PSM_FFT_LEN] = { 0.0 } |
array of phase values for classic algorithm | |
double | psi [PSM_FFT_LEN] = { 0.0 } |
array of phase correction values for classic algorithm | |
BinData | binData [PSM_FFT_LEN] |
array of BinData structures for current FFT frame | |
BinData | binDataPrevious [PSM_FFT_LEN] |
array of BinData structures for previous FFT frame | |
int | peakBins [PSM_FFT_LEN] = { -1 } |
array of current peak bin index values (-1 = not peak) | |
int | peakBinsPrevious [PSM_FFT_LEN] = { -1 } |
array of previous peak bin index values (-1 = not peak) | |
double * | windowBuff = nullptr |
buffer for window | |
double * | outputBuff = nullptr |
buffer for resampled output | |
double | windowCorrection = 0.0 |
window correction value | |
unsigned int | outputBufferLength = 0 |
lenght of resampled output array | |
The PSMVocoder object implements a phase vocoder pitch shifter. Phase locking and peak tracking are optional.
Audio I/O:
Control I/F:
|
inlinevirtual |
return false: this object only processes samples
Implements IAudioSignalProcessor.
|
inlinevirtual |
return false: this object only processes samples
Implements IAudioSignalProcessor.
|
inlinevirtual |
return false: this object only processes samples
Implements IAudioSignalProcessor.
|
inlinevirtual |
return false: this object only processes samples
Implements IAudioSignalProcessor.
|
inline |
identify peak bins and tag their respective regions of influence
|
inline |
identify peak bins and tag their respective regions of influence
|
inline |
identify peak bins and tag their respective regions of influence
|
inline |
identify peak bins and tag their respective regions of influence
|
inline |
find bin index of nearest peak bin in previous FFT frame
|
inline |
find bin index of nearest peak bin in previous FFT frame
|
inline |
find bin index of nearest peak bin in previous FFT frame
|
inline |
find bin index of nearest peak bin in previous FFT frame
|
inline |
get parameters: note use of custom structure for passing param data
|
inline |
get parameters: note use of custom structure for passing param data
|
inline |
get parameters: note use of custom structure for passing param data
|
inline |
get parameters: note use of custom structure for passing param data
|
inlinevirtual |
process input sample through PSM vocoder
xn | input |
Implements IAudioSignalProcessor.
|
inlinevirtual |
process input sample through PSM vocoder
xn | input |
Implements IAudioSignalProcessor.
|
inlinevirtual |
process input sample through PSM vocoder
xn | input |
Implements IAudioSignalProcessor.
|
inlinevirtual |
process input sample through PSM vocoder
xn | input |
Implements IAudioSignalProcessor.
|
inlinevirtual |
reset members to initialized state
Implements IAudioSignalProcessor.
|
inlinevirtual |
reset members to initialized state
Implements IAudioSignalProcessor.
|
inlinevirtual |
reset members to initialized state
Implements IAudioSignalProcessor.
|
inlinevirtual |
reset members to initialized state
Implements IAudioSignalProcessor.
|
inline |
set parameters: note use of custom structure for passing param data
PSMVocoderParameters | custom data structure |
|
inline |
set parameters: note use of custom structure for passing param data
PSMVocoderParameters | custom data structure |
|
inline |
set parameters: note use of custom structure for passing param data
PSMVocoderParameters | custom data structure |
|
inline |
set parameters: note use of custom structure for passing param data
PSMVocoderParameters | custom data structure |
|
inline |
set the pitch shift in semitones (note that this can be fractional too)
|
inline |
set the pitch shift in semitones (note that this can be fractional too)
|
inline |
set the pitch shift in semitones (note that this can be fractional too)
|
inline |
set the pitch shift in semitones (note that this can be fractional too)