[gst-devel] dynamic overlaying of images on video

gael neuez gneuez at hotmail.com
Wed Aug 29 22:01:06 CEST 2007

>From: Tim Müller <t.i.m at zen.co.uk>
>To: gstreamer-devel at lists.sourceforge.net
>Subject: Re: [gst-devel] dynamic overlaying of images on video
>Date: Wed, 29 Aug 2007 13:47:39 +0100
> > My problem is that the position of each overlay sink pad is fixed to 
> > so all layers overlap each-others. I have modified the component such 
> > each pad has a fixed (hardcoded) position in the output frame. But this 
> > static, not dynamic...
>The videomixer sink pads all have "xpos", "ypos", "zorder" and "alpha"
>properties (which you can set in your code using g_object_set()). The
>documentation should probably mention that somewhere.

Yes, I've seen that in the code source of videomixer. But these properties 
are not seen as the plugin ones (using gst-inspect for example), these are 
pads properties. From my application code, how should I access to them? Pads 
are generated with random names when I link a new 'image pipeline' to it, so 
unless I access the GList of sinks and try to use g_object_set() on parsed 
list elements, I don't get right how to set these properties...

> > I was thinking of deriving the videomixer element, adding an additional 
> > sink pad. This pad would be fed with a txt file giving the (x,y) pos for
> > each image to be overlaid.
> > In fact, I'd also like to extend this to the pango textoverlay (for
> > displaying the name of the player below its thumbnail in the video, I 
> > need to specify the position where the text must be set).
> >
> > Would that make sense to you, or is there any better/nicer solution? Has
> > anyone experienced that kind of problem?
>There's also the textrender element which renders a text string to a
>bitmap, which you could then in turn feed into videomixer.  Or you could
>just put N textoverlay elements in a row after the videomixer, rendering
>the texts (settable via the "text" property) at whatever position you

Yes, I would try that, as soon as I can figure out the solution of the x/y 
pos properties.
I have another question relative to the text renderer. If I launch 
"gst-launch filesrc location=sampletext.txt ! textrender ! videomixer 
name=mix ! directdrawsink videotestsrc ! mix.", with the text file 
containing a single text line, this text is displayed on the video only for 
a few secs, then disappears. Is there a way to have it displayed 

Thanks again,

Windows Live Spaces : créez votre blog à votre image ! 

More information about the gstreamer-devel mailing list