[mythtv] Better Integration of plugins
Isaac Richards
ijr at case.edu
Fri Feb 25 00:58:02 UTC 2005
On Thursday 24 February 2005 07:24 pm, Paul Volkaerts wrote:
> A common set of clases to handle drawing on top of TV or on QT is
> definately a good idea.
>
> But how to handle multiple plugins all wanting to access the display is the
> problem as I see it; and I can think of two options:
>
> (2)Or, you have one thread that owns the display and other threads sends
> requests to display information. This means plugins must be able to run as
> a worker function; but it gets round the control issues in (1). This is
> definately how my mods work; but I chose this method based on it being
> simple and not the best way.
This is how mythui works (kinda). Check out the drawTimeout() function in
mythmainwindow.cpp in libs/libmythui/. No actual drawing happens outside of
that function (but the UI objects can be updated, etc, outside of it).
Actually, look at the rest of the architecture there, it'd be easier than me
explaining, and it's all fairly simple.
Anyway - with mythui, it'll display whatever's 'on-top' (which can be multiple
distinct objects), and pass down control events to whichever object has
focus. There's nothing that says that if multiple things are displaying that
they have to be in the same plugin/whatnot.
Isaac
More information about the mythtv-dev
mailing list