platform/upstream/gstreamer.git
3 years agova: Delete the useless align expand in va_pool_set_config().
He Junyan [Wed, 2 Jun 2021 16:07:05 +0000 (00:07 +0800)]
va: Delete the useless align expand in va_pool_set_config().

The base va decoder's video_align is just used for calculation the
real decoded buffer's width and height. While the gst_video_info_align
just calculate the offset and stride based on the video_align. But
all the offsets and strides are overwritten in gst_va_dmabuf_allocator_try
or gst_va_allocator_try, which make that calculation useless.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2298>

3 years agowebrtc: Re-add WebRTC object docs to the public headers
Sebastian Dröge [Mon, 28 Jun 2021 14:41:38 +0000 (17:41 +0300)]
webrtc: Re-add WebRTC object docs to the public headers

So they end up in the generated documentation and the Since markers
appear in the .gir files too.

Also remove wrong "Since: 1.16" markers for some objects that were
available since 1.14.0 already.

Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/issues/1609

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2366>

3 years agowebrtcbin: Set transceiver kind and codec preferences immediately when creating it
Sebastian Dröge [Fri, 25 Jun 2021 07:20:06 +0000 (10:20 +0300)]
webrtcbin: Set transceiver kind and codec preferences immediately when creating it

Otherwise the on-new-transceiver signal will always be emitted with kind
set to UNKNOWN and no codec preferences although both are often known at
this point already.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2360>

3 years agowebrtcbin: Add a test for setting codec preferences as part of "on-new-transceiver...
Sebastian Dröge [Fri, 25 Jun 2021 09:14:03 +0000 (12:14 +0300)]
webrtcbin: Add a test for setting codec preferences as part of "on-new-transceiver" when setting the remote offer

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2310>

3 years agowebrtc: Use fail_unless_equals_string() for string assertions
Sebastian Dröge [Fri, 25 Jun 2021 09:13:42 +0000 (12:13 +0300)]
webrtc: Use fail_unless_equals_string() for string assertions

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2310>

3 years agowebrtcbin: Store newly created transceivers when creating an answer also in the seen...
Sebastian Dröge [Tue, 8 Jun 2021 08:40:14 +0000 (11:40 +0300)]
webrtcbin: Store newly created transceivers when creating an answer also in the seen transceivers list

Otherwise it might be used a second time for another media afterwards.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2310>

3 years agowebrtcbin: When creating a new transceiver as part of creating the answer also take...
Sebastian Dröge [Tue, 8 Jun 2021 08:39:27 +0000 (11:39 +0300)]
webrtcbin: When creating a new transceiver as part of creating the answer also take its codec preferences into account

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2310>

3 years agowebrtcbin: Fix a couple of caps leaks of the offer caps
Sebastian Dröge [Tue, 8 Jun 2021 08:38:11 +0000 (11:38 +0300)]
webrtcbin: Fix a couple of caps leaks of the offer caps

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2310>

3 years agowebrtcbin: Stop transceivers update after first SDP error on data channel
Philippe Normand [Thu, 24 Jun 2021 11:28:11 +0000 (12:28 +0100)]
webrtcbin: Stop transceivers update after first SDP error on data channel

When invalid SDP is supplied, _update_data_channel_from_sdp_media() sets the
GError, so it is invalid to continue any further SDP processing, we have to exit
early when the first error is raised.

This change is similar to the one applied in
064428cb34572fa1a018ebbaba6925967ba99dc0.
See also #1595

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2356>

3 years agowebrtcbin test: Fix race in new test
Olivier Crête [Mon, 21 Jun 2021 20:50:46 +0000 (16:50 -0400)]
webrtcbin test: Fix race in new test

Pull a buffer from a sink to make sure that the caps are already
set before trying to update them.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2348>

3 years agomsdk: fix qp range for vp9enc
Mengkejiergeli Ba [Tue, 22 Jun 2021 08:12:57 +0000 (16:12 +0800)]
msdk: fix qp range for vp9enc

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2349>

3 years agoavwait: Don't consider it a segment change if the segment is the same except for...
Sebastian Dröge [Thu, 10 Jun 2021 08:46:35 +0000 (11:46 +0300)]
avwait: Don't consider it a segment change if the segment is the same except for the position

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2319>

3 years agod3d11: Add support for GRAY and more YUV formats
Seungha Yang [Mon, 21 Jun 2021 08:13:33 +0000 (17:13 +0900)]
d3d11: Add support for GRAY and more YUV formats

By this commit, following formats will be newly supported by d3d11 elements

* Y444_{8, 12, 16}LE formats:
  Similar to other planar formats. Such Y444 variants are not supported
  by Direct3D11 natively, but we can simply map each plane by
  using R8 and/or R16 texture.
* P012_LE:
  It is not different from P016_LE, but defining P012 and P016 separately
  for more explicit signalling. Note that DXVA uses P016 texture
  for 12bits encoded bitstreams.
* GRAY:
  This format is required for some codecs (e.g., AV1) if monochrome
  is supported
