platform/upstream/gstreamer.git
3 years agocccombiner: implement scheduling
Mathieu Duponchelle [Tue, 9 Mar 2021 12:22:10 +0000 (13:22 +0100)]
cccombiner: implement scheduling

Prior to that, cccombiner's behaviour was essentially that of
a funnel: it strictly looked at input timestamps to associate
together video and caption buffers.

This patch instead exposes a "schedule" property, with a default
of TRUE, to control whether caption buffers should be smoothly
scheduled, in order to have exactly one per output video buffer.

This can involve rewriting input captions, for example when the
input is CDP sequence counters are rewritten, time codes are dropped
and potentially re-injected if the input video frame had a time code
meta.

Caption buffers may also get split up in order to assign captions to
the correct field when the input is interlaced.

This can also imply that the input will drift from synchronization,
when there isn't enough padding in the input stream to catch up. In
that case the element will start dropping old caption buffers once
the number of buffers in its internal queue reaches a certain limit
(configurable).

The property is exposed so that existing users of cccombiner can
revert back to the original behaviour, but should eventually be
removed, as that behaviour was simply inadequate.

This commit also disallows changing the input caption type, as
this would needlessly complicate implementation, and removes
the corresponding test.

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

3 years agod3d11: Use render-target and shader-resource bind flags by default
Seungha Yang [Wed, 17 Mar 2021 10:26:12 +0000 (19:26 +0900)]
d3d11: Use render-target and shader-resource bind flags by default

Even if bind flags is not needed by an element, other element
might need such bind flags.

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

3 years agova: vpp: Fix features lost in transform_caps().
He Junyan [Sun, 14 Mar 2021 16:04:21 +0000 (00:04 +0800)]
va: vpp: Fix features lost in transform_caps().

When we transform the caps from the sink to src, or vice versa, the
"caps" passed to us may only contain parts of the features. Which
makes our vpp lose some feature in caps and get a negotiation error.
The correct way should be:
Cleaning the format and resolution of that caps, but adding all VA,
DMA features to it, making it a full feature caps. Then, clipping it
with the pad template.

fixes: #1551

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

3 years agowpe: Ignore 'error-cancelled' 'failures'
Thibault Saunier [Mon, 15 Mar 2021 19:25:36 +0000 (16:25 -0300)]
wpe: Ignore 'error-cancelled' 'failures'

This happens when the user use the 'load-bytes' signal and nothing is wrong there

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

3 years agod3d11decoder: WARNING if ID3D11VideoDevice is unavailable, not ERROR
Seungha Yang [Tue, 16 Mar 2021 10:09:59 +0000 (19:09 +0900)]
d3d11decoder: WARNING if ID3D11VideoDevice is unavailable, not ERROR

gst_d3d11_decoder_new() method is also used for device capability
checking during plugin init. Although we are checking hardware
flag prior to that, it doesn't guarantee ID3D11VideoDevice interface.

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

3 years agomediafoundation: Fix resource leak
Seungha Yang [Tue, 16 Mar 2021 08:56:51 +0000 (17:56 +0900)]
mediafoundation: Fix resource leak

IMFActivate would hold its internal objects unless user call ShutdownObject(),
even if we release the IMFActivate. Here internal objects may
include Direct3D objects, such as texture, device handle for example.

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

3 years agod3d11colorconvert: Fix caps leak
Seungha Yang [Tue, 16 Mar 2021 06:58:57 +0000 (15:58 +0900)]
d3d11colorconvert: Fix caps leak

GstBaseTransform::fixate_caps() takes ownership of passed
othercaps argument.

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

3 years agova: example: multiple-vpp: test sharpen with dynamic controller
Víctor Manuel Jáquez Leal [Sat, 13 Mar 2021 18:00:18 +0000 (19:00 +0100)]
va: example: multiple-vpp: test sharpen with dynamic controller

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

3 years agova: postproc: synchronize segment with stream time
Víctor Manuel Jáquez Leal [Sat, 13 Mar 2021 17:57:37 +0000 (18:57 +0100)]
va: postproc: synchronize segment with stream time

This is required to use dynamic controllable parameters.

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

3 years agod3d11decoder: Do negotiation again per forward/reverse playback mode change
Seungha Yang [Mon, 15 Mar 2021 09:26:03 +0000 (18:26 +0900)]
d3d11decoder: Do negotiation again per forward/reverse playback mode change

For reverse playback, we are always copying decoded
frame to downstream buffer. So the pool size can be
and need to be large enough.

In case that forward playback, however, we need to restrict
the max pool size for performance reason. Otherwise decoder
will keep copying decoded texture to downstream buffer pool
if decoding is faster than downstream throughput
performance and also there are queue element between them.

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

3 years agod3d11videosink: Avoid switching conversion tool during playback
Seungha Yang [Mon, 15 Mar 2021 10:48:56 +0000 (19:48 +0900)]
d3d11videosink: Avoid switching conversion tool during playback

Decoder might be able to copy decoded texture to the other buffer pool
during playback depending on context. In that case, copied one
has no D3D11_BIND_DECODER bind flag.

