On Sun, 13 Aug 2006, David Powers wrote:
Now, what I'd be curious to know is how I can get amplitude values in order to do cheap simulations of various instruments (flute, cello, etc.). I know this can be done with fft's, but I don't know how to get a simple list of values between 0-1 that I can just plug into my additive synth.
You need to make your FFT use the same fundamental as the note you play. It might be easier to instead play the same fundamental as your FFT's instead. Note that instruments have various timbres depending on the pitch, so you really want something recorded at the same octave as what you're going to play (which is pretty much the difference between wavetables of the 1980's and those of the 1990's).
For example, if you pick a blocksize of 64 and a sample rate of 44100 Hz, the fundamental is 44100/64 Hz = 689.0625 Hz = MIDI 76.766. For any power-of-two blocksize the result will be some Fa note minus one-eighth tone.
For a sample rate of 48000 Hz, the fundamental is 48000/64 Hz = 750 Hz = MIDI 78.232. For any power-of-two blocksize the result will be some Fa# note plus one-eighth tone.
_ _ __ ___ _____ ________ _____________ _____________________ ... | Mathieu Bouchard - tél:+1.514.383.3801 - http://artengine.ca/matju | Freelance Digital Arts Engineer, Montréal QC Canada