* 4:2:0 planar 12bits (I420_12LE) and 4:2:2 planar 8, 10, 12bits
  formats (Y42B, I422_10LE, and I422_12LE)

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2346>

3 years agotsmux: When selecting random PIDs, name the pads according to those PIDs
Sebastian Dröge [Thu, 10 Jun 2021 08:42:24 +0000 (11:42 +0300)]
tsmux: When selecting random PIDs, name the pads according to those PIDs

Some elements will make use of the automatically generated names to
create new pads in future muxer instances, for example splitmuxsink.

Previously we would've created a pad with a random pid that would become
"sink_0", and then on a new muxer instance a pad "sink_0" and tsmux
would've then failed because 0 is not a valid PID.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2318>

3 years agomfvideoenc: Enhance B-frame timestamp handling
Seungha Yang [Tue, 22 Jun 2021 16:43:08 +0000 (01:43 +0900)]
mfvideoenc: Enhance B-frame timestamp handling

When B-frame is enabled, encoder seems to adjust PTS of encoded sample
by using frame duration.

For instance, one observed timestamp pattern by using B-frame enabled
and 30fps stream is:
* Frame-1: MF pts 0:00.033333300 MF dts 0:00.000000000
* Frame-2: MF pts 0:00.133333300 MF dts 0:00.033333300
* Frame-3: MF pts 0:00.066666600 MF dts 0:00.066666600
* Frame-4: MF pts 0:00.099999900 MF dts 0:00.100000000

We can notice that the amount of PTS shift is frame duration and
Frame-4 exhibits PTS < DTS.

To compensate shifted timestamp, we should
calculate the timestamp offset and re-calculate DTS correspondingly.
Otherwise, total timeline of output stream will be shifted, and that
can cause time sync issue.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2354>

3 years agotsmux: Recheck existing pad PIDs when requesting a new pad with a random pid
Sebastian Dröge [Thu, 10 Jun 2021 08:36:43 +0000 (11:36 +0300)]
tsmux: Recheck existing pad PIDs when requesting a new pad with a random pid

Previously pads might have been requested already (e.g. in NULL state),
then reset was called (e.g. because changing state) and then a new pad
was requested. Resetting is re-creating the internal muxer object and as
such resetting the pid counter, so the next requested pad would get the
same pid as the first requested pad which then leads to collisions.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2317>

3 years agomfh264enc, mfh265enc: Set profile string to src caps
Seungha Yang [Mon, 21 Jun 2021 17:34:18 +0000 (02:34 +0900)]
mfh264enc, mfh265enc: Set profile string to src caps

Set configured profile to src caps so that downstream can figure
out selected profile.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2347>

3 years agowebrtc lib: Make the datachannel struct private
Olivier Crête [Wed, 21 Apr 2021 20:24:00 +0000 (16:24 -0400)]
webrtc lib: Make the datachannel struct private

This will prevent any unsafe access.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2241>

3 years agowebrtc lib: Make the DTLSTransport struct private
Olivier Crête [Wed, 21 Apr 2021 20:19:41 +0000 (16:19 -0400)]
webrtc lib: Make the DTLSTransport struct private

This will prevent any unsafe access.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2241>

3 years agowebrtc lib: Make the icetransport struct private
Olivier Crête [Wed, 21 Apr 2021 20:17:23 +0000 (16:17 -0400)]
webrtc lib: Make the icetransport struct private

This will prevent any unsafe access.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2241>

3 years agowebrtc lib: Make the rtpreceiver struct private
Olivier Crête [Wed, 21 Apr 2021 20:04:26 +0000 (16:04 -0400)]
webrtc lib: Make the rtpreceiver struct private

This will prevent any unsafe access.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2241>

3 years agowebrtc lib: Make the rtpsender struct private
Olivier Crête [Wed, 21 Apr 2021 20:00:57 +0000 (16:00 -0400)]
webrtc lib: Make the rtpsender struct private

This will prevent any unsafe access.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2241>

3 years agowebrtc lib: Make the transceiver struct private
Olivier Crête [Wed, 21 Apr 2021 20:00:34 +0000 (16:00 -0400)]
webrtc lib: Make the transceiver struct private

This will prevent any unsafe access.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2241>

3 years agox265enc: add negative DTS support
Mathieu Duponchelle [Fri, 18 Jun 2021 17:26:35 +0000 (19:26 +0200)]
x265enc: add negative DTS support

Use the same set_min_pts approach as x264enc.

Fixes: https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/issues/304
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2340>

3 years agodecklinkaudiosrc: Don't assume that stream time is always valid
Seungha Yang [Thu, 17 Jun 2021 11:10:35 +0000 (20:10 +0900)]
decklinkaudiosrc: Don't assume that stream time is always valid

As per SDK doc, IDeckLinkInputCallback::VideoInputFrameArrived
method might not provide video frame and it can be null.
In that case, given stream_time can be invalid.
So, we should not try to convert GST_CLOCK_TIME_NONE
by using gst_clock_adjust_with_calibration()

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2337>