If we used ID3D11VideoProcessor previously for decoder texture,
and incoming texture supports ID3D11VideoProcessor as well even if it has no
D3D11_BIND_DECODER flag (having D3D11_BIND_RENDER_TARGET for example),
allow zero-copying instead of using our fallback texture.

Frequent conversion tool change (between ID3D11VideoProcessor and generic shader)
might result in inconsistent image quality.

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

3 years agova: postproc: only drop filters if they change
Víctor Manuel Jáquez Leal [Fri, 12 Mar 2021 12:50:59 +0000 (13:50 +0100)]
va: postproc: only drop filters if they change

Currently, at every frame the filters array is recreated. This is not
optimal, since it should be only rebuilt if the VA filter's related
properties change. This patches does that by using a flag.

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

3 years agod3d11decoder: Refactor device open step and negotiation
Seungha Yang [Sun, 14 Mar 2021 07:11:12 +0000 (16:11 +0900)]
d3d11decoder: Refactor device open step and negotiation

* Remove redundant method arguments
* Don't allocate staging texture if downstream supports d3d11 memory

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

3 years agod3d11decoder: Move profile GUID handling into decoder object
Seungha Yang [Sun, 14 Mar 2021 06:08:01 +0000 (15:08 +0900)]
d3d11decoder: Move profile GUID handling into decoder object

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

3 years agod3d11decoder: Get rid of private struct
Seungha Yang [Sun, 14 Mar 2021 05:26:17 +0000 (14:26 +0900)]
d3d11decoder: Get rid of private struct

Completely hide member variables

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

3 years agoRevert "d3d11vp9dec: Add support for internal frame resizing"
Seungha Yang [Sun, 14 Mar 2021 03:50:21 +0000 (12:50 +0900)]
Revert "d3d11vp9dec: Add support for internal frame resizing"

This reverts commit 58a4c33a0e4f4e5415d8578166716e0d65c0c27e

We should use ID3D11VideoProcessor instead of shader
to avoid copy. We need to revisit this topic later

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

3 years agod3d11device: Hold ID3D11VideoDevice and ID3D11VideoContext object
Seungha Yang [Sat, 13 Mar 2021 13:47:55 +0000 (22:47 +0900)]
d3d11device: Hold ID3D11VideoDevice and ID3D11VideoContext object

... instead of QueryInterface-ing per elements. Note that
ID3D11VideoDevice and ID3D11VideoContext objects might not be available
if device doesn't support video interface.
So GstD3D11Device object will create those objects only when requested.

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

3 years agod3d11: Run gst-indent for all C++ code
Seungha Yang [Sun, 14 Mar 2021 04:01:37 +0000 (13:01 +0900)]
d3d11: Run gst-indent for all C++ code

Since all d3d11 plugin implementation code are C++, we need to
run gst-indent manually. This is preparation for later
"gst-indent sys/d3d11/*.cpp" run.

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

3 years agod3d11: Port to C++
Seungha Yang [Sat, 13 Mar 2021 08:40:57 +0000 (17:40 +0900)]
d3d11: Port to C++

Direct3D11 objects are COM, and most COM C APIs are verbose
(C++ is a little better). So, by using C++ APIs, we can make code
shorter and more readable.
Moreover, "ComPtr" helper class (which is C++ only) can be
utilized, that is very helpful for avoiding error-prone COM refcounting
issue/leak.

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

3 years agova: example: multiple-vpp: test direction change
Víctor Manuel Jáquez Leal [Fri, 12 Mar 2021 11:36:52 +0000 (12:36 +0100)]
va: example: multiple-vpp: test direction change

If the driver supports it (iHD, so far) and the parameter -d is set,
the direction of the video will be changed randomly.

In the code you can select, at compilation time, if the direction
change is done by element's property or by pipeline events.

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

3 years agova: postproc: update passthrough and reconfigure pads
Víctor Manuel Jáquez Leal [Thu, 11 Mar 2021 17:53:09 +0000 (18:53 +0100)]
va: postproc: update passthrough and reconfigure pads

Added helper function _update_passthrough() which will define and set
the pass-through mode of the filter, and it'll either reconfigure both
pads or it will just mark the src pad for renegotiation or nothing at
all.

There are cases where both pads have to be reconfigured (direction
changed, for example), other when just src pad has to (filters
updated) or none (changing to ready state).

The requirement of renegotiation depends on the need to enable/disable
its VA buffer pools.

This patch sets pass-through mode by default, so the buffer pools
aren't allocated if no filtering/direction operations are defined,
which is the correct behavior.

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

3 years agozxing: update to support version 1.1.1
Stéphane Cerveau [Thu, 25 Feb 2021 13:09:50 +0000 (14:09 +0100)]
zxing: update to support version 1.1.1

Support new API in 1.1.1
Update the supported input video format.
Update tests to use parse_launch

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

3 years agompegvideoparse: do not clip the frame
Stéphane Cerveau [Wed, 10 Mar 2021 12:10:28 +0000 (13:10 +0100)]
mpegvideoparse: do not clip the frame

