AudioEffectSpectrumAnalyzerInstance
Queryable instance of an AudioEffectSpectrumAnalyzer.
Queryable instance of an AudioEffectSpectrumAnalyzer.
The runtime part of an AudioEffectSpectrumAnalyzer, which can be used to query the magnitude of a frequency range on its host bus.
An instance of this class can be obtained with AudioServer.GetBusEffectInstance.
Declarations checked against C# SDK 1.0.0. Expand a name to see declarations and documentation.
Methods1
GetMagnitudeForFrequencyRangeVector2
public Vector2 GetMagnitudeForFrequencyRange(float fromHz, float toHz, AudioEffectSpectrumAnalyzerInstance.MagnitudeMode mode = AudioEffectSpectrumAnalyzerInstance.MagnitudeMode.Max);Returns the magnitude of the frequencies from from_hz to to_hz in linear energy as a Vector2. The x component of the return value represents the left stereo channel, and y represents the right channel.
mode determines how the frequency range will be processed.
| Name | Type | Default |
|---|---|---|
fromHz | float | — |
toHz | float | — |
mode | AudioEffectSpectrumAnalyzerInstance.MagnitudeMode | AudioEffectSpectrumAnalyzerInstance.MagnitudeMode.Max |
Vector2AudioEffectSpectrumAnalyzerInstance.MagnitudeMode
| Value | Description |
|---|---|
Average = 0 | Use the average value across the frequency range as magnitude. |
Max = 1 | Use the maximum value of the frequency range as magnitude. |