Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions docs/player-audio-txl/configuration/_category_.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"label": "Configuration",
"position": 1
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# Audio Override Manager

The **Audio Override Manager** is a component responsible for handling different **Audio Override Zones**.

![Audio Override Manager](/img/unity/playeraudio/overridemanager-1.png)

:::warning

There can only be one Audio Override Manager in a scene!

:::

## Configuration

#### Default Zone

> The default zone that is used when players are not in any specific zone.
> Used to set up default settings.

#### Override Zones

> Override Zones is a list of Audio Override Zones that you have in your world.

### Debug Options

#### Debug State

> A debug state object that will peridocally capture a snapshot of internal state of the object.


## Public API

### Network Sync

This object is **not** network synced.

### Inherited API

* UdonSharpBehaviour Public API

### Properties

#### <ApiProperty return="AudioOverrideZone" property="defaultZone" />

> Get the default AudioOverrideZone

#### <ApiProperty return="AudioOverrideZone[]" property="overrideZones" />

> Get the list of linked AudioOverrideZones

#### <ApiProperty return="AudioOverrideDebug" property="debugState" />

> Returns the debugState

### Methods

#### <ApiMethod return="void" method="_SetDebugState" params={["AudioOverrideDebug", "state"]} />

> Sets the debug state object at runtime, replacing the previous debug state if it exists. Passing `null` will unasign
> any current debug state.

#### <ApiMethod return="void" method="_UpdateZoneData" />

> Updates zone data

#### <ApiMethod return="void" method="_PlayerEnterZone" params={["AudioOverrideZone", "zone", "VRCPlayerApi", "player"]} />

> Called when a player enters a zone

#### <ApiMethod return="void" method="_PlayerLeaveZone" params={["AudioOverrideZone", "zone", "VRCPlayerApi", "player"]} />

> Called when a player leaves a zone

#### <ApiMethod return="void" method="_RebuildLocal" />

> Rebuild local

#### <ApiMethod return="AudioOverrideZone" method="_FindActiveZone" params={["VRCPlayerApi", "player"]} />

> Find active zone of a player.
> Returns `null` when the player is not in any override zones.
177 changes: 177 additions & 0 deletions docs/player-audio-txl/configuration/audio-override-settings/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,177 @@
# Audio Override Settings

The **Audio Override Settings** is a component responsible for applying the **player volume** settings.

![Audio Override Settings](/img/unity/playeraudio/overridesettings-1.png)

## Configuration

### Voice Override

![Overide Settings Editor - Voice Override](/img/unity/playeraudio/overridesettings-2.png)

The settings for player voice audio.

#### Apply Voice

> Whether to apply the voice override settings

#### Voice Gain

> Voice volume.
>
> Default is 15, which is normal volume level.
> 0 is used for Broadcast and Mute profiles.

#### Voice Near

> How close the player can be heared.
>
> Default is 0, meaning no distance is required for hearing other players.
> For the broadcast profile, this defaults to 200.

#### Voice Far

> How far the player can be heared from.
>
> Default is 25, meaning 25 units/meters is the furthest distance you can hear other players from.
> For the broadcast profile, this defaults to 200.
> So also for a comms system, you want to set this very high, so you can hear over large distances.
> For muting players, set this to 0 and set the near to 0 as well, meaning there's no space to hear the other players.

#### Voice Volumetric

> The volumetric radius for the player's voice.
>
> Default is 0.
> For the broadcast profile, this defaults to 200.

#### Voice Lowpass

> Whether a lowpass filter is applied to the player's voice.
>
> Default is On.
> For the broadcast profile, this defaults to Off.


### Avatar Sound Override

![Overide Settings Editor - Avatar Sound Override](/img/unity/playeraudio/overridesettings-3.png)

The settings for avatar sounds.

#### Apply Avatar

> Whether to apply the overrides to the avatar sounds.

#### Avatar Gain

> Avatar volume.
>
> Default is 10, which is normal volume level.
> 0 is used for Broadcast and Mute profiles.

#### Avatar Near

> How close the avatar sounds can be heared.
>
> Default is 0, meaning no distance is required for hearing other players.
> For the broadcast profile, this defaults to 200.

#### Avatar Far

> How far the avatar sounds can be heared from.
>
> Default is 40, meaning 40 units/meters is the furthest distance you can hear avatar sounds from.
> For the broadcast profile, this defaults to 200.
> For muting avatar sounds, set this to 0 and set the near to 0 as well, meaning there's no space to hear the avatar sounds.

#### Avatar Volumetric

> The volumetric radius for the avatar sounds.
>
> Default is 0.
> For the broadcast profile, this defaults to 200.

### Debug Options

![Overide Settings Editor - Debug Options](/img/unity/playeraudio/debugoptions.png)

#### Debug Log

> The debug log object that any logging should be directed to.

#### VRC Logging

> Writes a copy of any logged messages to the VRChat log.


## Public API

### Network Sync

This object is **not** network synced.

### Inherited API

* UdonSharpBehaviour Public API

### Properties

#### <ApiProperty return="bool" property="applyVoice" />

> Determines whether voice override settings should be applied.

#### <ApiProperty return="float" property="voiceGain" />

> Gets or sets the gain (volume) level for voice.

#### <ApiProperty return="float" property="voiceNear" />

> Gets or sets the near distance for voice attenuation.

#### <ApiProperty return="float" property="voiceFar" />

> Gets or sets the far distance for voice attenuation.

#### <ApiProperty return="float" property="voiceVolumetric" />

> Gets or sets the volumetric radius for voice.

#### <ApiProperty return="bool" property="voiceLowpass" />

> Gets or sets whether a lowpass filter is applied to voice.

#### <ApiProperty return="bool" property="applyAvatar" />

> Determines whether avatar audio override settings should be applied.

#### <ApiProperty return="float" property="avatarGain" />

> Gets or sets the gain (volume) level for avatar audio.

#### <ApiProperty return="float" property="avatarNear" />

> Gets or sets the near distance for avatar audio attenuation.

#### <ApiProperty return="float" property="avatarFar" />

> Gets or sets the far distance for avatar audio attenuation.

#### <ApiProperty return="float" property="avatarVolumetric" />

> Gets or sets the volumetric radius for avatar audio.

#### <ApiProperty return="DebugLog" property="debugLog" />

> Gets or sets the debug logging interface used by this class.

#### <ApiProperty return="bool" property="vrcLogging" />

> Gets or sets whether VRChat-specific logging is enabled.

### Methods

#### <ApiMethod return="void" method="_Apply" params={["VRCPlayerApi", "player"]} />

> Applies voice and avatar override settings to the specified VRCPlayerApi player.
Loading