If the current buffer is delta unit such as P or B
frame, the buffer should not be clipped and need to
let the decoder handle the segment boundary situation.

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

3 years agod3d11device: Fix wrong printf formatting
Seungha Yang [Wed, 10 Mar 2021 17:36:28 +0000 (02:36 +0900)]
d3d11device: Fix wrong printf formatting

Add missing '%' there

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

3 years agotranscoder: Add state-changed signal
Philippe Normand [Sat, 20 Feb 2021 11:36:42 +0000 (11:36 +0000)]
transcoder: Add state-changed signal

Similar to GstPlayer, a new signal for state tracking is now emitted at runtime,
as a commodity for applications which then don't need to monitor the pipeline
GstBus for state changes anymore.

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

3 years agoplayer: Rewrite as GstPlay wrapper
Philippe Normand [Mon, 7 Dec 2020 10:47:30 +0000 (10:47 +0000)]
player: Rewrite as GstPlay wrapper

For the time being the GstPlayer library remains as a wrapper for GstPlay, in
order to keep existing applications working and give them time to port to
GstPlay. GstPlayer will remain in -bad for a couple cycles and the plan for
GstPlay is to move it to -base before 1.20.

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

3 years agoplay: Flush API bus before exiting main loop
Philippe Normand [Mon, 7 Dec 2020 09:56:26 +0000 (09:56 +0000)]
play: Flush API bus before exiting main loop

Otherwise the bus might attempt to dispatch queued messages after the thread
ended, causing runtime warnings.

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

3 years agoplay: tests: Switch user-agent test to a real HTTP server
Philippe Normand [Sun, 29 Nov 2020 18:55:48 +0000 (18:55 +0000)]
play: tests: Switch user-agent test to a real HTTP server

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

3 years agoplay: tests: Refactor to use new Message bus API
Philippe Normand [Sat, 14 Nov 2020 10:56:51 +0000 (10:56 +0000)]
play: tests: Refactor to use new Message bus API

Instead of relying on an extra GMainLoop, the messages are poped from the player
bus and handled synchronously. This should avoid flaky behaviors.

Fixes #608

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

3 years agoplay: Plug media_info leak
Philippe Normand [Sat, 14 Nov 2020 10:47:53 +0000 (10:47 +0000)]
play: Plug media_info leak

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

3 years agoplay: Rename internal buffering field to buffering_percent
Stephan Hesse [Tue, 28 Apr 2020 19:09:40 +0000 (21:09 +0200)]
play: Rename internal buffering field to buffering_percent

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

3 years agoplay: Introducing the new playback library
Stephan Hesse [Sat, 2 Nov 2019 15:14:13 +0000 (16:14 +0100)]
play: Introducing the new playback library

This aims to be a replacement for the GstPlayer library. In GstPlay, notifications are
sent as application messages through a dedicated GstBus. The GMainContext-based
signal dispatcher was replaced by a GObject signal adapter, now relying on the
bus to emit its signals. The signal dispatcher is now optional and fully
decoupled from the GstPlay object.

Co-authored with: Philippe Normand <philn@igalia.com>

Fixes #394

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

3 years agoavwait: Don't post messages with the mutex locked
Sebastian Dröge [Tue, 9 Mar 2021 11:00:10 +0000 (13:00 +0200)]
avwait: Don't post messages with the mutex locked

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

3 years agowebrtc: don't generate duplicate rtx payloads when bundle-policy is set
Matthew Waters [Mon, 1 Mar 2021 09:53:53 +0000 (20:53 +1100)]
webrtc: don't generate duplicate rtx payloads when bundle-policy is set

It was possible to generate a SDP that had an RTX payload type
that matched one of the media payload types when providing caps via
codec_preferences without any sink pads.

Fixes

m=video 9 UDP/TLS/RTP/SAVPF 96
...
a=rtpmap:96 VP8/90000
a=rtcp-fb:96 nack pli
a=fmtp:96 apt=96

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

3 years agotests: Add negotiation tests for the interlace elements
Vivia Nikolaidou [Mon, 8 Mar 2021 12:30:52 +0000 (14:30 +0200)]
tests: Add negotiation tests for the interlace elements

Many complicated cases exist. Would be good to have some checks.

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

3 years agointerlace: Discard stored_frame on EOS and PAUSED_TO_READY
Vivia Nikolaidou [Mon, 8 Mar 2021 18:59:14 +0000 (20:59 +0200)]
interlace: Discard stored_frame on EOS and PAUSED_TO_READY

Would otherwise leak it.

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

3 years agointerlace: Specify interlace-modes in the sink pad template
Vivia Nikolaidou [Mon, 8 Mar 2021 14:16:25 +0000 (16:16 +0200)]
interlace: Specify interlace-modes in the sink pad template

Especially specify the field-order in the interleaved mode. Otherwise it
might cause the negotiation to fail, because
GST_PAD_SET_ACCEPT_INTERSECT is not set on the sinkpad, and the
field-order is missing in the sink template but can be present in the
outside caps.

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

