FAST SDK Coding Reference 1.0.3
Loading...
Searching...
No Matches
AudioClipExtensions Class Reference

A class to extend the functionality of an AudioClip. More...

Static Public Member Functions

static AudioClip CreateChannelClip (this AudioClip originalClip, bool[] targetChannels)
 Create a new multi-channel AudioClip from the current AudioClip. The new clip can have audio on specifc channels so that it plays through specific speaker(s).
 
static AudioClip CreatePauseClip (float duration)
 Create an empty AudioClip, which could be use for pausing before or after playing another AudioClip.
 

Detailed Description

A class to extend the functionality of an AudioClip.

See also
UnityEngine.AudioClip

Member Function Documentation

◆ CreateChannelClip()

static AudioClip CreateChannelClip ( this AudioClip originalClip,
bool[] targetChannels )
static

Create a new multi-channel AudioClip from the current AudioClip. The new clip can have audio on specifc channels so that it plays through specific speaker(s).

Parameters
originalClipThe current AudioClip to create a new multi-channel clip from.
targetChannelsThe array to select which channels to use. Set an element to true if that index represents a channel to use.
Returns
A new multi-channel AudioClip.
See also
This is a modified version of the code shared by Thomas-Mountainborn on Unity Forums on June 10, 2016

◆ CreatePauseClip()

static AudioClip CreatePauseClip ( float duration)
static

Create an empty AudioClip, which could be use for pausing before or after playing another AudioClip.

Parameters
durationThe amount of time in seconds that the clip should play for.
Returns
A new AudioClip.

The documentation for this class was generated from the following file: