Exemplo n.º 1
0
        private void Add2Buffer(byte[] buffer, byte[] result, int totsamples, int channels1, int channels2, bool v, float volume)
        {
            switch (this.Format)
            {
            case AudioFormat.Short16: AudioOut.Add2BufferShort(buffer, result, totsamples, channels1, channels2, v, volume); break;

            case AudioFormat.Float32: AudioOut.Add2BufferFloat(buffer, result, totsamples, channels1, channels2, v, volume); break;

            default: throw new NotImplementedException();
            }
        }
Exemplo n.º 2
0
        private void RootMeanSquare(float[] audiolevel, byte[] buffer, int channels)
        {
            switch (this.Format)
            {
            case AudioFormat.Short16: AudioOut.RootMeanSquareShort(audiolevel, buffer, channels); break;

            case AudioFormat.Float32: AudioOut.RootMeanSquareFloat(audiolevel, buffer, channels); break;

            default: throw new NotImplementedException();
            }
        }