3 years agonvh264sldec: Reopen decoder object if larger DPB size is required
Seungha Yang [Sun, 7 Mar 2021 07:47:07 +0000 (16:47 +0900)]
nvh264sldec: Reopen decoder object if larger DPB size is required

Equivalent to the d3d11h264dec fix
https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1839

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

3 years agod3d11: Fix an HLSL compiler warning
Seungha Yang [Tue, 2 Mar 2021 16:23:20 +0000 (01:23 +0900)]
d3d11: Fix an HLSL compiler warning

warning X3578: Output value 'main' is not completely initialized

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

3 years agotranscoder: handle SIGINT and SIGHUP
Bing Song [Wed, 27 Jan 2021 02:55:13 +0000 (10:55 +0800)]
transcoder: handle SIGINT and SIGHUP

Handle SIGINT and SIGHUP in transcoder. Or the output file maybe corrupt.

Fixes #1507

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

3 years agod3d11h264dec: Keep track of actually configured DPB size
Seungha Yang [Thu, 4 Mar 2021 08:42:28 +0000 (17:42 +0900)]
d3d11h264dec: Keep track of actually configured DPB size

... instead of the largest we ever seen.
Note that d3d11h264dec element holds previously configured DPB size
for later decoder object re-open decision.

This is to fix below case:
1) Initial SPS, required DPB size is 6
  - decoder object is opened with DPB size 6
  - max_dpb_size is now 6
2) SPS update with resolution change, required DPB size is 1
  - decoder object is re-opened with DPB size 1
  - max_dpb_size should be updated to 1, but it didn't happen (BUG)
3) SPS update without resolution change, only required DPB size is updated to 6
  - decoder object should be re-opened but didn't happen
    because we didn't update max_dpb_size at 2).

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

3 years agointerlace: add more formats, esp 10-bit, 12-bit and 16-bit ones
Tim-Philipp Müller [Wed, 3 Mar 2021 16:19:39 +0000 (16:19 +0000)]
interlace: add more formats, esp 10-bit, 12-bit and 16-bit ones

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

3 years agov4l2codecs: h264: retrieve interlaced information
Benjamin Gaignard [Tue, 16 Feb 2021 10:23:17 +0000 (11:23 +0100)]
v4l2codecs: h264: retrieve interlaced information

Lets the decoder knows if the frames are interlaced or not.
Provide this information to the driver while filling reference
pictures fields in slice params structure

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

3 years agov4l2codecs: h264: Reduce controls for subsequent slices
Nicolas Dufresne [Fri, 27 Nov 2020 21:00:03 +0000 (16:00 -0500)]
v4l2codecs: h264: Reduce controls for subsequent slices

Only the SLICE_PARAMS and PRED_WEIGHTS are needed for the second and
following slices.

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

3 years agov4l2codecs: h264: Implement optional scaling matrix
Ezequiel Garcia [Fri, 14 Aug 2020 13:13:09 +0000 (10:13 -0300)]
v4l2codecs: h264: Implement optional scaling matrix

The new H.264 uAPI requires that all drivers support
scaling matrix only as an option, when a non-flat
scaling matrix is provided in the bitstream headers.

Take advantage of this and avoid passing the scaling
matrix if not needed.

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

3 years agov4l2codecs: h264: Only set SPS control if needed
Ezequiel Garcia [Wed, 30 Sep 2020 17:34:15 +0000 (14:34 -0300)]
v4l2codecs: h264: Only set SPS control if needed

Given V4L2 controls are cached in V4L2, there is no need
to set them if they don't change. Set the SPS control
only if a new sequence was received by the parser.

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

3 years agov4l2codecs: h264: Only slice-based need SLICE_PARAMS and PRED_WEIGHTS
Ezequiel Garcia [Wed, 30 Sep 2020 17:22:14 +0000 (14:22 -0300)]
v4l2codecs: h264: Only slice-based need SLICE_PARAMS and PRED_WEIGHTS

Frame-based decoding mode doesn't require SLICE_PARAMS and
PRED_WEIGHTS controls.

Moreover, if the driver doesn't support these two controls, trying
to set them will fail. Fix this by only setting these on
slice-based decoding mode.

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

3 years agov4l2codecs: h264: Add API checks
Ezequiel Garcia [Wed, 30 Sep 2020 17:14:41 +0000 (14:14 -0300)]
v4l2codecs: h264: Add API checks

Check that the V4L2 H264 controls' sizes match
our expectation. If not, then probably there's an API
mismatch which will cause errors or decoding corruption.

Also, print a warning if the kernel version is too old.

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

3 years agov4l2codecs: h264: Update to the new uAPI
Ezequiel Garcia [Wed, 30 Sep 2020 13:40:51 +0000 (10:40 -0300)]
v4l2codecs: h264: Update to the new uAPI

Starting from Linux v5.11, the V4L2 stateless H.264 uAPI
is updated and stable.

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

3 years agov4l2codecs: h264: Set the scaling matrix present flag unconditionally
Ezequiel Garcia [Wed, 30 Sep 2020 13:33:59 +0000 (10:33 -0300)]
v4l2codecs: h264: Set the scaling matrix present flag unconditionally

