Пример #1
0
 public void AddSamples(float[] buffer, int offset, int count, byte[] listeners)
 {
     if (this.circularBuffer == null)
     {
         this.circularBuffer = new MyCircularBuffer(this.BufferLength, FloatPerRead);
     }
     circularBuffer.Write(buffer, offset, count, listeners);
 }
Пример #2
0
 public MyBufferedSampleProvider(WaveFormat waveFormat)
 {
     this.waveFormat     = waveFormat;
     this.BufferLength   = (waveFormat.AverageBytesPerSecond / 4) * 5;
     this.ReadFully      = true;
     FloatPerRead        = waveFormat.AverageBytesPerSecond / 20;
     this.circularBuffer = new MyCircularBuffer(this.BufferLength, FloatPerRead);
 }