v2.0.0
Loading...
Searching...
No Matches
spectrogram.h
Go to the documentation of this file.
1//=============================================================================================================
27
28#ifndef SPECTROGRAM_H
29#define SPECTROGRAM_H
30
31//=============================================================================================================
32// INCLUDES
33//=============================================================================================================
34
35#include "dsp_global.h"
36
37//=============================================================================================================
38// EIGEN INCLUDES
39//=============================================================================================================
40
41#include <Eigen/Core>
42
43//=============================================================================================================
44// DEFINE NAMESPACE UTILSLIB
45//=============================================================================================================
46
47namespace UTILSLIB
48{
49
54{
55 Eigen::VectorXd vecInputData;
56 quint32 iRangeLow;
57 quint32 iRangeHigh;
59};
60
67{
68public:
69 //=========================================================================================================
78 static Eigen::MatrixXd makeSpectrogram(Eigen::VectorXd signal,
79 qint32 windowSize);
80
81private:
82 //=========================================================================================================
92 static Eigen::VectorXd gaussWindow(qint32 sample_count,
93 qreal scale,
94 quint32 translation);
95
96 //=========================================================================================================
104 static Eigen::MatrixXd compute(const SpectogramInputData& data);
105
106 //=========================================================================================================
113 static void reduce(Eigen::MatrixXd& resultData,
114 const Eigen::MatrixXd& data);
115};
116} //namespace
117
118#endif // SPECTROGRAM_H
Export/import macros and namespace declaration for the DSP library.
#define DSPSHARED_EXPORT
Definition dsp_global.h:50
Shared utilities (I/O helpers, spectral analysis, layout management, warp algorithms).
Input parameters for short-time Fourier transform spectrogram computation.
Definition spectrogram.h:54
Computes time-frequency spectrograms via short-time Fourier transform with configurable window and ov...
Definition spectrogram.h:67
static Eigen::MatrixXd makeSpectrogram(Eigen::VectorXd signal, qint32 windowSize)