|
LMMS
|
Receives audio data, runs FFT analysis and stores the result. More...
#include <SaProcessor.h>
Public Attributes | |
| QMutex | m_reallocationAccess |
| QMutex | m_dataAccess |
Private Member Functions | |
| QRgb | makePixel (float left, float right) const |
Private Attributes | |
| const SaControls * | m_controls |
| bool | m_terminate |
| unsigned int | m_zeroPadFactor = 2 |
| use n-steps bigger FFT for given block size | |
| std::atomic< unsigned int > | m_inBlockSize |
| size of input (time domain) data block | |
| unsigned int | m_fftBlockSize |
| size of padded block for FFT processing | |
| unsigned int | m_sampleRate |
| unsigned int | m_framesFilledUp |
| std::vector< float > | m_bufferL |
| time domain samples (left) | |
| std::vector< float > | m_bufferR |
| time domain samples (right) | |
| std::vector< float > | m_fftWindow |
| precomputed window function coefficients | |
| std::vector< float > | m_filteredBufferL |
| time domain samples with window function applied (left) | |
| std::vector< float > | m_filteredBufferR |
| time domain samples with window function applied (right) | |
| fftwf_plan | m_fftPlanL |
| fftwf_plan | m_fftPlanR |
| fftwf_complex * | m_spectrumL |
| frequency domain samples (complex) (left) | |
| fftwf_complex * | m_spectrumR |
| frequency domain samples (complex) (right) | |
| std::vector< float > | m_absSpectrumL |
| frequency domain samples (absolute) (left) | |
| std::vector< float > | m_absSpectrumR |
| frequency domain samples (absolute) (right) | |
| std::vector< float > | m_normSpectrumL |
| frequency domain samples (normalized) (left) | |
| std::vector< float > | m_normSpectrumR |
| frequency domain samples (normalized) (right) | |
| std::vector< uchar > | m_history_work |
| local history buffer for render | |
| std::vector< uchar > | m_history |
| public buffer for reading | |
| bool | m_flipRequest |
| update public buffer only when requested | |
| std::atomic< unsigned int > | m_waterfallHeight |
| number of stored lines in history buffer | |
| const unsigned int | m_waterfallMaxWidth = 3840 |
| bool | m_spectrumActive |
| bool | m_waterfallActive |
| std::atomic< unsigned int > | m_waterfallNotEmpty |
| number of lines remaining visible on display | |
| bool | m_reallocating |
Receives audio data, runs FFT analysis and stores the result.
|
explicit |
|
virtual |
| float lmms::SaProcessor::ampToYPixel | ( | float | amplitude, |
| unsigned int | height ) const |
| void lmms::SaProcessor::analyze | ( | LocklessRingBuffer< SampleFrame > & | ring_buffer | ) |
| float lmms::SaProcessor::binBandwidth | ( | ) | const |
| unsigned int lmms::SaProcessor::binCount | ( | ) | const |
size of output (frequency domain) data block
| float lmms::SaProcessor::binToFreq | ( | unsigned int | bin_index | ) | const |
| void lmms::SaProcessor::clear | ( | ) |
| void lmms::SaProcessor::clearHistory | ( | ) |
|
inline |
| float lmms::SaProcessor::freqToXPixel | ( | float | frequency, |
| unsigned int | width ) const |
| float lmms::SaProcessor::getAmpRangeMax | ( | ) | const |
| float lmms::SaProcessor::getAmpRangeMin | ( | bool | linear = false | ) | const |
| float lmms::SaProcessor::getFreqRangeMax | ( | ) | const |
| float lmms::SaProcessor::getFreqRangeMin | ( | bool | linear = false | ) | const |
| float lmms::SaProcessor::getNyquistFreq | ( | ) | const |
| unsigned int lmms::SaProcessor::getSampleRate | ( | ) | const |
|
inline |
|
inline |
|
inline |
|
private |
| void lmms::SaProcessor::reallocateBuffers | ( | ) |
| void lmms::SaProcessor::rebuildWindow | ( | ) |
| void lmms::SaProcessor::setSpectrumActive | ( | bool | active | ) |
| void lmms::SaProcessor::setWaterfallActive | ( | bool | active | ) |
| bool lmms::SaProcessor::spectrumNotEmpty | ( | ) |
check if result buffers contain any non-zero values
|
inline |
|
inline |
|
inline |
| unsigned int lmms::SaProcessor::waterfallWidth | ( | ) | const |
binCount value capped at 3840 (for display)
| float lmms::SaProcessor::xPixelToFreq | ( | float | x, |
| unsigned int | width ) const |
| float lmms::SaProcessor::yPixelToAmp | ( | float | y, |
| unsigned int | height ) const |
|
private |
frequency domain samples (absolute) (left)
|
private |
frequency domain samples (absolute) (right)
|
private |
time domain samples (left)
|
private |
time domain samples (right)
|
private |
| QMutex lmms::SaProcessor::m_dataAccess |
|
private |
size of padded block for FFT processing
|
private |
|
private |
|
private |
precomputed window function coefficients
|
private |
time domain samples with window function applied (left)
|
private |
time domain samples with window function applied (right)
|
private |
update public buffer only when requested
|
private |
|
private |
public buffer for reading
|
private |
local history buffer for render
|
private |
size of input (time domain) data block
|
private |
frequency domain samples (normalized) (left)
|
private |
frequency domain samples (normalized) (right)
|
private |
| QMutex lmms::SaProcessor::m_reallocationAccess |
|
private |
|
private |
|
private |
frequency domain samples (complex) (left)
|
private |
frequency domain samples (complex) (right)
|
private |
|
private |
|
private |
number of stored lines in history buffer
|
private |
number of lines remaining visible on display
|
private |
use n-steps bigger FFT for given block size