[gst-devel] decodebin caps troubles with rtspsrc source

Nicolas Aguirre aguirre.nicolas at gmail.com
Sat Apr 12 11:50:07 CEST 2008


Hi there,

I try to write a little program in C that handles rtsp streams with gst and
I have some troubles.

I create a pipeline like this one : rtspsrc ! decodebin ! fakesink
In documentation rtspsrc have "sometimes" pad and should provide data only
when in PLAYING state, so I added an callback to "pad-added" signal and set
state of my pipeline to PLAYING. My "pad-added" signal is called, and in
this callback I link rtspsrc pad with sink pad of decodebin element.
Decodebin have signals for "new-decoded-pad" so I provide a callback for
this signal too. Callback is called and I detect caps. But here troubles
comes. Caps are not always the same. Sometimes I receive fixed caps with
only one height, width, framerate and fourcc values , and sometimes i
received ranges for these values. I woul like to know how to do to always
receive right and fixed values in decodebin caps ?

"new-decoded-pad" callback have "last" boolean, in his prototype, sould this
value is 1 when they are no more pad for decodebin element ? In my test this
boolean vallue is always FALSE. My stream have audio and video.

attached my source code.

If you have ideas ... :)

Best regards,
Nicolas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20080412/341a7951/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.c
Type: text/x-csrc
Size: 6563 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20080412/341a7951/attachment.c>


More information about the gstreamer-devel mailing list