Meta_AudioTrack

An AudioTrack provides full control over playback and looping of data in a Meta_AudioBuffer.

One sound source is allocated to this and is retained to prevent AudioSound interrupting it.

Public Types


enum IDX

Property Index.

Idx_AudioBuffer

link - Meta_AudioBuffer containing the audio data we want this sound to play

Idx_State

State (int) - The playback state of the track

Idx_Gain

float - Volume; 0.0 is silent, 1.0 is 100% volume, 2.0 is 200%. Clamped at 2.0.

Idx_Loop

bool - When true, track automatically restarts when it reaches the end. Otherwise, upon ending it enters the Stopped state.

Idx_Relative

bool - When true, positional audio is relative to the listener (i.e. Camera), otherwise it is positioned in its world location.

Idx_RelativeTo

RelativeTo (int) - For relative mode, whether to use the parent Assembly world or local transform.

Idx_Directional

Unused.


Values for Idx_RelativeTo.

World

Use the parent assembly world transform to position the audio relative to the listener (Symbols - C: "RelativeToWorld", Lua: __AudioTrack_RelativeToWorld)

Local

Use the parent assembly local transform (Symbols - C: "RelativeToLocal", Lua: __AudioTrack_RelativeToLocal)


enum State

Values for Idx_State.

Stopped

Track is stopped and waiting at the beginning (Symbols - C: "Stopped", Lua: __AudioTrack_Stopped)

Playing

Track is playing (Symbols - C: "Playing", Lua: __AudioTrack_Playing)

Paused

Track is paused and will resume from the last playing location (Symbols - C: "Paused", Lua: __AudioTrack_Paused)

No Results.

Getting StartedArchitectureBest PracticesHow ToAdvanced TopicsChangelogvrtree_cppCoreForeign Function InterfaceMetanodesMigrationsObserversPropertiesTreeUtilitiesAPI DefinitionsVR ExchangePluginsLua API