[LAD] Wavetable synthesis : Creating fat wavetables
Gabriel M. Beddingfield
gabrbedd at gmail.com
Sat Aug 25 14:32:44 UTC 2012
On 08/24/2012 02:21 PM, harryhaaren at gmail.com wrote:
> Hi everybody!
> I'm interested in wavetable synthesis, so read around a bit on how they
> work, best used etc, but I can find preciously little information that
You probably know this, but wavetable synthesis is different from a
table-lookup oscillator. It sounds like you're doing a table look-up
> describes how to best "create" a wavetable.
> Pre-recorded material seems a pretty go-to choice rather than using
> csound or freinds to generate wavetables.
> The issue of tuning is where I currently struggle the most: How should
> that be approached?
I wrote a table-lookup oscillator that is currently being used in
omap-audio-tool for the tone generator. See  for the header. I
originally wrote it for fun, with the intention of using it on platforms
with weak floating point.
Like Fons mentioned in the e-mail, I made my tables a length of N^2 and
large enough so that they would not need interpolation for frequencies
over about 100Hz (IIRC). Below this cut-off frequency it does linear
When calculating offsets within your table, it's important to be wary of
truncation error (i.e. don't convert your frequency to "play every kth
sample in the table). This will cause your output frequencies to be
different from what you input (quantization error).
For generating the tables for sine, triangle, etc., audio-tool has a
program generate-wave-table.c that generates the look-up tables in a
format suitable for inclusion in a C source file. However, you can
easily change the output by changing the 'out()' implementation in main().
 I started off calling everything "wavetable" by mistake, this is one
was overlooked in the renaming of thing.
More information about the Linux-audio-dev