After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 692294 - [xvidenc] Sink pad getcaps prevents caps renegotiation
[xvidenc] Sink pad getcaps prevents caps renegotiation
Status: RESOLVED OBSOLETE
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
0.10.x
Other Linux
: Normal normal
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2013-01-22 14:03 UTC by Roland Elek
Modified: 2014-01-25 14:08 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Roland Elek 2013-01-22 14:03:50 UTC
After negotiating the sink pad of xvidenc to a specific caps, it refuses to renegotiate to any other caps, e.g. with a different frame rate. This is caused by the following part of the getcaps function in gstxvidenc.c, starting on line 990 for me:

  /* If we already have caps return them */
  if (GST_PAD_CAPS (pad))
    return gst_caps_ref (GST_PAD_CAPS (pad));

According to http://cgit.freedesktop.org/gstreamer/gstreamer/tree/docs/random/negotiation?h=0.10 , "get_caps() functions should always ignore the currently negotiated caps of a link", which is not what is happening here. With these lines commented out, the element successfully renegotiates to a different frame rate, and produces a playable stream.
Comment 1 Sebastian Dröge (slomo) 2014-01-25 14:08:47 UTC
xvid is not ported to 1.0 yet, and as part of that it would need to be ported to the videoencoder base class... which will automagically fix this bug.

Also it's valid to not allow changing the caps once they're set... for the case when the encoder can't reconfigure itself.