[gst-devel] Plugins in Python
bilboed at gmail.com
Sun May 28 10:26:04 CEST 2006
If you explained what application and plugin you're trying to build
we might be able to give you more details as to whether using
gstplugins is the good idea or not.
P.S. : Answer to me and mailing-list at the same time (reply to all).
On 5/28/06, Oscar Acena <oscaracena at yahoo.es> wrote:
> Thanks for answer so fast! The thing is that i think that i really need
> a plugin :-p
> I want to do a (what i think it must be a) plugin to use in other
> applications. The task the "plugin" must do is comunicate with another
> app in a special way, but the thing is that it should be used in other
> applications, so i thought that a plugin will do. Please, tell me if i'm
> wrong ;-) and thanks.
> Edward Hervey escribió:
> > Hi,
> > On 5/28/06, Oscar Aceÿfffff1a <oscaracena at yahoo.es> wrote:
> >> Hello,
> >> Well, i've wondered this many times. Then, should i presume that already
> >> exists one plugin writted in python and, therefore, for python? If
> >> so, where
> >> can i get it? I'm about to write an app in python too, and i need to
> >> write a
> >> plugin, in python if possible!
> > Let's get things straight first :) You CAN create elements entirely
> > in python, you just have to create a class that derives from
> > gst.Element (or one of the convenience classes, like gst.BaseSrc). ex:
> > class MyElement(gst.Element): ....
> > To create elements from that class you just... instantiate one.
> > myelement = MyElement().
> > And those elements can be used as any other gst.Element (like the
> > ones coming from gst.element_factory_make()).
> > A gst.Plugin is NOT needed to create gstreamer elements you can use
> > in a pipeline (some C applications already do that for application
> > specific elements).
> > The only need for a plugin, is to be able to use the element
> > class(es) that plugin provides in other gstreamer-based software,
> > through the use of the gst.Registry. It is NOT a requirement to be
> > able to use element classes in your progrm. If you want to use those
> > element classes in your program, you don't need plugins, you link them
> > statically to your C program.
> > So if you want to write element classes in python and use them in
> > your python program... you already can.
> > Do you understand the difference between a Plugin and an element
> > class now ?
> >> Another question: I have seen that to write a plugin, exists a template;
> >> this template, it is only writted for C? If so, can i port it to python?
> >> This could be useful for at least two persons! :-)
> > Once the python plugin loader is there... I guess we'll get round to
> > creating a template (which is going to be 50 lines more or less...).
> >> And the last question: if this is possible, how can i load the plugin
> >> to use
> >> in a normal pipe?
> > Read the paragraph about "plugin != element" above once more.
> >> Thanks in advance to all!
> >> Edward Hervey <bilboed at gmail.com> escribió:
> >> HI,
> >> Currently you can create most type of elements entirely in Python.
> >> But we don't have a python plugin loader currently, so you will only
> >> be able to use it from a python application (importing the python file
> >> where you wrote yor element).
> LLama Gratis a cualquier PC del Mundo.
> Llamadas a fijos y móviles desde 1 céntimo por minuto.
Junior developer / Fluendo S.L.
More information about the gstreamer-devel