[gstreamer-sharp] Retrieve codec format, profile and level of H.264 and MPEG4 encodes

Age Bosma agebosma at gmail.com
Mon Aug 29 10:50:43 PDT 2011


Hi,

I'd like to be able to determine which codec format, profile and level
are used for video files encoded in H.264 and MPEG4. The information
provided by the tags and caps do not contain it.

Is it possible to use gstreamer for this and, if yes, how?

What I've got so far can be found here: http://pastebin.com/e8UwsqsN

Using this it will only provide me with the following info of an H.264
video file:

audio-codec         : MPEG-4 AAC audio
maximum-bitrate     : 3768000000
bitrate             : 96958
language-code       : en
width               : 320
height              : 180
framerate           : 1001/40
format              : 024I
interlaced          : False
pixel-aspect-ratio  : 1/1

It does contain the format but it is the format of the raw stream.

I'm using the latest HEAD (2011-08-16) of gstreamer-sharp from the
repository [1], with gstreamer 0.10.32 installed (Ubuntu 11.04).

Code notes:
- GstDiscoverer is not being used for the technical metadata because
gstreamer-sharp has not been updated to 0.10.31 yet. GstDiscoverer also
doesn't provide profile and level info in the first place.
- Playbin2.GetVideoTags() is not being used to get the tags of the
stream because it will result in segmentation faults [2].

I hope you can help me out.

Yours sincerely,

Age Bosma


[1] http://cgit.freedesktop.org/gstreamer/gstreamer-sharp/
[2] https://bugzilla.gnome.org/show_bug.cgi?id=657493

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 554 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20110829/ea269cb8/attachment.pgp>


More information about the gstreamer-devel mailing list