AudioListener
Representation of a listener in 3D space.
Read time 6 minutesLast updated 2 days ago
Definition
- Type: Class
- Namespace: UnityEngine
- Assembly: UnityEngine.AudioModule
- Inherits from: AudioBehaviour
[RequireComponent(typeof(Transform))]public sealed class AudioListener : AudioBehaviour
Remarks
This class implements a microphone-like device. It records the sounds around it and plays that through the player's speakers. You can only have one listener in a Scene.
Additional Resources: AudioSource, AudioListener component in the Components Reference.
Properties
Property | Description |
|---|---|
| velocityUpdateMode | This lets you set whether the Audio Listener should be updated in the fixed or dynamic update. |
Static Properties
Property | Description |
|---|---|
| pause | The paused state of the audio system. |
| volume | Controls the game sound volume (0.0 to 1.0). |
Static Methods
Method | Description |
|---|---|
| GetOutputData | Provides a block of the listener (master)'s output data. |
| GetSpectrumData | Provides a block of the listener (master)'s spectrum data. |
Inheritance
Operators
Operator | Description |
|---|---|
| operator == | Compares two object references to see if they refer to the same object. |
| bool | Determines whether the object exists. |
| operator != | Compares if two objects refer to a different object. |