Re: [GnomeMeeting-devel-list] Towards a new video driver support in pwlib



Am Montag, 28. Juli 2003 17:17 schrieb Damien Sandras:
> Le lun 28/07/2003 ŕ 17:09, PUYDT Julien a écrit :
> > I had another idea: if the manager is called for whatever reason and its
> > list of plugins is empty, it loads them. That would be something like:
> > if (plugin_list == NULL) load_all_plugins();
> > at the beginning of each function... (or at least some of them)
>
> Loading the plugins can be done in the constructor, but problem, you can
> not load all plugins at the same time, only one at a time. You have one
> API and several implementations. The problem is that to detect the
> devices you have to load each of the plugins and see if they are able to
> use the device or not.

Of course it is no problem to load different plugins with the same api - you 
call the functions by pointers to them. Just dlopen the plugins (this gives 
you a handle for every plugin) and calling dlsym for the symbol you want.


> > This looks like perhaps I won't have that much to code to turn existing
> > drivers into plugins...
> >
> > Is there some problem I overlooked?

Perhaps it would be nice to have the api extendable, for example to add 
controls for some new camera device ...

> Perhaps what I told above, but I'm not sure...
>
> > Snark

Greetings,

Stefan

-- 
Stefan Brüns  /  Kastanienweg 6 - Zimmer 1206  /  52074 Aachen
mailto:lurch gmx li  http://www.kawo1.rwth-aachen.de/~lurchi/
      fax: +49-89-1488204565   phone: +49-160-7532733 

Attachment: pgpfamWT7mINC.pgp
Description: signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]