3 years agotranscoder: Fix usage of g_error_propagate
Thibault Saunier [Mon, 14 Jun 2021 17:16:30 +0000 (13:16 -0400)]
transcoder: Fix usage of g_error_propagate

In the error callback we were propagating an error we were not owning
which is incorrect use of the API.

Also we were clearing a GError we already propagated which is wrong
as propagating gives ownership away.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2325>

3 years agotranscoder: Add a missing object unlocking
Thibault Saunier [Mon, 14 Jun 2021 17:13:24 +0000 (13:13 -0400)]
transcoder: Add a missing object unlocking

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2325>

3 years agofaad: fix typo in element documentation
Stéphane Cerveau [Mon, 14 Jun 2021 13:07:05 +0000 (15:07 +0200)]
faad: fix typo in element documentation

seealso is now see_also

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2323>

3 years agotests: msdkh264dec: Run test only if factory is available.
Víctor Manuel Jáquez Leal [Thu, 17 Jun 2021 18:17:14 +0000 (20:17 +0200)]
tests: msdkh264dec: Run test only if factory is available.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2336>

3 years agomsdk: Demote error log message to warning.
Víctor Manuel Jáquez Leal [Thu, 17 Jun 2021 09:25:11 +0000 (11:25 +0200)]
msdk: Demote error log message to warning.

It is not an error that the available hardware doesn't support VA-API/MSDK. Just
none plugin features will be registered.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2336>

3 years agolibs: d3d11: Port to C++
Seungha Yang [Sun, 20 Jun 2021 09:48:21 +0000 (18:48 +0900)]
libs: d3d11: Port to C++

In general, C++ COM APIs are slightly less verbose and more readable
than C APIs. And C++ supports some helper methods
(smart pointer and C++ only macros for example) which are not allowed for C.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2343>

3 years agomsdk: declare external dependencies
U. Artie Eoff [Wed, 16 Jun 2021 17:23:37 +0000 (10:23 -0700)]
msdk: declare external dependencies

Track kernel and VA driver dependencies so gstreamer
will re-inspect the plugin if any of them change.

Also, do not blacklist the plugin if !msdk_is_available
since it could be a transient issue caused by one or
more external dependency issues (e.g. wrong/missing
driver specified, but corrected by user later on).

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2335>

3 years agoh264parse,h265parse: Push parameter set NAL units again per segment-done
Seungha Yang [Wed, 16 Jun 2021 16:00:33 +0000 (01:00 +0900)]
h264parse,h265parse: Push parameter set NAL units again per segment-done

Some decoder implementations might drain out internal buffers and
reset its status on segment-done event. So, in case that
upstream stream-format is packetized but downstream supports only
byte-format, required codec-data might not be forwarded toward
downstream if such parameter set NAL units don't exist in inband
bitstream. Therefore, parse elements should re-send parameter set NAL
units like the case of flush event.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2334>

3 years agovp8decoder: Drain the output queue on EOS/finish
Nicolas Dufresne [Wed, 16 Jun 2021 14:31:13 +0000 (10:31 -0400)]
vp8decoder: Drain the output queue on EOS/finish

The finish() virtual method was flushing the queue, instead push the
remaining buffers. It is not required to reset in finish() unlike
drain(). This a regression causing last frame to always be lost.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2333>

3 years agov4l2slvp8dec: Only ask for output delay once per negotiation
Nicolas Dufresne [Wed, 16 Jun 2021 14:30:18 +0000 (10:30 -0400)]
v4l2slvp8dec: Only ask for output delay once per negotiation

While it's technically possible to change it per frame, asking for
that every frame is not very useful. This mimic H264 decoder better.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2333>

3 years agova: Improve the default mapping between rt_format and video format.
He Junyan [Wed, 16 Jun 2021 08:56:14 +0000 (16:56 +0800)]
va: Improve the default mapping between rt_format and video format.

We add 12 bits entries into this default mapping. And the old mapping
is not precise. For example, the NV12 should not be used as the default
mapping for VA_RT_FORMAT_YUV422 and VA_RT_FORMAT_YUV444, it is even not
a 422 or 444 format.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2332>

3 years agova: Add 12 bits rt_format setting in H265.
He Junyan [Wed, 16 Jun 2021 08:43:40 +0000 (16:43 +0800)]
va: Add 12 bits rt_format setting in H265.

In order to support 12 bits format decoding, we need to add the
support for 12 bits rt_format in H265.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2332>

3 years agova: Fix a typo in video format mapping.
He Junyan [Wed, 16 Jun 2021 08:32:30 +0000 (16:32 +0800)]
va: Fix a typo in video format mapping.

GST_VIDEO_FORMAT_Y412_LE is a 4:4:4 format and so should be mapped
to VA_RT_YUV444_12 rt format.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2332>

3 years agoh265parse: Fix a typo in get_compatible_profile_caps().
He Junyan [Tue, 15 Jun 2021 13:36:43 +0000 (21:36 +0800)]
h265parse: Fix a typo in get_compatible_profile_caps().

