Some brainstorming on a possible wave generator

Let me try to explain the simple-most generator for Renoise I can think of: Zebra-Line-Drawing in the Sample Editor. Right, look at u-he Zebra and see how basic these
oscillators are set up. It’s a line tool as in graphics software. You can create: Saw, pulse and triangle among other simmilar shapes. Zebra can
actually do frequency-domain drawing and morphing too. We’re at the moment not interested in these. And it would be enough to draw only a single line segment.

So, what should happen when you have drawn such a line in the Sample Editor? Simply: It gets rendered into the Waveform, with exacly the size that matches onto
the wave view, at exactly the start and end points you have dragged the line.

Loop points for this cycle will be set by Renoise. So with one drag you can create a saw. With two drags you can create a triangle, but the loop points are on the
second segment then, the same applies when creating a pulse. So there should be some minimal assistance in getting the loop points correctly. A sine cycle could be
done by afterwards using the already-there filtering on selected wave-data. Again, with some loop point assistance.

Now that would be a very simple wave generator. But a lot of folks would complain how it sounds, heavily aliasing. So, after the groundwork is done, to cure this
aliasing there would be two features needed: Adding more than just cubic interpolation to Renoise. Saved in the song per Waveform. There’s a few more interpolators
than just 4 point cubic, and they are also using only few points. They all have different characteristics when applied to the transitions of basic shapes. Some give less
aliasing on saw transitions, some on pulse. Basicly it would allow a “blind” way to create PolyBLEP oscillators.

The rest of the aliasing could then be reduced with oversampling. Since other parts of Renoise should not be touched, it would be good to do oversampling on each Instrument.
Doing the filtering and downsampling on each Renoise Instrument, or even each Waveform (as there might be already things in an Instrument that cannot handle a different
audio rate) would, at first, not be very fast.

So, the pulse width modulation would be left. This could be fixed by - as Zebra does - morphing between two Waveforms. Meaning, it’s not impossible, though in this scenario
depending on a feature that’s not trivial to implement. Edit: gentleclockdivider pointed out that Zebra uses graintables for this.

Curious, how does the zebra oscillator work? Is it really generating a only one single sample? Or is it actually an oscillator of some sort and you are just controlling the shape or harmonic content of it via a ‘pencil’ control?

Perhaps, a purely sampling solution would be for the draw waveform function to calculate and generate multi-samples from the drawing so that higher octaves would be less likely to alias. Maybe, then a user applier key tracking bandpass (weighted towards extreme highs), adjusted as well as possible, would work a little better to limit aliasing?

The drawing option already exists in the sample editor, it simply is not really a line-tool but freehand drawing, that perhaps makes it a bit cumbersome to draw straight lines.
I like the rest of these ideas.

Don’t know how it internally works. While for Sytrus I could say since Gol posted it on KVR (that cool minimal pre-synthesizer => big single cycle => FFT), Urs Heckman jokingly replied to someone that he’d have to kill him after he told how (easy) it works. But the neat drawing with straight lines in Zebra is actually done by keeping segment ends/starts together and some insert-point feature. It’s actually just like an envelope editor.

I thought this too yesterday. But when reading about Gol and his Sytrus on KVR ^_^, I found some unpleasant problem with the wavetable approach: To get less aliasing, you need more key zones. But with the keyzones, you also increase “breaks” that you later might want to hide for stuff like portamento or the pitch envelopes.

The key tracking bandpass sounds promising. Though I think, for anti-aliasing a steep lowpass filter might be better, as it happens up there in the frequency. But there’s no butterworth 8n or so at the Waveform modulation yet, maybe such a filter is also too slow when updating coefficients, if it later should follow a fast pitch change. And, really oversampling, so, rendering at 2x frequency, cutting the upper half away and downsampling, is afaik unparalelled in terms of sound. But I could be wrong, the experts for this are in the renoise team or the DSP forum on KVR. Maybe we could ask.

zebra’s osc…are far more complicated than you describe; altought the result of the drawed waveforms (geomorph mode ) output a waveform of the exact shape , there is a lot more happening under the hood .
There’s an explanation over at the kvr forum .
As spacecult describes , the actual creating/shaping of harmonic content of the waveform is al happening under the hood in zebra , that why zebra is so great , simple user interface but a lot of stuff happening .,but I think that urs explained somewhere that the actual waveform creation is a hybrid
of additive+graintable etc…
Renoise for that matter or any other synth that has the ability to draw waveforms are just table oscillators , the lenght of the table is defined when you input the length of the samples/also define resolution ( reaktor audiotable for example ) that get scanned trough with a ramp oscillator which defines the pitch of the sample .
I created a waveform generator in reaktor based on the sine table , you can record it in the audiotable ( you can set sample size to your liking ) 128 partials, crystal clear sound .,you do have to make multisamples yourself
Like I said earlier ,renoise synthesis capabilities are verry limited , pure sound generatiion that is ( no effects ) , altough it has a great interpolation algo ( argures ) ,
Renoise needs some serious boost in that area ,
The download link is directly from my box account ,( no shaddy download link with popups )