We are currently always setting and passing a scaling matrix,
so need to set this flag accordingly. Passing a scaling matrix
optionally will be implemented in follow-up commit.

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

3 years agova: postproc: mention the possibility of color balance
Víctor Manuel Jáquez Leal [Tue, 2 Mar 2021 11:46:24 +0000 (12:46 +0100)]
va: postproc: mention the possibility of color balance

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

3 years agodocs: plugins update VA elements
Víctor Manuel Jáquez Leal [Tue, 2 Mar 2021 11:46:06 +0000 (12:46 +0100)]
docs: plugins update VA elements

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

3 years agova: vp8dec, vp9dec: only set NV12 color format for documentation
Víctor Manuel Jáquez Leal [Tue, 2 Mar 2021 11:44:12 +0000 (12:44 +0100)]
va: vp8dec, vp9dec: only set NV12 color format for documentation

Mention in documentation only the most used output format in VA-API.

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

3 years agod3d11convert: Forward colorimetry and chroma-site from upstream
Seungha Yang [Tue, 2 Mar 2021 13:01:26 +0000 (22:01 +0900)]
d3d11convert: Forward colorimetry and chroma-site from upstream

Adopt the improvement of https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1033
into d3d11.

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

3 years agod3d11convert: Add support for border drawing
Seungha Yang [Tue, 2 Mar 2021 08:47:03 +0000 (17:47 +0900)]
d3d11convert: Add support for border drawing

... and fix wrong resizing when downstream requested PAR value

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

3 years agod3d11convert: Prefer video processor over shader
Seungha Yang [Tue, 2 Mar 2021 12:35:00 +0000 (21:35 +0900)]
d3d11convert: Prefer video processor over shader

... if video processor was used previously. Otherwise, switching
between video processor and shader would result in inconsistent
output image quality.

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

3 years agod3d11videoprocessor: Disable auto processing mode explicitly
Seungha Yang [Tue, 2 Mar 2021 09:07:36 +0000 (18:07 +0900)]
d3d11videoprocessor: Disable auto processing mode explicitly

Don't allow auto processing (e.g., denoising), as it might result
in unexpected output.

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

3 years agod3d11memory: Fix for wrong texture_array_size returns
Seungha Yang [Tue, 2 Mar 2021 12:10:24 +0000 (21:10 +0900)]
d3d11memory: Fix for wrong texture_array_size returns

Fix mismatched return values

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

3 years agod3d11decoder: Add trace log for DPB pool size debugging
Seungha Yang [Tue, 2 Mar 2021 12:13:18 +0000 (21:13 +0900)]
d3d11decoder: Add trace log for DPB pool size debugging

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

3 years agod3d11decoder: Always use render-target bind flag for downstream pool
Seungha Yang [Tue, 2 Mar 2021 11:45:22 +0000 (20:45 +0900)]
d3d11decoder: Always use render-target bind flag for downstream pool

To convert decoded texture into other format, downstream would use
video processor instead of shader. In order for downstream to
be able to use video processor even if we copied decoded texture
into downstream pool, we should set this bind flag. Otherwise,
downstream would keep switching video processor and shader
to convert format which would result in inconsistent image quality.

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

3 years agod3d11: Fix wrong preprocessing blocks
Seungha Yang [Tue, 2 Mar 2021 11:37:04 +0000 (20:37 +0900)]
d3d11: Fix wrong preprocessing blocks

Missed in https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/464

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

3 years agova: vpp: fix a wrong caps logic in vpp_transform_caps().
He Junyan [Mon, 1 Mar 2021 05:44:09 +0000 (13:44 +0800)]
va: vpp: fix a wrong caps logic in vpp_transform_caps().

The current gst_va_vpp_transform_caps return such as:
  video/x-raw(memory:VAMemory), width=(int)[ 16, 16384 ], height=(int)[ 16, 16384 ],
  interlace-mode=(string)progressive, format=(string){ NV12, I420, YV12, YUY2, RGBA,
  BGRA, P010_10LE, ARGB, ABGR, VUYA }; video/x-raw(memory:DMABuf), width=(int)[ 16,
  16384 ], height=(int)[ 16, 16384 ], interlace-mode=(string)progressive, format=(string)
  { NV12, I420, YV12, YUY2, RGBA, BGRA, P010_10LE, ARGB, ABGR, VUYA }; video/x-raw,
  width=(int)[ 16, 16384 ], height=(int)[ 16, 16384 ], interlace-mode=(string)progressive,
  format=(string){ VUYA, GRAY8, NV12, NV21, YUY2, UYVY, YV12, I420, P010_10LE };
  video/x-raw(memory:VAMemory), width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ],
  interlace-mode=(string)progressive; video/x-raw(memory:DMABuf), width=(int)[ 1, 2147483647 ],
  height=(int)[ 1, 2147483647 ], interlace-mode=(string)progressive; video/x-raw, width=(int)
  [ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], interlace-mode=(string)progressive

