qm-dsp
1.8
|
#include <Chromagram.h>
Public Member Functions | |
Chromagram (ChromaConfig Config) | |
~Chromagram () | |
double * | process (const double *data) |
Process a time-domain input signal of length equal to getFrameSize(). More... | |
double * | process (const double *real, const double *imag) |
Process a frequency-domain input signal generated from a time-domain signal of length equal to getFrameSize() that has been windowed and "fftshifted" to place the zero index in the centre of the frame. More... | |
void | unityNormalise (double *src) |
double | kabs (double real, double imag) |
int | getK () |
int | getFrameSize () |
int | getHopSize () |
Private Member Functions | |
int | initialise (ChromaConfig Config) |
int | deInitialise () |
Private Attributes | |
Window< double > * | m_window |
double * | m_windowbuf |
double * | m_chromadata |
double | m_FMin |
double | m_FMax |
int | m_BPO |
int | m_uK |
MathUtilities::NormaliseType | m_normalise |
int | m_frameSize |
int | m_hopSize |
FFTReal * | m_FFT |
ConstantQ * | m_ConstantQ |
double * | m_FFTRe |
double * | m_FFTIm |
double * | m_CQRe |
double * | m_CQIm |
bool | m_skGenerated |
Detailed Description
Definition at line 31 of file Chromagram.h.
Constructor & Destructor Documentation
Chromagram::Chromagram | ( | ChromaConfig | Config | ) |
Definition at line 22 of file Chromagram.cpp.
References initialise().
Chromagram::~Chromagram | ( | ) |
Definition at line 77 of file Chromagram.cpp.
References deInitialise().
Member Function Documentation
double * Chromagram::process | ( | const double * | data | ) |
Process a time-domain input signal of length equal to getFrameSize().
The returned buffer contains the chromagram values indexed by bin, with the number of values corresponding to the BPO field in the ChromaConfig supplied at construction. It is owned by the Chromagram object and is reused from one process call to the next.
Definition at line 124 of file Chromagram.cpp.
References Window< T >::cut(), FFTReal::forward(), HammingWindow, m_ConstantQ, m_FFT, m_FFTIm, m_FFTRe, m_frameSize, m_skGenerated, m_window, m_windowbuf, and ConstantQ::sparsekernel().
Referenced by GetKeyMode::process().
double * Chromagram::process | ( | const double * | real, |
const double * | imag | ||
) |
Process a frequency-domain input signal generated from a time-domain signal of length equal to getFrameSize() that has been windowed and "fftshifted" to place the zero index in the centre of the frame.
The real and imag buffers must each contain the full getFrameSize() frequency bins.
The returned buffer contains the chromagram values indexed by bin, with the number of values corresponding to the BPO field in the ChromaConfig supplied at construction. It is owned by the Chromagram object and is reused from one process call to the next.
Definition at line 155 of file Chromagram.cpp.
References kabs(), m_BPO, m_chromadata, m_ConstantQ, m_CQIm, m_CQRe, m_normalise, m_skGenerated, m_uK, MathUtilities::normalise(), ConstantQ::process(), and ConstantQ::sparsekernel().
void Chromagram::unityNormalise | ( | double * | src | ) |
Definition at line 110 of file Chromagram.cpp.
References MathUtilities::getFrameMinMax(), and m_BPO.
double Chromagram::kabs | ( | double | real, |
double | imag | ||
) |
Definition at line 102 of file Chromagram.cpp.
Referenced by process().
|
inline |
Definition at line 70 of file Chromagram.h.
|
inline |
Definition at line 71 of file Chromagram.h.
Referenced by GetKeyMode::GetKeyMode().
|
inline |
Definition at line 72 of file Chromagram.h.
|
private |
Definition at line 28 of file Chromagram.cpp.
References ChromaConfig::BPO, CQConfig::BPO, ChromaConfig::CQThresh, CQConfig::CQThresh, ChromaConfig::FS, CQConfig::FS, ConstantQ::getFFTLength(), ConstantQ::getHop(), ConstantQ::getK(), m_BPO, m_chromadata, m_ConstantQ, m_CQIm, m_CQRe, m_FFT, m_FFTIm, m_FFTRe, m_FMax, m_FMin, m_frameSize, m_hopSize, m_normalise, m_uK, m_window, m_windowbuf, ChromaConfig::max, CQConfig::max, ChromaConfig::min, CQConfig::min, and ChromaConfig::normalise.
Referenced by Chromagram().
|
private |
Definition at line 82 of file Chromagram.cpp.
References m_chromadata, m_ConstantQ, m_CQIm, m_CQRe, m_FFT, m_FFTIm, m_FFTRe, m_window, and m_windowbuf.
Referenced by ~Chromagram().
Member Data Documentation
|
private |
Definition at line 78 of file Chromagram.h.
Referenced by deInitialise(), initialise(), and process().
|
private |
Definition at line 79 of file Chromagram.h.
Referenced by deInitialise(), initialise(), and process().
|
private |
Definition at line 81 of file Chromagram.h.
Referenced by deInitialise(), initialise(), and process().
|
private |
Definition at line 82 of file Chromagram.h.
Referenced by initialise().
|
private |
Definition at line 83 of file Chromagram.h.
Referenced by initialise().
|
private |
Definition at line 84 of file Chromagram.h.
Referenced by initialise(), process(), and unityNormalise().
|
private |
Definition at line 85 of file Chromagram.h.
Referenced by initialise(), and process().
|
private |
Definition at line 87 of file Chromagram.h.
Referenced by initialise(), and process().
|
private |
Definition at line 89 of file Chromagram.h.
Referenced by initialise(), and process().
|
private |
Definition at line 90 of file Chromagram.h.
Referenced by initialise().
|
private |
Definition at line 92 of file Chromagram.h.
Referenced by deInitialise(), initialise(), and process().
|
private |
Definition at line 93 of file Chromagram.h.
Referenced by deInitialise(), initialise(), and process().
|
private |
Definition at line 95 of file Chromagram.h.
Referenced by deInitialise(), initialise(), and process().
|
private |
Definition at line 96 of file Chromagram.h.
Referenced by deInitialise(), initialise(), and process().
|
private |
Definition at line 97 of file Chromagram.h.
Referenced by deInitialise(), initialise(), and process().
|
private |
Definition at line 98 of file Chromagram.h.
Referenced by deInitialise(), initialise(), and process().
|
private |
Definition at line 100 of file Chromagram.h.
Referenced by process().
The documentation for this class was generated from the following files:
Generated by 1.8.11