The GST_H265_PROFILE_MAIN_444_10 profile should be compatible with
GST_H265_PROFILE_SCREEN_EXTENDED_MAIN_444_10, not the current
GST_H265_PROFILE_SCREEN_EXTENDED_MAIN_10.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2328>

3 years agowaylandsink: prevent frame callback being released twice
Randy Li (ayaka) [Tue, 15 Dec 2020 10:11:08 +0000 (18:11 +0800)]
waylandsink: prevent frame callback being released twice

For those using context from the application which
would be the embedded video case, if the frame callback
is entering at the same time as window is finalizing,
a wayland proxy object would be destroyed twice, leading
the refcout less than zero in the second time, it can
throw an abort() in wayland.

For those top window case, which as a directly connection
to the compositor, they can stop the message queue then
the frame callback won't happen at the same time as the
window is finalizing. It doesn't think it would bother
them about this.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1883>

3 years agoalphadecodebin: Fix stall due to QoS
Nicolas Dufresne [Mon, 14 Jun 2021 20:04:52 +0000 (16:04 -0400)]
alphadecodebin: Fix stall due to QoS

alphacombine element is a simple element that assumes buffers are always
paired, or at least that missing buffers are signalled with a GAP. The QoS
implementation in the GstVideoDecoder base class allow decoders dropping
frames independently and that could lead to stall in alphacombine.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2326>

3 years agojpeg2000parse, openjpeg: add support for YCrCb 4:1:1 sampling
Stéphane Cerveau [Tue, 2 Feb 2021 10:02:02 +0000 (11:02 +0100)]
jpeg2000parse, openjpeg: add support for YCrCb 4:1:1 sampling

Add YCrCb 4:1:1 support in openjpeg elements
and fix in jpeg2000parse the YCrCb 4:1:0 support

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2321>

3 years agod3d11decoder: Don't print error log when no DPB texture is available
Seungha Yang [Thu, 10 Jun 2021 14:35:38 +0000 (23:35 +0900)]
d3d11decoder: Don't print error log when no DPB texture is available

... but we are flushing. The condition is quite expected situation
when pipeline is in the middle of seeking operation.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2320>

3 years agomsdkenc: add extbrc support in ext-coding-props property
Yinhang Liu [Sun, 23 May 2021 10:17:38 +0000 (18:17 +0800)]
msdkenc: add extbrc support in ext-coding-props property

The SDK can support external bitrate control [1], so add extbrc
to enable this feature.

[1] https://github.com/Intel-Media-SDK/MediaSDK/blob/master/doc/mediasdk-man.md#mfxextcodingoption2

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2139>

3 years agomsdkenc: add ext-coding-props for external coding options
Yinhang Liu [Sun, 23 May 2021 10:13:25 +0000 (18:13 +0800)]
msdkenc: add ext-coding-props for external coding options

This property supports passing multiple parameters using GstStructure.

Example usage:
ext-coding-props="props,key0=value0,key1=value1,..."

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2139>

3 years agocodecs: Fix the H265 poc out of order warning.
He Junyan [Sat, 5 Jun 2021 13:59:50 +0000 (21:59 +0800)]
codecs: Fix the H265 poc out of order warning.

We always get a warning such as:
h265decoder gsth265decoder.c:1432:gst_h265_decoder_do_output_picture: \
<vah265dec0> Outputting out of order 255 -> 0, likely a broken stream
in H265 decoder.

The problem is caused because we fail to reset the last_output_poc when
we get IDR and BLA. The incoming IDR and BLA frame already bump all the
frames in the DPB, but we forget to reset the last_output_poc, which
make the POC out of order and generate the warning all the time.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2294>

3 years agowasapi2sink: Fix ringbuffer object leak
Seungha Yang [Wed, 9 Jun 2021 16:09:44 +0000 (01:09 +0900)]
wasapi2sink: Fix ringbuffer object leak

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2315>

3 years agowasapi2ringbuffer: Implement GstAudioRingBuffer::pause()
Seungha Yang [Wed, 9 Jun 2021 15:24:24 +0000 (00:24 +0900)]
wasapi2ringbuffer: Implement GstAudioRingBuffer::pause()

WASAPI doesn't support PAUSE so it's not different from Stop().
When pipeline is in paused state, we don't need to waste CPU resource
for feeding silent buffers.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2315>

3 years agod3d11memory: Implement GstAllocator::mem_copy method
Seungha Yang [Sun, 6 Jun 2021 16:49:26 +0000 (01:49 +0900)]
d3d11memory: Implement GstAllocator::mem_copy method

There are a few places which require deep copy
(basesink on drain for example). Also this implementation can be
useful for future use case.
One probable future use case is that copying DPB texture to
another texture for in-place transform since our DPB texture is never
writable, and therefore copying is unavoidable.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2308>

3 years agowasapi2src: Add support for loopback recording
Seungha Yang [Tue, 8 Jun 2021 12:35:20 +0000 (21:35 +0900)]
wasapi2src: Add support for loopback recording