Which is not correct. It mixes the template caps and the input query caps together.
The correct way should be: clip the template caps with the input caps(remove format
and rangify size). The correct answer should be:
  video/x-raw(memory:VAMemory), width=(int)[ 16, 16384 ], height=(int)[ 16, 16384 ], interlace
  -mode=(string)progressive, format=(string){ NV12, I420, YV12, YUY2, RGBA, BGRA, P010_10LE,
  ARGB, ABGR, VUYA }; video/x-raw(memory:DMABuf), width=(int)[ 16, 16384 ], height=(int)[ 16,
  16384 ], interlace-mode=(string)progressive, format=(string){ NV12, I420, YV12, YUY2, RGBA,
  BGRA, P010_10LE, ARGB, ABGR, VUYA }; video/x-raw, width=(int)[ 16, 16384 ], height=(int)[ 16,
  16384 ], interlace-mode=(string)progressive, format=(string){ VUYA, GRAY8, NV12, NV21, YUY2,
  UYVY, YV12, I420, P010_10LE }

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

3 years agompegtsparse: Fix switched DTS/PTS when set-timestamps=false
Jan Alexander Steffens (heftig) [Mon, 1 Mar 2021 15:23:37 +0000 (16:23 +0100)]
mpegtsparse: Fix switched DTS/PTS when set-timestamps=false

Fixes 30ee21eae36e7279f63b77167ba1dcf5f70b8e83.

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

3 years agowebrtc ice: Add 'min/max-rtp-port' props for setting RTP port range
Ilya Kreymer [Thu, 15 Aug 2019 15:25:26 +0000 (08:25 -0700)]
webrtc ice: Add 'min/max-rtp-port' props for setting RTP port range

default min port == 0, max port == 65535 -- if min port == 0, uses existing random port selection (range ignored)
add 'gathering_started' flag to avoid changing ports after gathering has started
validity checks: min port <= max port enforced, error thrown otherwise
include tests to ensure port range is being utilized (by @hhardy)

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

3 years agowebrtc ice: Only ever request one component, it's always rtcpmux
Olivier Crête [Thu, 25 Feb 2021 16:58:57 +0000 (11:58 -0500)]
webrtc ice: Only ever request one component, it's always rtcpmux

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

3 years agotranscoder: Add some missing API guards
Thibault Saunier [Fri, 26 Feb 2021 18:40:01 +0000 (15:40 -0300)]
transcoder: Add some missing API guards

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

3 years agotranscoder: Fix potential use of uninitialized variables
Thibault Saunier [Fri, 26 Feb 2021 18:36:48 +0000 (15:36 -0300)]
transcoder: Fix potential use of uninitialized variables

gst_structure_get won't touch variables if the field is not present
leading to potential use of initialized vars

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

3 years agotranscoder: Rework the API to create/get SignalAdapter
Thibault Saunier [Fri, 26 Feb 2021 18:31:29 +0000 (15:31 -0300)]
transcoder: Rework the API to create/get SignalAdapter

We can only have 1 single GstTranscoderSignalAdapter object for a
given GstTranscoder object, this enforces that by avoiding to expose
a constructor and instead add a method to GstTranscoder to get the
signal adapter (internally creating it when needed). We can still
cleanly ensure that the signal adapter is running for the requested
GMainContext and return NULL if it is not the case.

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

3 years agowebrtcbin: use regular ice nomination by default
Matthew Waters [Mon, 22 Feb 2021 05:59:25 +0000 (16:59 +1100)]
webrtcbin: use regular ice nomination by default

1. We don't currently deal with an a=ice-options in the SDP which means
   we currently violate https://tools.ietf.org/html/rfc5245#section-8.1.1
   which states: "If its peer is using ICE options (present in
   an ice-options attribute from the peer) that the agent does not
   understand, the agent MUST use a regular nomination algorithm."
2. The recommendation is default to regular nomination in both RFC5245
   and RFC8445.  libnice change for this is
   https://gitlab.freedesktop.org/libnice/libnice/-/merge_requests/125
   which requires an API break in libnice.

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

3 years agotranscoder: Remove un-needed gst_init call
Philippe Normand [Wed, 24 Feb 2021 18:43:07 +0000 (18:43 +0000)]
transcoder: Remove un-needed gst_init call

We can safely assume GStreamer is already initialized from here.

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

3 years agotranscoder: Port to a GstBus API instead
Thibault Saunier [Thu, 26 Nov 2020 01:25:28 +0000 (22:25 -0300)]
transcoder: Port to a GstBus API instead

Following the move made by GstPlayer in:

https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/35

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

3 years agotranscoder: Automatically generate enums GTypes
Thibault Saunier [Thu, 26 Nov 2020 01:21:35 +0000 (22:21 -0300)]
transcoder: Automatically generate enums GTypes

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

3 years agotranscoder: Port to G_DECLARE
Thibault Saunier [Thu, 26 Nov 2020 01:01:30 +0000 (22:01 -0300)]
transcoder: Port to G_DECLARE

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

3 years agodecklinkvideosink: Use correct numerator for 29.97fps
Sebastian Dröge [Fri, 26 Feb 2021 14:36:58 +0000 (16:36 +0200)]
decklinkvideosink: Use correct numerator for 29.97fps

