Ejemplo n.º 1
0
 void CheckOutputBuffer(DSPGraph graph, Action <NativeArray <float> > check = null, DSPGraph.ExecutionMode executionMode = DSPGraph.ExecutionMode.Jobified)
 {
     using (var buffer = new NativeArray <float>(kChannelCount * kDspBufferSize, Allocator.Temp))
     {
         graph.BeginMix(0, executionMode);
         graph.ReadMix(buffer, kDspBufferSize, kChannelCount);
         check?.Invoke(buffer);
     }
 }
 public void Sync()
 {
     using (var buff = new NativeArray <float>(200, Allocator.Temp))
     {
         Graph.BeginMix(0);
         Graph.ReadMix(buff, buff.Length / 2, 2);
     }
     Graph.Update();
 }
Ejemplo n.º 3
0
 public void EndMix(NativeArray <float> outputBuffer, int frameCount)
 {
     m_graph.ReadMix(outputBuffer, frameCount, m_channels);
 }
 public void Mix(NativeArray <float> buff, int frameCount, int channelCount)
 {
     Graph.BeginMix(frameCount, ExecutionMode);
     Graph.ReadMix(buff, frameCount, channelCount);
 }