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 705425 - x264enc: doesn't consider subset relations of profiles during negotiation
x264enc: doesn't consider subset relations of profiles during negotiation
Product: GStreamer
Classification: Platform
Component: gst-plugins-ugly
git master
Other Linux
: Normal major
: 1.0.10
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Reported: 2013-08-03 22:55 UTC by David Schleef
Modified: 2013-08-27 13:21 UTC
See Also:
GNOME target: ---
GNOME version: ---

Description David Schleef 2013-08-03 22:55:12 UTC
Both of these pipelines fail to get to PLAYING:

gst-launch-1.0 -v \
  videotestsrc ! \
  x264enc speed-preset=1 ! \
  video/x-h264,profile=main ! \
  fakesink silent=false

gst-launch-1.0 -v \
  videotestsrc ! \
  x264enc ! \
  video/x-h264,profile=baseline ! \
  fakesink name=sink0 silent=false
Comment 1 David Schleef 2013-08-03 23:53:28 UTC
I tracked this down to gst_codec_utils_h264_caps_set_level_and_profile() creating caps that are not the same as the filter caps.  In both cases (but for different reasons), the profile is set to contrained-baseline.

I'm somewhat surprised this doesn't cause a negotiation error.
Comment 2 Tim-Philipp Müller 2013-08-21 11:36:17 UTC
> I'm somewhat surprised this doesn't cause a negotiation error.

commit e0ae81ebacbe48300aece22dfef519088d8c5ae8
Author: Tim-Philipp Müller <>
Date:   Wed Aug 21 12:31:23 2013 +0100

    x264enc: propagate flow return back to base class and upstream
Comment 3 Sebastian Dröge (slomo) 2013-08-21 14:09:23 UTC
So additionally x264enc should check if it outputs constraint-baseline if downstream actually wants baseline. And if it does, just put that in the caps. As constrained-baseline is a strict subset of baseline there should be no problem, right?
Comment 4 Sebastian Dröge (slomo) 2013-08-21 16:35:33 UTC
commit aab5534573e318402ab5795f3310a739c8e8dc06
Author: Sebastian Dröge <>
Date:   Wed Aug 21 18:32:17 2013 +0200

    x264enc: Consider subset relations of profiles when setting srcpad caps
    constrained-baseline is a subset of baseline, is a subset of main,
    is a subset of high profile.
Comment 5 Tim-Philipp Müller 2013-08-21 16:51:24 UTC
Bit unfortunate that now the profile signalled in the codec data / SPS doesn't match the caps, but I'd be surprised if anything cares..
Comment 6 Sebastian Dröge (slomo) 2013-08-21 17:14:37 UTC
Well, we could change the codec data and SPS too if you think that's a good idea ;)
Comment 7 Tim-Philipp Müller 2013-08-27 13:21:32 UTC
Cherry-picked into 1.0 branch.