It's not 0.2997fps.

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

3 years agodecklinksrc: Use a more accurate capture time
Edward Hervey [Fri, 26 Feb 2021 10:39:10 +0000 (11:39 +0100)]
decklinksrc: Use a more accurate capture time

Use the hardware reference clock time when the frame was finished being captured
instead of a time much further down the road.

This improves the stability/accuracy of buffer times.

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

3 years agova: allocator: No need of fourcc to create surface.
Víctor Manuel Jáquez Leal [Wed, 24 Feb 2021 18:14:42 +0000 (19:14 +0100)]
va: allocator: No need of fourcc to create surface.

In commits 430aa327 and a119a940 there are a regression since it is
possible to create surfaces without fourcc, only chroma (rtformat) is
required.

This regression is shown on radeonsi driver with certain color
formats.

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

3 years agova: vpp: implement GstColorBalance interface
Víctor Manuel Jáquez Leal [Wed, 24 Feb 2021 12:06:51 +0000 (13:06 +0100)]
va: vpp: implement GstColorBalance interface

And modify multiple-vpp example to use it with -r parameter.

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

3 years agova: filter: add controllable and mutable playing to GParamFlags
Víctor Manuel Jáquez Leal [Tue, 23 Feb 2021 16:22:40 +0000 (17:22 +0100)]
va: filter: add controllable and mutable playing to GParamFlags

Add controllable and mutable playgin to common GParamFlags.

Also use this common flags to video-direction

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

3 years agovulkan: Fix elements long name.
Víctor Manuel Jáquez Leal [Wed, 24 Feb 2021 15:57:06 +0000 (16:57 +0100)]
vulkan: Fix elements long name.

Fix vkcoloconvert and vkviewconvert long names.

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

3 years agomsdk: allow user specify a drm device via an env variable
Haihao Xiang [Tue, 12 Jan 2021 07:33:49 +0000 (15:33 +0800)]
msdk: allow user specify a drm device via an env variable

User may specify the required device via GST_MSDK_DRM_DEVICE

Example:
GST_MSDK_DRM_DEVICE=/dev/dri/card0 gst-launch-1.0 videotestsrc ! msdkh264enc
! fakesink

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

3 years agoVA: Add the vaav1dec element as the av1 decoder.
He Junyan [Tue, 19 Jan 2021 07:36:29 +0000 (15:36 +0800)]
VA: Add the vaav1dec element as the av1 decoder.

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

3 years agoVA: Add the aux surface for gst buffer used by decoder.
He Junyan [Tue, 19 Jan 2021 07:17:58 +0000 (15:17 +0800)]
VA: Add the aux surface for gst buffer used by decoder.

The AV1 codec needs to support the film grain feature. When the film
grain feature is enabled, we need two surfaces as the output of the
decoded picture, one without film grain effect and the other one with
it. The first one acts as the reference and is needed for later pictures'
reconstruction, and the second one is the real display output.
So we need to attach another aux surface to the gst buffer/mem and make
that aux surface as the target of vaBeginPicture.

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

3 years agoVA: Add a helper function of decoder_add_slice_buffer_with_n_params.
He Junyan [Tue, 19 Jan 2021 07:07:38 +0000 (15:07 +0800)]
VA: Add a helper function of decoder_add_slice_buffer_with_n_params.

Some codecs such as AV1 needs several parameters associated with one
slice. It may have multi tiles within one slice and each tile needs
its description parameter.

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

3 years agocodecs: AV1decoder: Add the AV1 decoder base class.
He Junyan [Tue, 19 Jan 2021 06:59:45 +0000 (14:59 +0800)]
codecs: AV1decoder: Add the AV1 decoder base class.

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

3 years agova: allocator: replace assert with error log in va alloc.
He Junyan [Tue, 23 Feb 2021 05:47:29 +0000 (13:47 +0800)]
va: allocator: replace assert with error log in va alloc.

We should print error log rather than assert when the forcc or
the rt_format of va allocator is unrecognized.

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

3 years agod3d11: Documentation update
Seungha Yang [Sun, 21 Feb 2021 08:38:38 +0000 (17:38 +0900)]
d3d11: Documentation update

* Update class metadata
  * for wrapper bin elements to be distinguishable from internal element.
  * D3D11 -> Direct3D11 for consistency
* Add missing Since mark everywhere
* Update plugin cache

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

3 years agod3d11: Reorganize class hierarchy of convert elements
Seungha Yang [Sun, 21 Feb 2021 11:38:37 +0000 (20:38 +0900)]
d3d11: Reorganize class hierarchy of convert elements

AS-IS:
D3D11Convert class is baseclass of D3D11ColorConvert and D3D11Scale
* GstD3D11Convert
  |_ GstD3D11ColorConvert
  |_ GstD3D11Scale

TO-BE:
Introducing a new base class for color conversion and/or rescale elements
* GstD3D11BaseConvert
  |_ GstD3D11Convert
  |_ GstD3D11ColorConvert
  |_ GstD3D11Scale

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

