Quantcast
Channel: NAudio
Viewing all articles
Browse latest Browse all 5831

New Post: Use WaveIn to get Pitch (fft/autocorrelator).

$
0
0

Well all that is needed is to make sure you have the right number of samples. Because of the use of FFT, you need a power of two. So you could set up your buffer sizes carefully so that each DataAvailable has exactly the right number of samples, or you could use a CircularBuffer and when you have enough pass a chunk of samples into the AutoCorrelator. Use Buffer.BlockCopy to go from byte[] to float[] (assuming you are recording in mono)


Viewing all articles
Browse latest Browse all 5831

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>