[mythtv] Plugin architecture, info
Joseph A. Caputo
jcaputo1 at comcast.net
Thu Aug 7 23:30:01 EDT 2003
On Thursday 07 August 2003 18:17, Calvin Harrigan wrote:
> Looking over the archives it seems that since mythtv .10 there is support
> for a plugin system. Is there some documentation somewhere that details how
> to use the plugin system what's functions are available etc. Something
> like a developers faq? I'm working on implementing what I've termed so far
> as MythPower, a power management system for mythtv, I figure if I made it
> a plugin it would be a breeze to use with mythtv as opposed to a standalone
> program.
Plugin basics:
Your plugin should export the following symbols (functions):
extern "C" {
int mythplugin_init (const char *libversion);
int mythplugin_run ();
int mythplugin_config ();
};
The plugin module is built as a shared object/dynamic link library. The
mythplugin_init() function is called (once) when the module is initially
loaded into memory. The mythplugin_run() function is the main function of
your module. The mythplugin_config() function is the main function for your
module's setup gui.
That's the basics. Take a look at the makefile and main.cpp file of any of
the Myth modules for examples.
-JAC
More information about the mythtv-dev
mailing list