[gst-devel] I need approach

Stefan Kost ensonic at hora-obscura.de
Sun Jun 29 14:19:16 CEST 2008


AlannY schrieb:
> Hi there.
> I'm writing a program, which consists of 2 parts: filling structure and 
> filter video with data from this structure ;-) It's easy to say, but not 
> so easy to implement.
> I found 2 ways to implement that program:
> 1. In my program fill structure and then grab video data with GStreamer 
> with help of *fakesink*. After data filtered, pass new data to the 
> *fakesrc* and mix video in container with GStremer. This way is good, 
> but, as I can see - this way is not GStremer like ;-) So, there are 
> second way:
> 2. In my program fill structure and than write a GStremer plugin, which 
> will filter data with data from my structure. This approach is more 
> GStremer based, but there are some questions I have.
> Main question is: how to pass to custom plugin my structure. Maybe 
> g_object_set will help me?
> g_object_set (G_OBJECT (my_custom_plugin), "structure", &structure, NULL);

Yes, you can pass arbitrary thing via g_object_set. Easiest is to add a gpointer 
property to your own element. But you can also make it a gobject (or a gboxed) 
so that the correct type can be checked.

Also your own processing element does not need to be an installed plugin, you 
can use an normal gobject class that is part of your code. So it the element is 
not that generic this would be easier.


uses that to make a plugin with one element for testing.


> Currently I can't test it, so, if it will not work - tell me ;-)
> Is there any better way to solve my problem(s)?
> Thank you.
> -------------------------------------------------------------------------
> Check out the new SourceForge.net Marketplace.
> It's the best place to buy or sell services for
> just about anything Open Source.
> http://sourceforge.net/services/buy/index.php
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel

More information about the gstreamer-devel mailing list