... and add various device error handling.

This loopback implementation is functionally identical to that of wasapisrc.
When it's enabled, wasapi2src will read data from render device instead of
capture device.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2311>

3 years agowasapi2: Rewrite plugin and implement audioringbuffer subclass
Seungha Yang [Mon, 10 May 2021 11:45:28 +0000 (20:45 +0900)]
wasapi2: Rewrite plugin and implement audioringbuffer subclass

... based on MediaFoundation work queue API.

By this commit, wasapi2 plugin will make use of pull mode scheduling
with audioringbuffer subclass.
There are several drawbacks of audiosrc/audiosink subclassing
(not audiobasesrc/audiobasesink) for WASAPI API, which are:
* audiosrc/audiosink classes try to set high priority to
  read/write thread via MMCSS (Multimedia Class Scheduler Service)
  but it's not allowed in case of UWP application.
  In order to use MMCSS in UWP, application should use MediaFoundation
  work queue indirectly.
  Since audiosrc/audiosink scheduling model is not compatible with
  MediaFoundation's work queue model, audioringbuffer subclassing
  is required.
* WASAPI capture device might report larger packet size than expected
  (i.e., larger frames we can read than expected frame size per period).
  Meanwhile, in any case, application should drain all packets at that moment.
  In order to handle the case, wasapi/wasapi2 plugins were making use of
  GstAdapter which is obviously sub-optimal because it requires additional
  memory allocation and copy.
  By implementing audioringbuffer subclassing, we can avoid such inefficiency.

In this commit, all the device read/write operations will be moved
to newly implemented wasapi2ringbuffer class and
existing wasapi2client class will take care of device enumeration
and activation parts only.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2306>

3 years agowasapi2: Use AUDCLNT_STREAMFLAGS_NOPERSIST flag
Seungha Yang [Sun, 6 Jun 2021 08:32:59 +0000 (17:32 +0900)]
wasapi2: Use AUDCLNT_STREAMFLAGS_NOPERSIST flag

... so that we can disable persistence of our mute/volume status

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2306>

3 years agowasapi2src: Fix doc typo
Seungha Yang [Sun, 6 Jun 2021 08:28:56 +0000 (17:28 +0900)]
wasapi2src: Fix doc typo

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2306>

3 years agowpe: Rename `undeserializable_type` to `not_deserializable_type`
Thibault Saunier [Wed, 26 May 2021 04:12:59 +0000 (00:12 -0400)]
wpe: Rename `undeserializable_type` to `not_deserializable_type`

Making it more readable.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2273>

3 years agowpe: Make forwarded messages layout more like GstBinForwaded messages
Thibault Saunier [Wed, 26 May 2021 03:58:27 +0000 (23:58 -0400)]
wpe: Make forwarded messages layout more like GstBinForwaded messages

Making it look more like how we do this kind of things in other places.

See: https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2252#note_927653
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2273>

3 years agowpe: Make wpesrc!video pad an always pad
Thibault Saunier [Fri, 21 May 2021 14:52:01 +0000 (10:52 -0400)]
wpe: Make wpesrc!video pad an always pad

There should always be a `video` pad no matter what.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2273>

3 years agowpe: Remove unused env var
Thibault Saunier [Fri, 21 May 2021 14:31:53 +0000 (10:31 -0400)]
wpe: Remove unused env var

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2273>

3 years agowpe: Fix atomic usage
Thibault Saunier [Fri, 21 May 2021 14:31:37 +0000 (10:31 -0400)]
wpe: Fix atomic usage

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2273>

3 years agowpe: Add a note able requiring tracing subsystem for message forwarding
Thibault Saunier [Fri, 21 May 2021 14:29:11 +0000 (10:29 -0400)]
wpe: Add a note able requiring tracing subsystem for message forwarding

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2273>

3 years agowpe: Fix check on whether MEMFD_CREATE is available
Thibault Saunier [Fri, 21 May 2021 14:18:21 +0000 (10:18 -0400)]
wpe: Fix check on whether MEMFD_CREATE is available

The ordering of the ifdef was wrong

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2273>

3 years agowpe: Plug a leak
Thibault Saunier [Fri, 21 May 2021 14:13:01 +0000 (10:13 -0400)]
wpe: Plug a leak

We were freeing after returning

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2273>

3 years agoRevert "wpe: Properly respect LIBGL_ALWAYS_SOFTWARE"
Thibault Saunier [Fri, 21 May 2021 13:54:33 +0000 (09:54 -0400)]
Revert "wpe: Properly respect LIBGL_ALWAYS_SOFTWARE"

This causes issues I didn't see:
     https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2252#note_927633

Let's just tell people to use capsfilter to force software rendering in
`wpesrc` for now.

The intent was to allow forcing it easily in playbin2 for the CI, but
we will do it some other way and see when time comes.

This reverts commit 9415106b029e5469ca28d882dc46ecc38786d4c9.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2273>

