![]() |
Audacity 3.2.0
|
#include <SpectrumCache.h>
Public Member Functions | |
SpecCache () | |
~SpecCache () | |
bool | Matches (int dirty_, double pixelsPerSecond, const SpectrogramSettings &settings, double rate) const |
bool | CalculateOneSpectrum (const SpectrogramSettings &settings, SampleTrackCache &waveTrackCache, const int xx, sampleCount numSamples, double offset, double rate, double pixelsPerSecond, int lowerBoundX, int upperBoundX, const std::vector< float > &gainFactors, float *__restrict scratch, float *__restrict out) const |
void | Grow (size_t len_, SpectrogramSettings &settings, double pixelsPerSecond, double start_) |
void | Populate (const SpectrogramSettings &settings, SampleTrackCache &waveTrackCache, int copyBegin, int copyEnd, size_t numPixels, sampleCount numSamples, double offset, double rate, double pixelsPerSecond) |
Public Attributes | |
size_t | len { 0 } |
int | algorithm |
double | pps |
double | leftTrim { .0 } |
double | rightTrim { .0 } |
double | start |
int | windowType |
size_t | windowSize { 0 } |
unsigned | zeroPaddingFactor { 0 } |
int | frequencyGain |
std::vector< float > | freq |
std::vector< sampleCount > | where |
int | dirty |
Definition at line 24 of file SpectrumCache.h.
|
inline |
Definition at line 28 of file SpectrumCache.h.
|
inline |
Definition at line 38 of file SpectrumCache.h.
bool SpecCache::CalculateOneSpectrum | ( | const SpectrogramSettings & | settings, |
SampleTrackCache & | waveTrackCache, | ||
const int | xx, | ||
sampleCount | numSamples, | ||
double | offset, | ||
double | rate, | ||
double | pixelsPerSecond, | ||
int | lowerBoundX, | ||
int | upperBoundX, | ||
const std::vector< float > & | gainFactors, | ||
float *__restrict | scratch, | ||
float *__restrict | out | ||
) | const |
Definition at line 97 of file SpectrumCache.cpp.
References SpectrogramSettings::algPitchEAC, SpectrogramSettings::algReassignment, sampleCount::as_double(), sampleCount::as_long_long(), ComputeSpectrum(), anonymous_namespace{SpectrumCache.cpp}::ComputeSpectrumUsingRealFFTf(), SampleTrackCache::GetFloats(), len, M_PI, fast_float::detail::power(), RealFFTf(), settings(), and where.
Referenced by Populate().
void SpecCache::Grow | ( | size_t | len_, |
SpectrogramSettings & | settings, | ||
double | pixelsPerSecond, | ||
double | start_ | ||
) |
Definition at line 321 of file SpectrumCache.cpp.
References algorithm, freq, frequencyGain, len, pps, settings(), start, where, windowSize, windowType, and zeroPaddingFactor.
Referenced by anonymous_namespace{SpectrumView.cpp}::DrawClipSpectrum().
bool SpecCache::Matches | ( | int | dirty_, |
double | pixelsPerSecond, | ||
const SpectrogramSettings & | settings, | ||
double | rate | ||
) | const |
Definition at line 76 of file SpectrumCache.cpp.
References algorithm, dirty, frequencyGain, len, pps, settings(), windowSize, windowType, and zeroPaddingFactor.
void SpecCache::Populate | ( | const SpectrogramSettings & | settings, |
SampleTrackCache & | waveTrackCache, | ||
int | copyBegin, | ||
int | copyEnd, | ||
size_t | numPixels, | ||
sampleCount | numSamples, | ||
double | offset, | ||
double | rate, | ||
double | pixelsPerSecond | ||
) |
Definition at line 344 of file SpectrumCache.cpp.
References SpectrogramSettings::algPitchEAC, SpectrogramSettings::algReassignment, CalculateOneSpectrum(), anonymous_namespace{SpectrumCache.cpp}::ComputeSpectrogramGainFactors(), freq, SampleTrackCache::GetTrack(), min(), fast_float::detail::power(), and settings().
Referenced by anonymous_namespace{SpectrumView.cpp}::DrawClipSpectrum().
int SpecCache::algorithm |
Definition at line 68 of file SpectrumCache.h.
int SpecCache::dirty |
Definition at line 80 of file SpectrumCache.h.
Referenced by Matches().
std::vector<float> SpecCache::freq |
Definition at line 77 of file SpectrumCache.h.
Referenced by anonymous_namespace{SpectrumView.cpp}::DrawClipSpectrum(), Grow(), and Populate().
int SpecCache::frequencyGain |
Definition at line 76 of file SpectrumCache.h.
double SpecCache::leftTrim { .0 } |
Definition at line 70 of file SpectrumCache.h.
size_t SpecCache::len { 0 } |
Definition at line 67 of file SpectrumCache.h.
Referenced by CalculateOneSpectrum(), Grow(), and Matches().
double SpecCache::pps |
Definition at line 69 of file SpectrumCache.h.
double SpecCache::rightTrim { .0 } |
Definition at line 71 of file SpectrumCache.h.
double SpecCache::start |
Definition at line 72 of file SpectrumCache.h.
Referenced by Grow().
std::vector<sampleCount> SpecCache::where |
Definition at line 78 of file SpectrumCache.h.
Referenced by CalculateOneSpectrum(), anonymous_namespace{SpectrumView.cpp}::DrawClipSpectrum(), and Grow().
size_t SpecCache::windowSize { 0 } |
Definition at line 74 of file SpectrumCache.h.
int SpecCache::windowType |
Definition at line 73 of file SpectrumCache.h.
unsigned SpecCache::zeroPaddingFactor { 0 } |
Definition at line 75 of file SpectrumCache.h.