GNOME Bugzilla – Bug 609639
xviddec plugin caps does not allow MPEG 4 video - trivial fix
Last modified: 2011-05-23 15:31:17 UTC
The XVid Plugins use their own caps "video/x-xvid", however as XVid is an implementation of MPEG4 it would be useful for the caps to allow for MPEG4 as well. The Encoder does currently allow the src caps to be MPEG4, however the Decoder sink caps only allows xvid. As MPEG4 decoders are defined by the specification I believe that simply changing the caps to allow MPEG4 should work. This would be useful as the XVID decoders are very efficient and could be used instead of ffdec_mpeg4. The fix is absolutely trivial, I've tested it by adding the following caps to the decoder's sink template in "/gstpluginsbad/ext/xvid/xviddec.c": "video/mpeg, " "mpegversion = (int) 4, " "systemstream = (boolean) FALSE, " "width = (int) [ 0, MAX ], " "height = (int) [ 0, MAX ], " "framerate = (fraction) [ 0/1, MAX ] This then works with the following pipelines: gst-launch videotestsrc ! ffenc_mpeg4 ! xviddec ! ffmpegcolorspace ! xvimagesink gst-launch videotestsrc ! xvidenc ! 'video/mpeg, mpegversion=(int)4' ! xviddec ! ffmpegcolorspace ! xvimagesink Nick
commit 4e01ce3fd267729d2ddc264ddf87bfd8b51e2d05 Author: Sebastian Dröge <sebastian.droege@collabora.co.uk> Date: Mon May 23 17:29:56 2011 +0200 xviddec: Add video/mpeg,mpegversion=4 to the caps Fixes bug #609639.