[PD] efficient bank of sines

Johannes Taelman j0 at advalvas.be
Tue Dec 9 13:21:01 CET 2003


 > On Monday 08 December 2003 12:52 pm, Tom Erbe wrote:

 >>what's the opinion of the list as the most efficient method to make a
 >>large bank of harmonically related sines (say 50-200 partials)? is it
 >>just a group of osc~, or phasor~ or something else entirely?

All really depends on how much control you want over it.

If you only need to change the fundamental pitch and overall amplitude, 
you just need to implement a wavetable synth, and generate the 
appropriate wavetable, like Ben describes. Could also be done with the 
sinesum (?) message to an array.

If you need frame-based control over the individual amplitudes, you can 
do the overlap-add ifft-synthesis with block~ and rifft~.

If you need to change the spectrum only once in a while, you can put the 
rifft~ and tabsend~ in a subpatch. Switch~ it off with bang~, so it runs 
only once each time you switch~ it on.

An improved version of this uses multiple wavetables and crossfades 
between them so that there are no clicks when changing the spectrum.

If audio-rate control over the individual amplitudes and/or pitches is 
required, you'll need osc~'s and a fast computer.

Correct me if I'm wrong somewhere.

BTW: Are those guard points still required for correct use of tabread4~? 
How can we generate them elegantly when not generating the wavetable 
with sinesum?

  j#|@





More information about the Pd-list mailing list