Re: [LAD] [ANN] LV2 beta3

From: Steve Harris <steve@email-addr-hidden>
Date: Fri May 11 2007 - 01:08:51 EEST

On 10 May 2007, at 22:44, Fons Adriaensen wrote:

> On Thu, May 10, 2007 at 03:58:25PM +0100, Steve Harris wrote:
>
>> I don't support it unless someone has a representation issue. You're
>> not like to see if (fs == 44100) anyway, and if you did you'd want to
>> hedge a bit: if (fs > 44090 && fs < 44110). If you have to write if
>> (fs_num / fs_denom == 44100) then things are bit dodgy anyway.
>
> Let me state once and for all, even it will not gain me any
> popularity:
>
> Anyone who thinks that writing a range check on a fraction A/B is
> too
> difficult is very probably completely incompetent and should not
> waste
> his/her time trying to write audio DSP code for a plugin.

I wasn't suggesting it was hard, just that doing the value check on
an integer is no easier than doing it on a double, so that's not an
argument in either direction.

> But if the word of Linux Audio wants to accommodate amateurism and
> ignorance at the expense of professionalism and experience, I will
> not hesitate a second to say goodbey. I'll feel sad for a few days
> but not much longer.

I'm not sure that it's reasonable to to describe representing sample
rates as a floating point number as amateurish. Switching to a
numerator/denominator pair is a bit of a departure, and will
significantly increase the effort of porting LADSPA plugins to LV2,
so I'm not keen until I understand the benefit in concrete terms.

I dislike boilerplate code that appears everywhere, and certainly all
my plugins would grow
double fs = (double)fs_denom / (double)fs_num; which seems a bit
pointless on the face of it.

I could probably run sed script to switch to num/denom format, but
it's almost zero effort to switch to a double, and none of my plugins
will derive any benefit whatsoever from the dum/denom pair. Do you
have an example of where knowing both factors is useful?

- Steve
_______________________________________________
Linux-audio-dev mailing list
Linux-audio-dev@email-addr-hidden
http://lists.linuxaudio.org/mailman/listinfo.cgi/linux-audio-dev
Received on Fri May 11 04:15:04 2007

This archive was generated by hypermail 2.1.8 : Fri May 11 2007 - 04:15:04 EEST