#include <SMSPitchShift.hxx>
In order to preserve timbre, the original spectral shape is extracted and then applied back.
Definition at line 47 of file SMSPitchShift.hxx.
Public Member Functions | |
SMSPitchShift () | |
~SMSPitchShift () | |
bool | ConcreteConfigure (const ProcessingConfig &config) |
Configuration method interface. | |
bool | Do (const SpectralPeakArray &inPeaks, const Fundamental &inFund, const Spectrum &inRes, SpectralPeakArray &outPeaks, Fundamental &outFund, Spectrum &outRes) |
bool | Do (const Frame &in, Frame &out) |
bool | Do () |
Supervised mode execution method (using ports). | |
Public Attributes | |
InControl | mIgnoreResidual |
In some cases, such as in the harmonizer it makes sense to ignore the residual spectrum in order to keep things manageable. |
CLAM::SMSPitchShift::SMSPitchShift | ( | ) | [inline] |
CLAM::SMSPitchShift::~SMSPitchShift | ( | ) | [inline] |
Definition at line 76 of file SMSPitchShift.hxx.
bool CLAM::SMSPitchShift::ConcreteConfigure | ( | const ProcessingConfig & | ) | [inline, virtual] |
Configuration method interface.
The Processing base class forces all the concrete classes derived from it to implement this method, which must actually perform the specific configuration tasks.
Note that the user can not call this method directly. He will use Configure instead. The argument is expected to be an object of the necesary concrete configuration class.
Reference | to the configuration object. |
This | method must throw a bad_cast exception if the argument is not an object of the expected configuration class. |
Reimplemented from CLAM::Processing.
Definition at line 78 of file SMSPitchShift.hxx.
References CLAM::InControl::DoControl(), mIgnoreResidual, CLAM::InControl::SetBounds(), and CLAM::InControl::SetDefaultValue().
bool CLAM::SMSPitchShift::Do | ( | const SpectralPeakArray & | inPeaks, | |
const Fundamental & | inFund, | |||
const Spectrum & | inRes, | |||
SpectralPeakArray & | outPeaks, | |||
Fundamental & | outFund, | |||
Spectrum & | outRes | |||
) |
Definition at line 40 of file SMSPitchShift.cxx.
References CLAM::FDCombFilter::Do(), CLAM::SpectralEnvelopeApply::Do(), CLAM::SpectralEnvelopeExtract::Do(), CLAM::InControl::DoControl(), CLAM::Fundamental::GetFreq(), CLAM::InControl::GetLastValue(), CLAM::Fundamental::GetnCandidates(), CLAM::SpectralPeakArray::GetnPeaks(), CLAM::FrameTransformation::mConfig, CLAM::FDCombFilter::mFreq, mIgnoreResidual, CLAM::Fundamental::SetFreq(), and CLAM::SpectralPeakArray::SetnPeaks().
Referenced by CLAM::SMSPitchDiscretization::Do(), CLAM::SMSHarmonizer::Do(), CLAM::SMSGenderChange::Do(), and CLAM::SegmentSMSHarmonizer::Do().
Implements CLAM::FrameTransformation.
Definition at line 111 of file SMSPitchShift.cxx.
References Do().
bool CLAM::SMSPitchShift::Do | ( | ) | [inline, virtual] |
Supervised mode execution method (using ports).
Implements CLAM::Processing.
Definition at line 99 of file SMSPitchShift.hxx.
Referenced by Do().
In some cases, such as in the harmonizer it makes sense to ignore the residual spectrum in order to keep things manageable.
This should if fact be a configuration param, but we don't want to introduce specific params that prevent us from using the generic one
Definition at line 128 of file SMSPitchShift.hxx.
Referenced by ConcreteConfigure(), Do(), CLAM::SMSHarmonizer::IgnoreResidual(), and CLAM::SegmentSMSHarmonizer::IgnoreResidual().