3 years agodebugutils: Introduce videocodectestsink
Nicolas Dufresne [Fri, 28 May 2021 19:18:53 +0000 (15:18 -0400)]
debugutils: Introduce videocodectestsink

This is a video specific sink used to test video CODEC conformance. This is similar
to a combination of filesink and testsink, but will skip over any type of
padding that GStreamer Video library introduces. This is needed in order to obtain the
correct checksum or raw yuv data.

This element currently support writing back non-padded raw I420 through the
location property and will calculate an MD5 and post it as an element message
of type conformance/checksum. More output format or checksum type could be
added in the future as needed.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2287>

3 years agovkinstance: Don't abort in case that system has no available vulkan device
Seungha Yang [Thu, 3 Jun 2021 16:44:47 +0000 (01:44 +0900)]
vkinstance: Don't abort in case that system has no available vulkan device

Specification doesn't have restriction that returned
pPhysicalDeviceCount value must be non-zero

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2304>

3 years agotsdemux: Clear all streams when rewinding
Edward Hervey [Thu, 3 Jun 2021 09:24:53 +0000 (11:24 +0200)]
tsdemux: Clear all streams when rewinding

This avoids sending out partial invalid data downstream which could cause
decoders (ex: `dvdlpmdec`) to error out.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2301>

3 years agod3d11: Add support for YV12 and NV21 formats
Seungha Yang [Fri, 28 May 2021 16:48:15 +0000 (01:48 +0900)]
d3d11: Add support for YV12 and NV21 formats

Handle UV swapped 4:2:0 8bits formats

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2290>

3 years agod3d11window_win32: Ensure closing internal HWND from window thread
Seungha Yang [Thu, 3 Jun 2021 09:28:26 +0000 (18:28 +0900)]
d3d11window_win32: Ensure closing internal HWND from window thread

Window handle must be closed from its own message thread

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2302>

3 years agodoc: Update cache after pixel format reorder
Nicolas Dufresne [Thu, 3 Jun 2021 14:31:39 +0000 (10:31 -0400)]
doc: Update cache after pixel format reorder

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2303>

3 years agodoc: add the msdk elements
Yinhang Liu [Thu, 3 Jun 2021 02:03:19 +0000 (10:03 +0800)]
doc: add the msdk elements

Supported elements:
msdkav1dec, msdkh264dec, msdkh264enc, msdkh265dec, msdkh265enc,
msdkmjpegdec, msdkmjpegenc, msdkmpeg2dec, msdkmpeg2enc, msdkvc1dec,
msdkvp8dec, msdkvp9dec, msdkvp9enc, msdkvpp.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2296>

3 years agowaylandsink: Fix for missing initial configure
Nicolas Dufresne [Wed, 2 Jun 2021 18:17:13 +0000 (14:17 -0400)]
waylandsink: Fix for missing initial configure

We were doing our initial "empty" commit on the subsurface instead of the
toplevel surface. As an incidence, we should not have received a configure
event ever, not just on mutter. This fixes the following warning when using
mutter compositor (aka gnome-shell):

  waylandsink wlwindow.c:304:gst_wl_window_new_toplevel: The compositor did not send configure event.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2299>

3 years agotest: camerabin: Fix buffer size calculation
Nicolas Dufresne [Wed, 2 Jun 2021 15:26:41 +0000 (11:26 -0400)]
test: camerabin: Fix buffer size calculation

We were assunming that GStreamer size for RGB (24bit packed) data was width x
height x 3, but GStreamer defaults to specific alignment. Use GstVideoInfo API
in order to obtain the buffer size.

This fixes failure seen when trying to merge: https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/998
which make us negoaite 1x1 instead of 16x16 in this test.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2297>

3 years agocodecs: Integrate H265 DPB full check into need_bump().
He Junyan [Mon, 31 May 2021 09:51:58 +0000 (17:51 +0800)]
codecs: Integrate H265 DPB full check into need_bump().

The current DPB check of H265 is not very correct. The current frame
is already in the DPB when we check whether the DPB is full.
For example, the DPB max size is 16 and we have 15 ref frames in the
DPB, so the gst_h265_dpb_delete_unused() cleans no one, and then plus
the current frame, the DPB is 16. This causes an error return, but in
fact, the stream is correct.
We now integrate the DPB full check into the need_bump() function.
We add the correct frame into to DPB and then check whether the picture
num is bigger than max_num_pics of DPB(which means there is no room for
the current picture). If true, we bump the DPB immediately.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2291>

3 years agoBack to development
Tim-Philipp Müller [Tue, 1 Jun 2021 14:28:57 +0000 (15:28 +0100)]
Back to development

3 years agoRelease 1.19.1
Tim-Philipp Müller [Mon, 31 May 2021 23:14:22 +0000 (00:14 +0100)]
Release 1.19.1

3 years agov4l2codecs: gstv4l2codecsvp8dec: implement a render delay
Daniel Almeida [Thu, 8 Apr 2021 13:11:52 +0000 (10:11 -0300)]
v4l2codecs: gstv4l2codecsvp8dec: implement a render delay