3 years agod3d11deinterlace: Add missing system memory caps features on templates
Seungha Yang [Sun, 21 Feb 2021 08:35:40 +0000 (17:35 +0900)]
d3d11deinterlace: Add missing system memory caps features on templates

This element can support system memory

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

3 years agova: filter, vpp: process colorimetry
Víctor Manuel Jáquez Leal [Thu, 18 Feb 2021 08:53:09 +0000 (09:53 +0100)]
va: filter, vpp: process colorimetry

A new filter method were added: gst_va_filter_set_formats(). In this
way the input & output GstVideoInfo are processed only once per stream
negotiation, and not per frame.

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

3 years agova: filter: check if filter is open on set_orientation()
Víctor Manuel Jáquez Leal [Thu, 18 Feb 2021 04:58:25 +0000 (05:58 +0100)]
va: filter: check if filter is open on set_orientation()

Because the method requires pipeline_caps is filled.

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

3 years agova: filter: human readable background color
Víctor Manuel Jáquez Leal [Wed, 17 Feb 2021 17:56:29 +0000 (18:56 +0100)]
va: filter: human readable background color

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

3 years agova: filter: fail immediately if vaBeginPicture() fails
Víctor Manuel Jáquez Leal [Wed, 17 Feb 2021 17:55:14 +0000 (18:55 +0100)]
va: filter: fail immediately if vaBeginPicture() fails

There's no need to try vaRenderPicture() if vaBeginPicture() failed.

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

3 years agova: filter: destroy pipeline buffer after destroying filters
Víctor Manuel Jáquez Leal [Wed, 17 Feb 2021 17:30:10 +0000 (18:30 +0100)]
va: filter: destroy pipeline buffer after destroying filters

In 6ae24948 the pipeline buffer destroy were removing assuming it
wasn't required. Nonetheless, debugging the code it looks like a
buffer leak in iHD driver since the ID of the buffer kept increasing.

The difference now is that first the filter buffers are destroy first
and later the pipeline buffer.

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

3 years agova: vpp: Add raw buffer copy when needed.
He Junyan [Fri, 19 Feb 2021 06:27:39 +0000 (14:27 +0800)]
va: vpp: Add raw buffer copy when needed.

Just like the decoder, the vapostproc also needs to copy the output
buffer to raw buffer if downstream elements only supports raw caps
and does not support the video meta.

The pipeline like:
  gst-launch-1.0 filesrc location=xxxx ! h264parse ! vah264dec ! \
  vapostproc ! capsfilter caps=video/x-raw,width=55,height=128 ! \
  filesink location=xxx
needs this logic to dump the data correctly.

fixes: #1523

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

3 years agosdpsrc: fix double free if sdp is provided as string via the property
Tim-Philipp Müller [Fri, 19 Feb 2021 00:03:00 +0000 (00:03 +0000)]
sdpsrc: fix double free if sdp is provided as string via the property

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

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

3 years agowasapi2device: Make wasapi2 device distinguishable from wasapi device
Seungha Yang [Thu, 18 Feb 2021 12:38:37 +0000 (21:38 +0900)]
wasapi2device: Make wasapi2 device distinguishable from wasapi device

Both wasapi2 and wasapi plugins use WASAPI API. So "device.api=wasapi"
would make sense for the wasapi2 plugin as well. But people would be
confused by the identical "device.api=wasapi" property if intended
plugin is wasapi, not wasapi2. This change will make them distinguishable
by using "device.api" device property.

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

3 years agowasapi2: Always build if Windows 10 SDK is available
Seungha Yang [Tue, 12 Jan 2021 15:27:40 +0000 (00:27 +0900)]
wasapi2: Always build if Windows 10 SDK is available

Add support for building wasapi2 plugin if Windows 10 SDK is
available on system

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

3 years agodtls: use GST_WARNING instead of g_warning
Stéphane Cerveau [Mon, 8 Feb 2021 11:24:58 +0000 (12:24 +0100)]
dtls: use GST_WARNING instead of g_warning

No need a g_warning which is failing always
with gst-inspect -a

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

3 years agoh264parse: don't invalidate the last PPS when parsing a new SPS
Michael Olbrich [Thu, 28 Jan 2021 11:28:03 +0000 (12:28 +0100)]
h264parse: don't invalidate the last PPS when parsing a new SPS

When a SPS is received then any previous PPS remains valid. So don't clear
the PPS flag from the parser state.

This is important because there are encoders that don't generated a PPS after
every SPS.

Closes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/issues/571

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

3 years agoh265parse: Detect height change on field-based interlaced files
Vivia Nikolaidou [Wed, 17 Feb 2021 13:15:09 +0000 (15:15 +0200)]
h265parse: Detect height change on field-based interlaced files

The first time update_src_caps is called, there's no frame parsed yet,
therefore we don't know whether the file has alternate-field interlacing
mode. If we run it again after we have a frame, it might be that now we
have the SEI pic_struct parsed, and therefore we know that it's
field-based interlaced, and therefore the height must be multiplied by
two. Earlier on this was not detected as a change.

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