v4l2codecs: H264 does not play with playbin on iMX8M
Describe your issue
Using 1.24.1, H264 videos no longer play with playbin. This issue is not present in 1.24.0.
Setup
iMX8MQ based board with enabled Hantro stateless decoders.
Steps to reproduce the bug
Play any H264 video, tried various levels, bitrates etc.
Error log
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
0:00:00.128244845 280 0xffffb4000d10 FIXME matroskademux matroska-demux.c:683:gst_matroska_demux_parse_colour:<matroskademux0> Unsupported subelement 0x55b7 in Colour
0:00:00.128348285 280 0xffffb4000d10 FIXME matroskademux matroska-demux.c:683:gst_matroska_demux_parse_colour:<matroskademux0> Unsupported subelement 0x55b8 in Colour
0:00:00.128381405 280 0xffffb4000d10 WARN matroskademux matroska-demux.c:1465:gst_matroska_demux_parse_stream: Unknown TrackEntry subelement 0xec - ignoring
0:00:00.134819766 280 0xffffb4000d10 WARN h264parse gsth264parse.c:2708:gst_h264_parse_update_src_caps:<h264parse0> VUI framerate 90000.0 exceeds allowed maximum 30.1
Redistribute latency...
0:00:00.144497886 280 0xffffb4000d10 ERROR v4l2codecs-h264dec gstv4l2codech264dec.c:453:gst_v4l2_codec_h264_dec_decide_allocation:<v4l2slh264dec0> DMABuf caps negotiated without the mandatory support of VideoMeta
0:00:00.144558726 280 0xffffb4000d10 WARN videodecoder gstvideodecoder.c:4392:gst_video_decoder_negotiate_pool:<v4l2slh264dec0> Subclass failed to decide allocation
0:00:00.144590526 280 0xffffb4000d10 ERROR v4l2codecs-h264dec gstv4l2codech264dec.c:942:gst_v4l2_codec_h264_dec_new_sequence:<v4l2slh264dec0> Failed to negotiate with downstream
0:00:00.144618366 280 0xffffb4000d10 WARN h264decoder gsth264decoder.c:2517:gst_h264_decoder_process_sps:<v4l2slh264dec0> subclass does not want accept new sequence
0:00:00.144644406 280 0xffffb4000d10 WARN h264decoder gsth264decoder.c:652:gst_h264_decoder_parse_sps:<v4l2slh264dec0> Failed to process SPS
0:00:00.144670086 280 0xffffb4000d10 WARN h264decoder gsth264decoder.c:721:gst_h264_decoder_parse_codec_data:<v4l2slh264dec0> Failed to parse SPS
0:00:00.144696606 280 0xffffb4000d10 WARN h264decoder gsth264decoder.c:1496:gst_h264_decoder_set_format:<v4l2slh264dec0> Failed to handle codec data
0:00:00.146840406 280 0xffffb4000d10 FIXME matroskareadcommon matroska-read-common.c:762:gst_matroska_read_common_parse_skip:<matroskademux0:sink> Unknown CueTrackPositions subelement 0xf0 - ignoring
0:00:00.146895966 280 0xffffb4000d10 FIXME matroskareadcommon matroska-read-common.c:762:gst_matroska_read_common_parse_skip:<matroskademux0:sink> Unknown CueTrackPositions subelement 0xf0 - ignoring
0:00:00.147120846 280 0xffffb4000e90 WARN h264parse gsth264parse.c:2708:gst_h264_parse_update_src_caps:<h264parse0> VUI framerate 90000.0 exceeds allowed maximum 30.1
Redistribute latency...
0:00:00.147804846 280 0xffffb4000e90 WARN h264parse gsth264parse.c:2708:gst_h264_parse_update_src_caps:<h264parse0> VUI framerate 90000.0 exceeds allowed maximum 30.1
0:00:00.149125086 280 0xffffb4000e90 WARN v4l2codecs-h264dec gstv4l2codech264dec.c:958:gst_v4l2_codec_h264_dec_new_sequence:<v4l2slh264dec0> GstVideoMeta support required, copying frames.
Redistribute latency...
0:00:00.149485206 280 0xffffb4000e90 WARN h264decoder gsth264decoder.c:1126:gst_h264_decoder_start_current_picture:<v4l2slh264dec0> subclass does not want to start picture
0:00:00.149521326 280 0xffffb4000e90 WARN h264decoder gsth264decoder.c:1341:gst_h264_decoder_parse_slice:<v4l2slh264dec0> start picture failed
0:00:00.149684766 280 0xffffb4000d10 WARN matroskademux matroska-demux.c:6115:gst_matroska_demux_loop:<matroskademux0> error: Internal data stream error.
0:00:00.149724966 280 0xffffb4000d10 WARN matroskademux matroska-demux.c:6115:gst_matroska_demux_loop:<matroskademux0> error: streaming stopped, reason not-negotiated (-4)
Info
Playing any other HW accelerated format such as VP8, VP9 and H265 works fine with playbin. Using playbin3, H264 videos work as expected but playing any H265 or VP9 videos always does a colorspace conversion from NV12_4L4.