-
Notifications
You must be signed in to change notification settings - Fork 8
PlayerAudioController
Guribo edited this page Jul 5, 2026
·
3 revisions
Packages/tlp.udonvoiceutils/Runtime/Core/PlayerAudio/PlayerAudioController.cs
The core controller that manages all player audio in the world.
PlayerAudioController is a UdonSharp component implementing the Controller role in the MVC pattern (extends TLP.UdonUtils.Runtime.DesignPatterns.MVC.Controller).
It:
- updates the voice and avatar audio settings using the VRCPlayerApi of each player in the current world
- with the exception of ignored players
- updates players in a time-sliced manner, at least one player during each rendered frame (configurable via
PlayerUpdateRate) - reduces voice and avatar audio ranges based on player or environment occlusion
- reduces voice and avatar audio ranges based on local player head rotation to emitting other player head position (listener directionality)
- reduces voice and avatar audio ranges based on emitting other player head rotation to local player head position (player directionality)
- applies voice and avatar override settings from
PlayerAudioOverridecomponents - mutes players in private channels (except those in the same channel as the local player)
- mutes players that are not in a private channel if
DisallowListeningToChannelis enabled on the corresponding override - can optionally synchronize the global default settings with the instance master via
SyncedMasterConfiguration - supports adjusting the global default settings via UI (uses
PlayerAudioView)
| Field | Type | Purpose |
|---|---|---|
LocalPlayerOverrideList |
PlayerAudioOverrideList |
Override list for the local player |
MainAudioReverbFilter |
AudioReverbFilter |
Reverb filter on the main audio listener |
PlayerOverrideListPool |
Pool |
Object pool for override lists |
PlayerOcclusionStrategy |
PlayerOcclusionStrategy |
Occlusion strategy (default or custom) |
IgnoredPlayers |
IgnoredPlayers |
Players excluded from audio processing |
Menu |
View |
Optional UI view (PlayerAudioView) |
| Field | Type | Purpose |
|---|---|---|
LocalConfiguration |
PlayerAudioConfigurationModel |
Local player's audio settings |
SyncedMasterConfiguration |
PlayerAudioConfigurationModel |
Instance master's synced settings |
DefaultConfiguration |
PlayerAudioConfigurationModel |
Reset-to-defaults values |
| Field | Default | Description |
|---|---|---|
PlayerUpdateRate |
1 |
How many players to update per frame. 0 = all players every frame (performance risk) |
The controller runs after all other audio components (PlayerAudioOverrideList, PlayerOcclusionStrategy, PlayerAudioOverride), processing players in time-sliced fashion.
- PlayerAudioOverride — per-zone/per-item override settings
- PlayerAudioOverrideList — sorted list of overrides per player
- PlayerAudioView — UI view for settings
- PlayerAudioConfigurationModel — data model for all audio settings
- Architecture
- Occlusion
- Voice Directionality
- Height Scaling
- Audio Processing Pipeline
- Private Voice Channels
- WorldAudio Subsystem
- WorldAudio Limitations
- Set Up Occlusion
- Set Up Voice Channels
- Set Up Reverb
- Set Up Height Scaling
- Set Up Voice Directionality
- Set Up Microphone
- Set Up WorldAudio Emitters
- Enable Debug Mode
- Tutorial #1: Custom Voice Override Zone
- Tutorial #2: Private Voice Channels
- Tutorial #3: Setting Up World Audio
- PlayerAudioController
- PlayerAudioOverride
- PlayerAudioOverrideList
- PlayerAudioView
- PlayerAudioConfigurationModel
- SyncedPlayerAudioConfigurationModel
- VoiceUtils
- IgnoredPlayers
- AudioObstacle
- DefaultPlayerOcclusion
- NullPlayerOcclusion
- PlayerOcclusionStrategy
- Privacy Channel Reference
- AdjustableGain
- DynamicPrivacy
- PickupMicrophone — MVC microphone system with MicModel/MicController/MicView
- VoiceOverrideTriggerZone
- VoiceOverrideRoom