https://app.box.com/…0e1vo314bjr3mdq

All this being said, the option to (for example) click and then hold shift and click somewhere else to draw a straight line between those two points would be incredibly handy

Do you remember where he wrote this?

Ok, but since the Waveform length and loop points can be set by your likings, I don’t yet completely understand the size limitation or the problem you describe. What I understand, is, that the generator would not evolve itself. The only way to create generatos that change their sound over time would be (from a GUI perspective) a kind of crossfading. Though, I know, simply adding a 10-sample pulse to a 20-sample pulse won’t magically give you pulse width modulation. That feature would not be trivial. It would also mean changing all code involved. But from the perspective of the user and GUI, it could still be added at a later release by just giving them an additional fader. So, why not *wait with the “morphing” feature?

Imho: Making multi-samples is an “approved workaround” with Renoise, since it works more or less and Renoise provides the possibilities. And this not just for the sake of anti-aliasing. I mean, if you use the key zones for creating the anti-aliasing, you lose these zones for creating different timbres for other zones. The user would have to create all intersected zones and work with them. So, the multi-sample feature isn’t just there to be abused as a wavetable. That’s why I’m not really keen on resambling a wavetable myself.

And I’m not conviced it will sound good with pitch changes, see previous post. It would have to be a so complex multi-sample. It’s what a wavetable-synthesizer does internally. Nothing that I could ever edit in Renoise myself.

Yep, sadly that’s how it is. And we need a good way to change it.
Argurus sinc is great, but also not realtime.

Iv never really liked freehand drawing waveforms, its very clumsy and often needs smoothing. Creating a wave with bezier curves is a much better way imo.

Here you go
http://www.kvraudio.com/forum/viewtopic.php?t=395297

One way to improve freehand drawing with the tools e currently have ( not talking about lua ) is increasing the sample size , standard is 168 samples ,which is way too small to draw detailed waveforms , you could increase to 1024 …when smoothing (interppolation between samples ) the changes won’t be that abrupt …, afterwards you ofcourse have to adjst the fundamental piitch in instrument properties /.
Serious I created a verry realisitically sounding 808 bass drum , the sample lenght was 22000 ( half a second ) …the most difficult part was drawing the sine waves at the first 50 ms of the sample .( which defined the intital pitch decay )

Thanks! :)

Renoise is capable of a type of what I would think might be grain-table synthesis, but just not in any much usable way (that’s apparent to me).

You can sort of play with this by getting a sample and entering a whole line of c-4s (or whatever, doesn’t matter) in the phraser and have phrase looping on. If you set the lpb and/or bpm to something where the apparent pitch of a played note is determined by the speed of the note ons in the phraser and not by the sample itself, you have then created another type of oscillator with harmonic content determined by whatever small snippet of the beginning of the sample is allowed to play.

In this case, the frequency of the oscillator is determined by the speed of the ‘notes’/how often the ‘oscillator’ is reset. So, it’s not really a sequencer anymore, it’s a return to beginning of waveform commander (uhm, yeah). But you don’t have to really think of it as a static waveform anymore at this point, but as a selectable amount of harmonic content. You can allow more or less of this ‘harmonic content program’ (which, yeah, is actually a sampled waveform) in by playing the sample ‘faster’ (re-sampling, thus allowing larger portion/more of the waveform [or less] in before next reset) by playing up and down the keyboard, causing the re-sampling. Of course, you need transpose turned on in the phrase editor otherwise the pitch and timbre will be static all the way up the keyboard. Which could be useful, too, but currently isn’t very useful because of the way things are.

This will work best (or easier to hear the effect) if you are using a sample (or ‘harmonic content program’, which isn’t a real term) that starts simple and grows more complex. Or starts complex and becomes simple. Doesn’t matter, you can play it backwards to select content from back to front. Doesn’t have to be very long, 200 samples long might be more than enough, maybe, maybe. Sample loop points don’t have to be on because you are constantly restarting the waveform/content from the phraser, but it might sound cool to have them on. Playing too high up the keyboard will kind of mess it up and start being a regular single cycle sample oscillator again (if you have sample loop points on) or lose volume and turn into a buzz and lose sense of fundamental (if looping is off) or just sound granular. You probably want to play very low on the keys and or drop sample pitch an octave or 2.

And of course, a carefully designed ‘harmonic content program’ would produce better result (emulating filter cutoffs and such, sort of morphing waveforms, fake fm sounds).

Of course, you can’t really do much with this in Renoise world because you can’t control any of it in any useful way. But, Renoise can do a practical demonstration of how such a type of synthesis works.

Yes, more options to draw would already be an improvement.

Cool idea. So, by using different velocity zones a phrase can play different Waveforms, so some basic form of graintable sythesis is possible. Or via the 0Sxx command. The control seems really to be a problem. The tempo of phrases is fixed to the global tempo (is it?) and the velocities or 0Sxx commands in the phrase (and by this what wavedata) is played cannot be controlled from outside the phrase. And it seems hard to achieve but I’m bad at composing so that’s just me finding it hard.

deleted

deleted

probably just leave it as it is