The v4l2 backend support delayed output for performance reasons.
It is then possible to use render delays to queue multiple requests
simultaneously, thus increasing performance.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2150>

3 years agocodecs: gstvp8decoder: add support for render delay
Daniel Almeida [Wed, 7 Apr 2021 21:24:27 +0000 (18:24 -0300)]
codecs: gstvp8decoder: add support for render delay

Some decoding APIs support delayed output for performance reasons.
One example would be to request decoding for multiple frames and
then query for the oldest frame in the output queue.

This also increases throughput for transcoding and improves seek
performance when supported by the underlying backend.

Introduce support in the vp8 base class, so that backends that
support render delays can actually implement it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2150>

3 years agowebrtcbin: Stop transceivers update after first SDP error
Philippe Normand [Mon, 17 May 2021 09:49:41 +0000 (10:49 +0100)]
webrtcbin: Stop transceivers update after first SDP error

When invalid SDP is supplied, _update_transceiver_from_sdp_media() sets the
GError, so it is invalid to continue any further SDP processing, we have to exit
early when the first error is raised.

Fixes #1595

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2254>

3 years agod3d11: Suppress some warning logs
Seungha Yang [Fri, 28 May 2021 14:21:19 +0000 (23:21 +0900)]
d3d11: Suppress some warning logs

We uses gst_d3d11_device_new() for enumerating device which can
fail for some reason. Don't print warning log for the case.
And decoding capability check is the same case as well.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2286>

3 years agohlssink2: Initialize debug category to prevent an assert with `fatal-warnings`
Roman Sivriver [Fri, 28 May 2021 21:05:02 +0000 (17:05 -0400)]
hlssink2: Initialize debug category to prevent an assert with `fatal-warnings`

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2288>

3 years agod3d11compositor: Reuse converter on alpha update
Seungha Yang [Fri, 21 May 2021 11:02:53 +0000 (20:02 +0900)]
d3d11compositor: Reuse converter on alpha update

... instead of creating converter object

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2276>

3 years agod3d11converter: Introduce config to be extensible
Seungha Yang [Mon, 17 May 2021 16:24:29 +0000 (01:24 +0900)]
d3d11converter: Introduce config to be extensible

Add a config argument like that of GstVideoConverter so that
we can add more options without modifying existing methods

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2276>

3 years agod3d11shader: Don't hold state object in GstD3D11Quad
Seungha Yang [Fri, 21 May 2021 12:30:42 +0000 (21:30 +0900)]
d3d11shader: Don't hold state object in GstD3D11Quad

We might want to update state object

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2276>

3 years agov4lcodecs: Validate src formats
Nicolas Dufresne [Thu, 27 May 2021 20:22:42 +0000 (16:22 -0400)]
v4lcodecs: Validate src formats

This add src format validation, this avoid registering element for
drivers we don't support any of their src formats. This also special
case the AlphaDecodeBin wrapper, as we know that alphacombine element
only support I420 and NV12 for now.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2272>

3 years agov4l2codecs: add wrappers for alpha decode
Daniel Almeida [Sat, 22 May 2021 19:29:09 +0000 (16:29 -0300)]
v4l2codecs: add wrappers for alpha decode

codecalpha is a new plugin introduced to support VP8/VP9 alpha as
defined in the WebM and Matroska specifications. It splits the stream
into two streams, one for the alpha and one for the actual content,
then it decodes them separately with vpxdec and finally combine the
results as A420 or AV12 (i.e. YUV + an extra alpha plane).

The workflow above is setup by means of a bin, gstcodecalphabin.

This patch simulates the same workflow into the v4l2codecs namespace,
thus using the new v4l2 stateless decoders for hardware acceleration.

This is so we can register the new alpha decode elements only if the
hardware produces formats we support, i.e. I420 or NV12 for now.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2272>

3 years agocodecalpha: alphacombine: add support for NV12/AV12
Daniel Almeida [Wed, 19 May 2021 21:45:19 +0000 (18:45 -0300)]
codecalpha: alphacombine: add support for NV12/AV12

Alpha combine works by appending the GstMemory for the alpha channel
to the GstBuffer containing I420, thereby pushing A420 on its src pad.

Add support for the same workflow for NV12, thereby producing the
recently introduced AV12 format (NV12 + Alpha).

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2277>

3 years agointerlace: Don't set field-order field for progressive caps
Seungha Yang [Tue, 25 May 2021 11:21:34 +0000 (20:21 +0900)]
interlace: Don't set field-order field for progressive caps

That would cause negotiation issue

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2282>

3 years agointerlace: Drop framerate from query caps of sinkpad
Seungha Yang [Tue, 25 May 2021 10:47:28 +0000 (19:47 +0900)]
interlace: Drop framerate from query caps of sinkpad

Query caps should return caps which represent the element can accept,
not resulting format.

Fixing negotiation error with
gst-launch-1.0 videotestsrc ! video/x-raw,framerate=25/1 ! interlace field-pattern=0 ! fakesink

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2282>

