Resonance Audio Unity SDK API Reference

ResonanceAudioListener Class Reference

ResonanceAudioListener

Resonance Audio listener component that enhances AudioListener to provide advanced spatial audio features.

Summary

There should be only one instance of this which is attached to the AudioListener's game object.

Inheritance

Inherits from: MonoBehaviour

Public attributes

globalGainDb = 0.0f
float
Global gain in decibels to be applied to the processed output.
occlusionMask = -1
LayerMask
Global layer mask to be used in occlusion detection.
recorderSeamless = false
bool
Denotes whether the soundfield should be recorded in a seamless loop.
recorderSourceTag = "Untagged"
string
Target tag for spatial audio sources to be recorded into soundfield.
stereoSpeakerModeEnabled = false
bool
Stereo speaker mode toggle.

Properties

IsRecording
bool
Is currently recording soundfield?

Public functions

GetCurrentRecordDuration()
double
Returns the current record duration in seconds.
StartSoundfieldRecorder()
void
Starts soundfield recording.
StopSoundfieldRecorder(string filePath)
void
Stops soundfield recording and saves the recorded data into target file path.

Public attributes

globalGainDb

float globalGainDb = 0.0f

Global gain in decibels to be applied to the processed output.

occlusionMask

LayerMask occlusionMask = -1

Global layer mask to be used in occlusion detection.

recorderSeamless

bool recorderSeamless = false

Denotes whether the soundfield should be recorded in a seamless loop.

recorderSourceTag

string recorderSourceTag = "Untagged"

Target tag for spatial audio sources to be recorded into soundfield.

stereoSpeakerModeEnabled

bool stereoSpeakerModeEnabled = false

Stereo speaker mode toggle.

Properties

IsRecording

bool IsRecording

Is currently recording soundfield?

Public functions

GetCurrentRecordDuration

double GetCurrentRecordDuration()

Returns the current record duration in seconds.

StartSoundfieldRecorder

void StartSoundfieldRecorder()

Starts soundfield recording.

StopSoundfieldRecorder

void StopSoundfieldRecorder(
  string filePath
)

Stops soundfield recording and saves the recorded data into target file path.