[gst-devel] XVID plugin and one question

Ronald Bultje rbultje at ronald.bitfreak.net
Tue Apr 30 14:49:02 CEST 2002


Hi Gianluca,

On Tue, 2002-04-30 at 15:51, g.insolvibile at cpr.it wrote:
> this is my first mail on the list, so before asking my question I
> would like to thank all the gstreamer proud developers for their great
> work. The whole framework is awesome!

Once again, thanks. :-).

> I am putting together a small xvid-based video decoder, which shall be
> capable of handling "DivX5" video streams. At the moment, my plugin
> works only if fed by a filesrc element, like this:
> 
> gst-launch filesrc location=xXx_trailer.m4v ! xviddec ! sdlvideosink
> 
> where xXx_trailer.m4v is the raw MPEG-4 visual stream extracted from 
> an AVI (.divx) file. Instead, if I try something like:
> 
> gst-launch filesrc location=xXx_trailer.m4v ! avidemux video_00!
> xviddec ! disksink location=test
> 
> I get errors because the xviddec sink did not get connected to the
> video_00 source.

First off, you probably want to use a queue here and a separate thread
for when you start using audio later on. It looks like this then:

gst-launch filesrc location=video.avi ! avidemux video_00! { queue !
xviddec ! sdlvideosink }

Now, why doesn't it connect? Probably because of GstCaps
incompatibilities. You probably want to run this pipeline with
gst-mask=-1 (debugging mode) and save it to a file, so:

gst-launch --gst-mask=-1 filesrc location=video.avi ! avidemux video_00!
{ queue ! xviddec ! sdlvideosink } > file.log

I expect the caps of avidemux and xviddec to be incompatible. If you can
put the code of the current xviddec plugin somewhere online, we can
check it for errors on the capsnego side. I expext the error to be
there...

> this case, should I register to receive a "new_pad" signal from 
> avidemux ?  If yes, when should I do it and how could I get a
> reference to the avidemux element from within my plugin ?

That's something that applications or autopluggers would do... I don't
think you need to do it inside a plugin.

> Btw, I am using gstreamer and gst-plugins version 0.3.3. Before
> switching to the newer 0.3.4 (or to the CVS) I would like to complete
> at least an alpha version of the plugin. If there is some reason to
> upgrade earlier, please let me know.

0.3.3 should work. I don't know of any problems with avimux in 0.3.3. Of
course after getting it to work, you should definately make it 0.3.4
compatible. ;-).

Ronald (or, as Andy Wingo calls me, BBB)

-- 
-   .-.
-   /V\    | Ronald Bultje <rbultje at ronald.bitfreak.net>
-  // \\   | Running: Linux 2.4.18-XFS and OpenBSD 3.0
- /(   )\  | http://ronald.bitfreak.net/
-  ^^-^^





More information about the gstreamer-devel mailing list