Static variables

@:value(128)staticinlineread onlyMAX_WORKLET_PARAMS:Int = 128

Variables

read onlycontext:AudioContext

@:value(false)read onlyactive:Bool = false

Methods

@:value({ volume : 1.0, name : "" })createBus(index:Int, name:String = "", volume:Float = 1.0):Void

setBusVolume(busIndex:Int, volume:Float):Void

setBusActive(busIndex:Int, active:Bool):Void

loadWorkletModule(name:String, url:String, ?callback:(success:Bool) ‑> Void):Void

attachWorkletToBus(busIndex:Int, workletName:String, ?options:Dynamic, ?onReady:() ‑> Void):Bool

scheduleWhenBusWorkletReady(busIndex:Int, ready:() ‑> Void):Void

setWorkletParameterWhenReady(busIndex:Int, paramName:String, value:Float):Void

setWorkletParameter(busIndex:Int, paramName:String, value:Float):Void

setWorkletParameterByIndex(busIndex:Int, paramIndex:Int, value:Float):Void

getWorkletParameterByIndex(busIndex:Int, paramIndex:Int):Float

@:value({ busIndex : DEFAULT_BUS })play(source:AudioSource, volume:Float, paused:Bool, busIndex:Int = DEFAULT_BUS):AudioHandle

@:value({ busIndex : DEFAULT_BUS })loop(source:AudioSource, volume:Float, paused:Bool, busIndex:Int = DEFAULT_BUS):AudioHandle

volume(handle:AudioHandle, volume:Float):Void

pan(handle:AudioHandle, pan:Float):Void

pitch(handle:AudioHandle, pitch:Float):Void

moveSoundToBus(handle:AudioHandle, newBusIndex:Int):Bool

createBusFilter(uri:String, busIndex:Int, createFunc:(busIndex:Int, instanceId:Int) ‑> Void, destroyFunc:(busIndex:Int, instanceId:Int) ‑> Void):Void

addBusFilterWorklet(busIndex:Int, filterId:Int, workletClass:Class<Any>, workletReady:() ‑> Void):Void

destroyBusFilterWorklet(busIndex:Int, filterId:Int):Void

dataFromBytes(id:String, bytes:Uint8Array, ?format:AudioFormat, ?callback:(data:AudioData) ‑> Void):Void

@:value({ interleaved : true })dataFromPCM(id:String, pcmData:Float32Array, sampleFrames:Int, channels:Int, sampleRate:Float, interleaved:Bool = true, ?format:AudioFormat, ?callback:(data:AudioData) ‑> Void):AudioData

Creates AudioData from raw PCM Float32 samples.

Parameters:

id

Unique identifier for this audio data

pcmData

Float32Array containing the raw PCM samples

sampleFrames

Number of sample frames (samples per channel)

channels

Number of audio channels (1 = mono, 2 = stereo, etc.)

sampleRate

Sample rate in Hz (e.g., 44100)

interleaved

Whether the PCM data is interleaved (LRLRLR...) or planar (LLL...RRR...)

format

Optional audio format information

callback

Optional callback when AudioData is ready

Inherited Variables

Defined by BaseAudio

read onlyapp:Clay

Clay app

Inherited Methods