Page 3 of 7

Re: Oscillators

Posted: Wed Oct 22, 2014 12:36 am
by RJHollins
I've been looking forward this this section ... particularly the PINK generator.

I hope to get to this tonite, as I've noticed that different 'generator' actually sound different :shock:

Something else I'm looking at ...

I use pink-noise as a source to do quick'n'dirty gain staging through an effects chain [old school technique from back in the pure analogue daze].

One of the issue I'm watching is the changing level output. I understand the randomness required, but I'd like to get a more steady output level [minimal fluctuation]. Will look at this Martin creation tonite.

THANKS!!!
:)

BTW ... quick look ... NICE radio button design and function 8-)

Re: Oscillators

Posted: Wed Oct 22, 2014 6:32 pm
by KG_is_back
You may also create Brownian noise. With a simple 1-pole lowpass filter (integrator) after white noise generator.

Re: Oscillators

Posted: Wed Oct 22, 2014 7:20 pm
by martinvicanek
Thanks, Nix, for mentioning Brown noise. I think it can be useful so I added it in the original post.

KG_is_back wrote:You may also create Brownian noise. With a simple 1-pole lowpass filter (integrator) after white noise generator.
Right. I have used a slightly fancier integrator, though, one that goes all the way up to Nyquist. Probably does not make much difference, but anyway.

RJHollins wrote:BTW ... quick look ... NICE radio button design and function 8-)

Thank you. :)

Re: Oscillators

Posted: Wed Oct 22, 2014 11:10 pm
by tulamide
Phew... with all these new things to learn, I can't keep up with the pace! KG's excellent ASM course, your brilliant oscillator course. But now, after having released the spline class, I will take the time to study all that I have missed. Thank you!

Low-Frequency Oscillators

Posted: Thu Oct 23, 2014 9:08 pm
by martinvicanek
(MV's Oscillators Part IV)

A low-frequency oscillator delivers a control signal to modulate sound. For example, a periodic amplitude or frequency modulation results in a tremolo or vibrato effect, respectively. Modulation, even if applied in subtle amounts, can add “life” to an otherwise sterile sound. This is particularly important in synthesisers, but is also applied to “natural” instruments in effect pedals etc. to make them sound “phat”.

Since LFOs operate in the time domain, aliasing or spectral purity is not a concern. However, LFO waveforms with discontinuities may result in unwanted clicks further down the processing chain. Even worse, if applied to the cutoff frequency of an ordinary biquad filter, a single discontinuity may interrupt the audio stream. Therefore, some sort of (preferably adjustable) smoothing is necessary for such waveforms.

LFO waveforms need not be periodic. In fact, periodic modulation is predictable and may sound boring or even annoying (ever listened to a pan-modulated Fender Rhodes with earphones?).

In the schematic below I have included some common waveforms as well as a number of random LFO waveforms.

As (a slight variation of :twisted: ) the signature of a prominent forum member says: Don't stagnate, create and modulate. Without randomness and serendipity the earth would be just another barren rock.

Edit: Added a bugfixed schematic (thx adamszabo for the report).

Re: Oscillators

Posted: Fri Oct 24, 2014 12:12 am
by tester
...which leads me to a question worth to ask I guess.

If stock shape oscillators are used, then after them - should be some sort of "de-zipper" added (stock? not so stock due to 1ms resolution of stock?), with transition time calculated from both - shape size (in samples) and frequency used for modulation?

I guess this refers to some rare cases only (i.e. I guess there are enough steps within jnd range / "just noticable difference" to give the impression of smoothness).

As for noises. Interesting one is called "grey noise" (equal loudness patterns), but it's somewhat subjective I guess.

I will definately check your randomness... :-) I remember I used dezipper and value trigger to achieve some interesting effects (and I guess some sort of curve shaper between points could be used too).

Re: Low-Frequency Oscillators

Posted: Fri Oct 24, 2014 3:39 am
by MyCo
martinvicanek wrote:Since LFOs operate in the time domain, aliasing or spectral purity is not a concern. However, LFO waveforms with discontinuities may result in unwanted clicks further down the processing chain.


Why are you using the BLEP code for the LFO then? Wouldn't it be cheaper to use the naive wave forms and pass them through a first order lowpass?

Here's a code suggestion for the sync parts (haven't checked how you do it in the ASM though):
Instead of:

Code: Select all

s = 1&(sync>0);
saw = saw0 - phase;
saw = saw + (-0.25 - saw)*s*(1 - s1);
s1 = s;


you can do:

Code: Select all

saw = saw0 - phase;
saw = saw + (-0.25 - saw) & ((sync<=0) | (s1>0));
s1 = sync;


When you do the sync input as streamboolin like the stock oscs, it can be even simpler:

Code: Select all

saw = saw0 - phase;
saw = saw + (-0.25 - saw) & ((sync==0) | s1);
s1 = sync;


Disclaimer: untested code!
BTW: I don't think the sync even works with the BLEP LFOs, because the cycle length of the BLEP get's completely messed up.

Re: Oscillators

Posted: Fri Oct 24, 2014 8:39 am
by Tronic
this algorithm help to make the hard sync version
Polynomial Transition Regions (PTR)...http://research.spa.aalto.fi/publicatio ... s/spl-ptr/

Re: Oscillators

Posted: Sat Oct 25, 2014 12:55 am
by Tronic
and here the better implementation
(EPTR) EFFICIENT POLYNOMIAL TRANSITION REGION ALGORITHM
http://smcnetwork.org/system/files/IMPR ... THESIS.pdf

Re: Oscillators

Posted: Sun Oct 26, 2014 2:12 pm
by martinvicanek
Thanks for your comments guys. MyCo, Your suggestion to use a 1st order LP is valid, because it also works for the sync. I believe sync and s1 should be the other way around but I see your point, thanks. Tronic, thank you for the links, will check them out.