3 years agod3d11compositor: Fix caps update handling
Seungha Yang [Wed, 26 May 2021 07:37:06 +0000 (16:37 +0900)]
d3d11compositor: Fix caps update handling

New caps is applied only when previous buffer is consumed if any.
So, the lastest given caps might not be corresponding to the current buffer
to be handled.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2284>

3 years agolibs: va: display: Handle auto clean up macros.
Víctor Manuel Jáquez Leal [Thu, 20 May 2021 11:47:11 +0000 (13:47 +0200)]
libs: va: display: Handle auto clean up macros.

Add G_DEFINE_AUTOPTR_CLEANUP_FUNC macro for display classes, so auto
pointers are possible to users.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2269>

3 years agova: h265dec: Add current picture into reference list for SCC.
He Junyan [Mon, 17 May 2021 11:06:34 +0000 (19:06 +0800)]
va: h265dec: Add current picture into reference list for SCC.

The current picture is not in the DPB, so we need to add it manually
to the reference list when SCC is enabled.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2255>

3 years agova: h265dec: Set Screen Content extension (SCC) for picture parameters.
He Junyan [Fri, 21 May 2021 15:47:14 +0000 (23:47 +0800)]
va: h265dec: Set Screen Content extension (SCC) for picture parameters.

We already declare the support of HEVC screen content extension profiles
in the profile mapping list, but we fail to generate the correct VA picture
parameters buffers. This may cause the GPU hang.

We need to fill the buffer of VAPictureParameterBufferHEVCExtension correctly.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2255>

3 years agova: h265dec: Use get_profile_from_sps() to recognize the profile.
He Junyan [Mon, 17 May 2021 09:47:07 +0000 (17:47 +0800)]
va: h265dec: Use get_profile_from_sps() to recognize the profile.

The function of gst_h265_get_profile_from_sps() is better than the
function gst_h265_profile_tier_level_get_profile() when we recognize
the profile of the stream, becaue it considers the compatibility.

It is also used by h265parse to recognize the profile. So it is
better to keep the same behaviour with the parse and other decoders.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2255>

3 years agova: h265dec: Set range extension for picture and slice parameters.
He Junyan [Fri, 21 May 2021 15:21:12 +0000 (23:21 +0800)]
va: h265dec: Set range extension for picture and slice parameters.

We already declare the support of HEVC range extension profiles in
the profile mapping list, but we fail to generate the correct VA
picture and slice parameters buffers. This may cause the GPU hang.

We need to fill the buffer of VAPictureParameterBufferHEVCExtension
and VASliceParameterBufferHEVCExtension correctly.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2255>

3 years agova: h265dec: Use picture and slide extension parameters.
Víctor Manuel Jáquez Leal [Mon, 24 May 2021 16:18:52 +0000 (18:18 +0200)]
va: h265dec: Use picture and slide extension parameters.

This is transitional commit to later implement extended and screen
profiles.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2255>

3 years agoUse gst_buffer_new_memdup()
Tim-Philipp Müller [Mon, 24 May 2021 17:34:25 +0000 (18:34 +0100)]
Use gst_buffer_new_memdup()

Update for function rename in core.

https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/827

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2281>

3 years agowpe: Bump wpebackend-fdo version requirement to 1.8
Philippe Normand [Sat, 22 May 2021 17:05:18 +0000 (18:05 +0100)]
wpe: Bump wpebackend-fdo version requirement to 1.8

Debian bullseye has this version already, and this allows us to get rid of many
ifdefs. The mouse scroll handling is actually functional now as well.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2278>

3 years agoUse new gst_buffer_new_copy()
Tim-Philipp Müller [Sun, 23 May 2021 15:10:53 +0000 (16:10 +0100)]
Use new gst_buffer_new_copy()

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2279>

3 years agodoc: update gst_plugins_cache.json
Daniel Almeida [Fri, 21 May 2021 18:18:21 +0000 (15:18 -0300)]
doc: update gst_plugins_cache.json

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1152>

3 years agodxgiscreencapsrc: renegotiate caps on resolution change
Jakub Adam [Fri, 14 May 2021 18:22:26 +0000 (20:22 +0200)]
dxgiscreencapsrc: renegotiate caps on resolution change

When desktop gets resized, recreate the textures and renegotiate the
source caps with the updated video dimensions.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2249>

3 years agova: h265dec: Set LastSliceOfPic for multi sliced frames.
He Junyan [Tue, 18 May 2021 06:09:01 +0000 (14:09 +0800)]
va: h265dec: Set LastSliceOfPic for multi sliced frames.

VA-API HEVC decoding needs to known which is the last slice of a
picture, but slices are processed sequencially, so we know the
last slice until all the slices are already pushed into the
VABuffer array.

In order to mark the last slice, they are pushed into the
VABuffer array with a delay of one slice: the first slice is
hold, and when the second slice come, the first one is pushed
while holding the second, and so on. Finally, at end_picture(),
the last slice is marked and pushed into the array.

Co-author: Victor Jaquez <vjaquez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2246>