Struct DSPGraph.OutputMixerHandle
A container for mixer thread operations
Inherited Members
Namespace: Unity.Audio
Syntax
public readonly struct OutputMixerHandle
Methods
BeginMix(Int32, DSPGraph.ExecutionMode)
This method is called before reading the samples from the mix
Declaration
public readonly void BeginMix(int frameCount, DSPGraph.ExecutionMode executionMode = DSPGraph.ExecutionMode.Jobified)
Parameters
Type | Name | Description |
---|---|---|
Int32 | frameCount | The number of frames to mix |
DSPGraph.ExecutionMode | executionMode | The execution mode to be used for audio kernels |
Remarks
This method will be bursted if the owning IAudioOutputJob is decorated with BurstCompileAttribute
ReadMix(NativeArray<Single>, Int32, Int32)
Read the samples from the mix. Always call after BeginMix.
Declaration
public readonly void ReadMix(NativeArray<float> buffer, int frameCount, int channelCount)
Parameters
Type | Name | Description |
---|---|---|
NativeArray<Single> | buffer | A Float array of the samples |
Int32 | frameCount | The number of frames to read |
Int32 | channelCount | The number of channels to read |
Remarks
This method will be bursted if the owning IAudioOutputJob is decorated with BurstCompileAttribute