Hello FMOD Ex developers
In the Channel::getSpectrum function, is there any chance of you increasing the max value of the numvalues parameter for your next release. Currently this is set at 8192, which, at an OutputRate of 11025, gives a frequency increment in the spectrumarray of 0.6729 Hz. If numvalues could be doubled (or even quadrupled), I could increase the accuracy of my guitar tuner accordingly.
If it cannot be increased, is there another way of getting an accurate reading of the frequency?
- Catz asked 12 years ago
I haven’t actually tried this, but if you are currently just looking for the largest peak in the spectrum, then you could probably increase the accuracy without increasing the fft size.
You could use the frequency you have found to look for local peaks at around multiples of the frequency you have found.
There are more spectrum samples for higher octaves than for lower octaves, so your accuracy should go up that way.
- Adion answered 12 years ago
You can’t use fmod’s spectrum to write an accurate guitar tuner. Guitars have multiple harmonics in it and you have to use multiple overlapping spectrums, and you also need phase information to get the best result. We wont be increasing the numvalues paramater range any time in the future. The bigger it gets the larger the latency gets and actually you will get more innacuracy, because it is analyzing huge windows of data which could contain multiple notes.
Please login first to submit.