Navigation
API > API/Runtime > API/Runtime/SignalProcessing > API/Runtime/SignalProcessing/DSP
References
| Module | SignalProcessing |
| Header | /Engine/Source/Runtime/SignalProcessing/Public/DSP/SpectrumAnalyzer.h |
| Include | #include "DSP/SpectrumAnalyzer.h" |
Syntax
class FAsyncSpectrumAnalyzer
Remarks
SpectrumAnalyzer for computing spectrum in async task.
Constructors
| Type | Name | Description | |
|---|---|---|---|
FAsyncSpectrumAnalyzer
(
float InSampleRate |
If an instance is created using either of these constructors, Init() is not neccessary. | ||
FAsyncSpectrumAnalyzer
(
const FSpectrumAnalyzerSettings& InSettings, |
Destructors
| Type | Name | Description | |
|---|---|---|---|
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | GetBands
(
ISpectrumBandExtractor& InExtractor, |
Return array of bands using spectrum band extractor. | |
| float | GetMagnitudeForFrequency
(
float InFrequency, |
Samples magnitude (linearly) for a given frequency, in Hz. | |
| float | GetNormalizedMagnitudeForFrequency
(
float InFrequency, |
||
| float | GetPhaseForFrequency
(
float InFrequency, |
Samples phase for a given frequency, in Hz. | |
| void | GetSettings
(
FSpectrumAnalyzerSettings& OutSettings |
Get the current settings used by this Spectrum Analyzer. | |
| void | Init
(
const FSpectrumAnalyzerSettings& InSettings, |
Initialize sample rate of analyzer if not known at time of construction. | |
| void | Init
(
float InSampleRate |
Initialize sample rate of analyzer if not known at time of construction. | |
| bool | Returns false if this instance of FSpectrumAnalyzer was constructed with the default constructor and Init() has not been called yet. | ||
| void | You can call this function to ensure that you're sampling the same window of frequency data, Then call UnlockOutputBuffer when you're done. | ||
| bool | PerformAnalysisIfPossible
(
bool bUseLatestAudio |
Thread safe call to perform actual FFT. | |
| bool | PerformAsyncAnalysisIfPossible
(
bool bUseLatestAudio |
Thread safe call to perform actual FFT. | |
| bool | PushAudio
(
const TSampleBuffer< float >& InBuffer |
Push audio to queue. Returns false if the queue is already full. | |
| bool | PushAudio
(
const float* InBuffer, |
Push audio to queue. Returns false if the queue is already full. | |
| void | SetSettings
(
const FSpectrumAnalyzerSettings& InSettings |
Update the settings used by this Spectrum Analyzer. Safe to call on any thread, but should not be called every tick. | |
| void |