A wavetable lookup oscillator which can be swept smoothly across wavetables. Fractional values of table will interpolate between two adjacent tables.
This oscillator requires at least two buffers to be filled with a wavetable format signal. This preprocesses the signal into a form which can be used efficiently by the oscillator. All the wavetables must be allocated to the same size, and the size must be a power of two.
The wavetable can be generated by filling a buffer via the Buffer: Buffer Fill Commands (e.g. Buffer: -sine1). Set wavetable: true
to ensure the proper data formatting.
Identically, you can create a Buffer object by sending one of the \b_gen
messages \sine1
, \sine2
, \sine3
(see Server Command Reference: Wave Fill Commands and examples below), again remembering to enable the wavetable format.
You can use Buffer: *allocConsecutive to ensure a contiguous buffers numbers to be interpolated.
This can also be achieved by creating a Signal object and sending it the Signal: -asWavetable message, saving it to disk, and having the server load it from there.
bufpos |
Buffer index. Can be swept continuously among adjacent wavetable buffers of the same size. |
freq |
Frequency in Hertz. (non-interpolated control-rate) |
phase |
Phase offset or modulator in radians. |
mul |
Output will be multiplied by this value. |
add |
This value will be added to the output. |