[gmpi] Re: lost-n-found #3 parameter stuff

On Thu, Nov 04, 2004 at 10:41:43 +0100, Koen Tanghe wrote:
> > using atof() ;) seriously, this is not hard, many LADSPA hosts do this
> > today.
> 
> Please Steve, if we start arguing that way, we could as well dismiss of the
> param --> string conversion too and "just use printf", right? Of course *I*
> know when I should just use atof(), but the host doesn't always.
> 
> Let's say I have a string type parameter that takes chord sequences as
> textual input (like "Am7 C Gm" for example), and I want the user to be able
> to type this in. The host can provide a textbox and you're doing your atof()
> thing. Great...

Your "Am7 C Gm" is a string parameter, possibly linked to a set of
numerical parameters by a value-conversion-bridge that we allready have a
special case mechanism for, so the host doesnt need to do any conversion.

> And there are more examples where the plugin must do the interpretation of
> the given input string (without needing a special GUI object). The point is
> that the plugin should be able to decide how to handle given string inputs,
> and I thought we needed a mechanism to allow that (as we do for the
> "value-to-display string" case).

What special UI object? Its just a UI. Which is plugin controlled code. If
we support a set of types as well then that lets the host handle unit
conversion cases (eg min, sec, millisec) for wide valued ports too. Fine.

A situation I'd like to avoid is having

a) three classes of plugins: ones with no input parsers, ones with some
input parsers and ones with input parsers on all ports - leading to subtle
and anoying differences in behaviour in some hosts.

b) having to write input parsers for every control port in my plugins.

I dont recally ever having thought, as a users or developer "Hmm.. I wish
the *host* could parse this string and convert it to a numerical value for
the plugin". Thats what UIs are for.

- Steve 

----------------------------------------------------------------------
Generalized Music Plugin Interface (GMPI) public discussion list
Participation in this list is contingent upon your abiding by the
following rules:  Please stay on topic.  You are responsible for your own
words.  Please respect your fellow subscribers.  Please do not
redistribute anyone else's words without their permission.

Archive: http://www.freelists.org/archives/gmpi
Email gmpi-request@xxxxxxxxxxxxx w/ subject "unsubscribe" to unsubscribe

Other related posts: