Re: [LAD] Plugin 1/oct frequency controls (AMS/MCP/VCO)

From: Fons Adriaensen <fons@email-addr-hidden>
Date: Mon Aug 20 2012 - 19:06:23 EEST

On Mon, Aug 20, 2012 at 11:24:17AM -0400, David Robillard wrote:
> On Mon, 2012-08-20 at 10:18 +0000, Fons Adriaensen wrote:
> > On Mon, Aug 20, 2012 at 12:27:12AM -0400, David Robillard wrote:
> >
> > > tl;dr: I think the most reasonable standard for an absolute 1/oct
> > > frequency unit is 0.0 = 440Hz
> >
> > You're confusing two things: unit and reference point. The second
> > you have only on a log scale, for example if you use dB you need
> > to define what 0 dB means.
>
> Good point, but a "unit" in general can include a reference point as
> part of its definition. When used relatively, as with dB for e.g. gain,
> it's usually obvious what the reference point is. When used absolutely,
> sure, you need a reference point, but multiple reference points is hell.
>
> Augmenting "octaves" is probably a bad idea though, I will probably make
> a new unit for "octaves centered around <whatever>".
>
> > The unit here is 'octaves'. The reference point is not a property
> > of any port AFAICS. It could be a property of the plugin: the
> > frequency it is set to when all control inputs are zero.
>
> That is a sensible way of looking at it, but a plugin /could/ have two
> ports in octaves with different reference points.

If have som difficulty in imagining what that would mean in practice...
Could you give an example ?

As I see it, all (frequency) ports are relative. +1 means 'add an
octave to whatever you have'. If they are all zero (which means they
don't have any effect) you get the internal reference frequency.
What difference could there be between two ports, both 'octaves',
both zero, but having a different reference ?

> I guess, since it's your code... how do you feel about using 440 instead
> (at least in LV2 versions), and how difficult would this be to adjust?
> It's not immediately obvious to me what magic number twiddling would
> have to happen.

I you couild give a list of the ones you're working on, I could give you
the magic numbers.

Note that these plugins really were designed for AMS. Some controls (those
that map to GUI sliders etc) are 'control rate', the others are audio rate.
The latter ones are never used as such, they are subsampled and interpolated,
with the interpolation being done on the internal variables rather than the
inputs.

Alsa note that the VCO ones are really out of date. I have much better
replacements, but they'll have to wait.

> I realize in reality I am probably stuck with this (IMO ill-considered)
> convention... oh well. Seemed worth mentioning anyway.

The thing that matters is consistency. For example if you have something
that converts MIDI note numbers to a 'voltage', that should use the same
reference point as the plugins. I probably followed the convention used
by AMS' midi controller modules.

Ciao,

-- 
FA
A world of exhaustive, reliable metadata would be an utopia.
It's also a pipe-dream, founded on self-delusion, nerd hubris
and hysterically inflated market opportunities. (Cory Doctorow)
_______________________________________________
Linux-audio-dev mailing list
Linux-audio-dev@email-addr-hidden
http://lists.linuxaudio.org/listinfo/linux-audio-dev
Received on Mon Aug 20 20:15:03 2012

This archive was generated by hypermail 2.1.8 : Mon Aug 20 2012 - 20:15:03 EEST