[mythtv] New plugin scheme / Filter selection interface?

Andrew Mahone andrewmahone at eml.cc
Fri Jan 30 19:46:43 EST 2004


On Fri, 30 Jan 2004 13:02:17 -0500, "Joseph A. Caputo"
<jcaputo1 at comcast.net> said:
> Cool, I'll have a look at it.
>
> -JAC

The filters README should have everything you need for this, but if I
missed anything in there, just ask.  It's a pretty simple interface,
the FilterManager class has a method that provides a list of
FilterInfo structs.

Keep in mind also that it may not simply be a matter of
enabling/disabling filters and specifying an order for them.  It is
perfectly valid to have multiple instances of a filter in the filter
chain, so we need something along the lines of being able to select
any available filter, add parameters to it, and insert it into the
filter chain.

As far as a GUI for parameters, I'd like to come up with a reasonably
flexible standard way for filters to describe their options.  I think
most options could be handled by the following types:

boolean: GUI would display as checkbox

integer: filter provides valid range, GUI would display a slider
or a spinbox

float: filter provides valid range, GUI would display as slider

enum: filter provides a list of string values, GUI would display
as combobox

A default value should also be provided for each option, and the GUI
should display a "reset to default" button.  Any thought on the best way
to describe these?  I'd like something compact that can get stuffed into
a string in the FilterInfo structure.  I think the GUI could be set up to
create colon-delimited lists of options, as used by many filters already.
I could set up some convenience macros for parsing such lists in
filter.h, although it shouldn't really be necessary.  I'm guessing from
the way that video codec options seem to work that building a GUI from a
list of options as described above shouldn't be too hard, right?
-- 
  Andrew Mahone
  andrewmahone AT eml DOT cc

-- 
http://www.fastmail.fm - mmm... Fastmail...


More information about the mythtv-dev mailing list