mirror of
https://github.com/openwrt/packages.git
synced 2026-11-28 23:03:27 +04:00
The stateless H.264 and H.265 decoders negotiate as soon as they parse a sequence. With codec data in the caps, that happens while decodebin pushes the sticky events into the decoder, before its src pad is exposed, so the allocation query goes unanswered and the decoder refuses DMABuf output for lack of GstVideoMeta. Add the upstream patch deferring the negotiation to the first picture, as the AV1 decoder already does. The Raspberry Pi HEVC decoder offers 8-bit and 10-bit pictures in Broadcom's column layout, which v4l2codecs knows only as a DMA_DRM format without a video format, or not at all. Add the patches mapping the decoder's NV12MT_COL128 and NV12MT_10_COL128 to the libgstvideo column formats, passing the slice bit size and data offset in the meaning the driver expects for them, and translating column strides for Wayland dma-buf import. The plugins need a libgstvideo that knows those formats. Make the probed caps writable before v4l2codecs filters them: when none of a decoder's capture formats is known, they are the shared empty caps, and GStreamer reports two CRITICAL assertions. Put each decoder's maximum frame size, as VIDIOC_ENUM_FRAMESIZES reports it, into its sink template, so that autoplugging picks a decoder able to take the stream: on RK3568 the Hantro H.264 decoder takes up to 1920x1088 and rkvdec up to 4096x2304. Keep the VP9 and AV1 decoders' buffers when downstream renegotiates while they stream; a second set next to the one in use runs into the VB2 limit of 32 buffers per queue. Renegotiate when a decoder starts again after a stop, and let the AV1 decoder drop frames up to the next keyframe when an inter frame changes the size and the driver cannot remove buffers, as the VP9 decoder does. Build and package the DASH demuxer, the legacy dashdemux element that works in playbin, along with the isoff library it links. Fixes:d86f866af1("gst1-plugins-bad: update to 1.17.1") Fixes:e7f535c3f6("gst1-plugins-bad: update to 1.26.2") Link: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/12917 Link: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9247 Link: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/13069 Signed-off-by: Daniel Golle <daniel@makrotopia.org>