[Suggestion] LFO Object !!

ZeroValue's icon

Am I the only that wish a LFO Object instead of using audio tools like phasor~ and after have to manage with audio data conversion, that's not radio friendly !!

We could have option like : waveform, direction, offset, rate, start/stop, depth.

Tell me what you think about it

Roman Thilenius's icon

it would probably not save much CPU to put phasor, modulo, mult and cycle into a single object, and it would be less flexible so that people would complain about missing features.

ZeroValue's icon

People could still use the audio version for flexibility .
The audio data conversion is most cpu consuming in my current patch. Maybe snapshot is not the best way to do it ?

Max Gardener's icon

In my experience, the problem with using snapshot is that everyone somehow thinks that setting the sample rate to a stupidly low interval is a good idea. Have you considered working with a more reasonable range and adding a slide object to the output? Might be worth a try.

ZeroValue's icon

I'm working in an interval 0. 1. and after the snapshot I multiply by 360* (working on azimuth in this case)
Do you have a small example ?

Roman Thilenius's icon


it does not matter if signal rate or data rate: building LFOs yourself is the way to go, and seems a far better solution than using a third party external.

Max Gardener's icon
ZeroValue's icon

When I started working on Lfo I found a bunch of examples and tutorial
I think this one was one of them
i‘ve made one that is quiet complete for me.
it’s ok with “this is the way to do it” but sometimes thing can change
I was just suggesting a new way :)

Roman Thilenius's icon


there are two main strategies for LFOs with different properties: use either line - or metro/counter as phase accumulator.

ZeroValue's icon

I’m using line for an other aspect of the patch
never try using counter. How to manage it ?

Roman Thilenius's icon


the line version is good for "fixed rate" and "proper float resolution", but because of that it wont reach the highest value at the peaks of angular waveforms.

with metro/counter this is possible, because there you can adapt the clock speed based on the current LFO speed parameter value - or even control single delta speeds so that you can modulate the LFO time almost like in a signal LFO during a cycle.

the good thing about all these complicated accumulator experiments is that when you once have it running, the phase-, amplitude- and waveform- math is the same every time, no matter how the phase accumulator was made. it is over wide parts even identically to an MSP patch based on phasor~.

Roman Thilenius's icon


ah, and before you get mad over [counter]... you can also try [metro] with [accum 0.], then you have float AND a timing resolution which can depend on LFO speed.

20 Hz -> metro 50
50 ms from 0. to 1. -> + 0.02 per step

reset, reverse direction, sync to another LFO, all very easy to add.

👽'tW∆s ∆lienz👽's icon

gen~ can also be used for this in its non-signal form [gen], since it has an internal metro you can instantiate it something like [gen @interval 20 @active 1] to give its internal metro 20ms interval and make it active right away, becomes an easy all-one-solution:

Max Patch
Copy patch and select New From Clipboard in Max.

Zancudo's icon

Hi Raja,

Shouldn't the signal for the sine come directly from the phasor and not the triangle?

Max Patch
Copy patch and select New From Clipboard in Max.

Roman Thilenius's icon


not if you want this interesting waveform.

SCNR


👽'tW∆s ∆lienz👽's icon

Shouldn't the signal for the sine come directly from the phasor and not the triangle?

if you want the most efficient calculation and don't intend to use the 'triangle' op at all for other waveforms, etc. then yes! but when i've generated these things in the audio-rate version, i enjoy the interesting twist that Roman has demonstrated by manipulating the 'triangle' op's 'duty cycle' inlet(this is why i just left it like that)

Zancudo's icon

Hi Roman,

In common northern mexican parlance, you have your mouth full of reason! (Tienes la boca llena de razón)
where would be any of us without interesting behavoiurs?!...

We should get you over to Belfast to share some of your insights. Fancy coming over for a seminar?

Very serious about it :)

👽'tW∆s ∆lienz👽's icon

where would be any of us without interesting behavoiurs?!

^indeed! such as this spelling of behaviours as 'behavoiurs'... nothing incorrect nor inefficient as we can appreciate being a 'voyeur' of interesting behaviours :D

Roman Thilenius's icon


only interesting behaviour leads to interesting behaviours - and that always was our mission.

or like i once said: you only have to play your music SO EXTREMLY LOUD that your neighbours think you are completely mentally ill, then they dont have the balls to complain about it any longer.

...

regarding raja´s gen patch. it might be not even the worst idea to implement e.g a "reverse" function right after the phase accumulator instead of creating different functions. and the tri wave, as a form of palindome phase, could be the third option. so there is really nothing "wrong" about this example.

👽'tW∆s ∆lienz👽's icon

to implement e.g a "reverse" function right after the phase accumulator

exactly, that's why i use the triangle at the heart of it all: with duty cycle at 1. it's reverse, at 0. it's forward, in between it can do all sorts of magic.