Proper Wavetable Synthesis in SunVox!

Post Reply
User avatar
SawZer
Posts: 273
Joined: Sun Jun 19, 2011 2:26 am
Location: Texas
Contact:

Proper Wavetable Synthesis in SunVox!

Post by SawZer »

fuzion_mixer & SawZer present:
fS WAV-TT
A MIDI triggering module that lets you turn any sample into a proper Serum style wavetable!

This was possible thanks to advances made by fuzion_mixer's Granulator module https://warmplace.ru/forum/viewtopic.php?f=11&t=5948

FAQ
What is a wavetable?
A wavetable is a set of single cycle waveforms, that may or may not be related to each other. They are used to contain multiple different sounds to either: scan through to quickly change an instrument's timbre, or to modulate between during a song to create more interesting sounds.

How can I make a wavetable?
All you need is a sample, which can either be one you've recorded, or one downloaded from the internet. One of the inspirations for this module's creation was the abundance of free Serum wavetables on the internet.

I have Serum/Vital. Can I use my wavetables for those synths in SunVox?
Yes! As long as the format is either .WAV or .OGG

CONTROLS
06. 44.1kHz / 48kHz Toggle:
Sets the internal Sound2ctl frequency to either 22.05kHz or 24kHz respectively. If your system uses 48kHz sound, you'll want to toggle this for best quality

07. Frame Count (Cycles):
Use this slider to set how many Frames, or cycles are in your sample.

08. Frame Boundary (Start) and 09. Frame Boundary (End):
These sliders allow you to offset the start and end of where Frames are calculated. 08 lets you offset the start up to 50% of the sample's length, and 09 lets you offset the end (forwards) up to 50% of the sample's length. These sliders are useful for trimming out any silence, or unwanted sections of a sample.

0A. Wavetable Ratio (%):
This slider allows you to tune the wavetable. It can also be used to shorten, or to lengthen (even to the point of overlapping) each frame. You can also modulate this slider in small amounts to detune.

0B. Start Phase:
Controls the starting phase inside each frame. Only takes effect on MIDI note events.

0C: Wavetable Position:
Allows you to scan between Frames/Cycles. Use this to quickly change the timbre of an instrument, or modulate the slider for an evolving sound.

SETUP
For best results, we recommend that you use samples with the following qualities:
- Sample has a stable root pitch. This means that there are no pitch bends in the sample.
- Sample has a stable volume throughout.
- Sample has minimal silence. The Frame Boundary controls are useful for trimming silence, but they can only trim so much. At higher values you'll lose some precision.
- Sample has countable Frames/Cycles, or Frame/Cycle count has been documented. It is possible to manually set the Frame count, but it may take some time.
- Sample is tuned to some octave of C. Otherwise you'll need to set the relative note of the sampler, as well as setting 0A. Wavetable Ratio (%) accordingly.

Step 1, Initial setup:
a - Connect the WAV-TT module to a Sampler as you would with a MultiSynth.
b - Connect the Sampler to an ADSR module, and set the ADSR's 0E. Mode to amp.modulalator mono (1) or amp.modulator stereo (2) if you have a stereo sample.
c - Add a Multisynth, and connect it to both the WAV-TT and the ADSR.
d - Connect the ADSR to module 00 Output.

Step 2, Configuring wavetable settings:
a - Open the Sampler's editor dialog by clicking the "Edit" button on the Sampler.
b - Switch to the waveform view by clicking the "Samples" tab.
c - If you do not know how many Frames/Cycles are present in your sample, you can get a good estimate by doing the following:
----c.i - Find 2 places in your sample where there is either a peak, or a zero crossing (waveform crosses the center line).
----c.ii - click on the first of these peaks/zero crossings, and write down the hex number that appears next to "07:". Do the same with the second peak/zero crossing.
----c.iii - Go to this website https://www.calculator.net/hex-calculator.html, and at the top where it says "Hexadecimal Calculation—Add, Subtract, Multiply, or Divide", enter the second number in the first box, select minus "-", and enter the first number in the second box. Click the "Calculate >" button. Write down the result from "Hex value", and ignore the remainder. If you get a negative number, swap the boxes and try again.
----c.iv - On the same website, and in the same boxes, enter in "8000" "%" and your result. Click the "Calculate >" button. Record the result under "Decimal value", and ignore the remainder.
----c.v - Set the WAV-TT module's 07. Frame Count (Cycles) to this number.
d - Set the WAV-TT module's 0C. Wavetable Position slider to some arbitrary position. In the Sampler's editor dialog, find the playhead. Observe how the playhead moves.
If the playhead:
- Is shorter or longer than one Frame/Cycle: adjust the WAV-TT's 0A. Wavetable Ratio (%) slider. You may need to retune the Sampler and WAV-TT module after this.
- Is offset from a Frame/Cycle: Carefully adjust the WAV-TT module's 07, 08, and 09 sliders to align the playhead properly. You can verify accuracy by slowly changing the WAV-TT's 0C. Wavetable Position and observing the playhead's motion.

I know that was a lot of configuration, but at this point you should have a properly tuned wavetable with little to no artifacts when modulating 0C. Wavetable Position!

Limitations:
Limited pitch range:
Due to integer conversions of MIDI note frequencies, the pitch tracking can be unstable beyond about a 4 octave range.

Monophonic only:
At the moment it's not possible to use WAV-TT in with polyphony.

Requires ADSR module:
WAV-TT constantly sends Note On signals, so you'll need to add an ADSR module so you can control its volume envelope. Otherwise the Sampler will constantly play.

Potentially tedious setup:
Self explanatory. There isn't any automated method for this.

Additional resources:
https://gravitascreate.com/serum-wavetables/
https://yehudarothschild.com/wavetable-editing-tools/
https://www.sequentialwaves.com/
Attachments
fuzion_mixer-SawZer_fS_WAV-TT.sunsynth
(26.32 KiB) Downloaded 251 times
Post Reply