Decodebin2 & multimedia format detection

Matěj Kubička matej at matejk.cz
Fri Apr 6 06:43:24 PDT 2012


Hello,
I have found myself in a bit of a struggle with GStreamer's decodebin2. 
Basically, I need to detect if a file I gave to decodebin2 have 
following properties:

a) whether it is a multimedia format or not
b) more specifically, if it contains video streams

Latter case I solved quite simply - just checked caps of newly added pad 
by decodebin2.

But first case seems to be rather problematic. Originally, I've put my 
hopes into "unknown-type" signal, but after a quick check in 
documentation, it doesn't really do what I hoped for.

When I give to decodebin2 a media format which is for sure unknown for 
GStreamer (like a c-file for instance :-)), the pipeline sends me an 
error on the bus. The error code is "1".

Is the meaning of error code "1" directly "unknown media format"? Is 
there a list of error codes somewhere available? Or, can you point me 
where are the error codes defined in the source code?

Thank you very much,
Matej.

--
www.matejk.com


More information about the gstreamer-devel mailing list