[gst-devel] Error whiling playing video

Eric Zhang nicolas.m.zhang at gmail.com
Tue Nov 11 07:05:51 CET 2008


Hi, gstreamer-devel:

    Thanks, Arnout! I got it.

Eric Zhang

2008/11/10 Arnout Vandecappelle <arnout at mind.be>

> On Monday 10 November 2008 03:58:18 Eric Zhang wrote:
> >     So could you explain a little bit why we should add this extra
> > capsfilter to make decodebin works? Thanks a lot.
>
>  If you think a bit about it, it's easy enough to understand.  gst-launch
> is
> completely agnostic about what all the pipeline elements do, but it somehow
> has to choose which sink pad to connect to which source pad of the rtspsrc.
> Look at the gst-launch command:
>
> gst-launch rtspsrc location="rtsp://xxxxxx" name=d
>  d. ! decodebin ! ffmpegcolorspace ! xvimagesink
>  d. ! decodebin ! audioconvert ! alsasink
>
> When rtspsrc creates a video source pad, gst-launch has to choose which of
> the
> two decodebins to connect to it.  Since they look identical (gst-launch
> can't
> look into the rest of the pipeline, who knows what decodebin will do
> anyway?), gst-launch randomly connect the video source to one of the
> decodebins.  After prerolling, the decodebin creates a source pad for the
> video and gst-launch has to connect it to the next element.  Now, if you're
> lucky, gst-launch had select the first decodebin and all goes well.  If
> you're unlucky, however, it has chosen the second decodebin, and gst-launch
> connects the audioconvert to the decodebin's video source pad...  That
> doesn't work, so the linking fails.
>
>  That doesn't crash your application yet.  It's only when the pipeline goes
> into PLAYING and the source starts pushing data in the decodebin, that it
> turns out that the decodebin doesn't have anywhere to send the data to.
> That's what triggers the 'Not linked' error.
>
>
>  When you use the depayloader and decoder explicitly instead of decodebin,
> the
> linking works correctly:
>
> gst-launch rtspsrc location="rtsp://xxxxxx" name=d
>  d. ! rtph263pdepay ! ffdec_h263 ! ffmpegcolorspace ! xvimagesink
>  d. ! rtpamrdepay ! amrnbdec ! audioconvert ! alsasink
>
> Now, the two branches of the pipeline are no longer identical.  gst-launch
> looks at the caps of rtph263pdepay and rtpamrdepay to see which one matches
> the video source.  It will therefore always select the right one.  You get
> the same behaviour with a decodebin by providing caps explicitly.
>
>
>  Regards,
>  Arnout
>
> --
> Arnout Vandecappelle                               arnout at mind be
> Senior Embedded Software Architect                 +32-16-286540
> Essensium/Mind                                     http://www.mind.be
> G.Geenslaan 9, 3001 Leuven, Belgium                BE 872 984 063 RPR
> Leuven
> LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
> GPG fingerprint:  D206 D44B 5155 DF98 550D  3F2A 2213 88AA A1C7 C933
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20081111/86c5f829/attachment.htm>


More information about the gstreamer-devel mailing list