Murl Engine Lua Addon API  Version 1.0 beta
Murl.Graph.IAudioSource

The IAudioSource graph node interface.

This interface represents a node referencing a read-only Resource::IAudio object, which can be played back by assigning it to one or more individual Graph::IAudioSequence nodes.


Table members

Methods


GetNodeInterface()

Get the constant Graph::INode interface. This method returns a constant pointer to the node's Graph::INode interface, to be able to query common node properties such as active state, visibility or ID.

Murl.Graph.INode GetNodeInterface()

Returns
Murl.Graph.INode The constant Graph::INode interface, or null if not available

GetAudioResourceTarget()

Get a constant Graph::IAudioResourceTarget container. This method returns a constant pointer to a Graph::IAudioResourceTarget container, which allows to query the audio resources referenced by a node implementing this interface.

Murl.Graph.IGenericResourceTarget.ResourceIAudio GetAudioResourceTarget()

Returns
Murl.Graph.IGenericResourceTarget.ResourceIAudio The constant Graph::IAudioResourceTarget container, or null if not available

SetBufferType(type)

Set the audio node's buffer type.

Boolean SetBufferType(Murl.IEnums.BufferType type)

Parameters
typeThe buffer type.
Returns
Boolean true if successful.

GetBufferType()

Get the audio node's buffer type.

Murl.IEnums.BufferType GetBufferType()

Returns
Murl.IEnums.BufferType The buffer type.

GetDuration()

Get the duration of the audio object.

Number GetDuration()

Returns
Number The duration in seconds.

AcquireAudioStream()

Get the audio node's audio stream.

Murl.IAudioStream AcquireAudioStream()

Returns
Murl.IAudioStream The audio stream.

ReleaseAudioStream(stream)

Release a previously acquired audio stream.

Boolean ReleaseAudioStream(Murl.IAudioStream stream)

Parameters
streamThe audio stream to release
Returns
Boolean true if successful.