platform/upstream/gstreamer.git
19 months agoci: consolidate pre-build CI stages
Jordan Petridis [Mon, 24 Oct 2022 18:38:13 +0000 (21:38 +0300)]
ci: consolidate pre-build CI stages

Back in the day we kept separate stages around to define
build order, however with DAG/needs now jobs run asynchronously.
Additionally on recent version its possibel to same jobs depend on
other jobs from the same stage.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3258>

19 months agoci: Replace obselete variable
Jordan Petridis [Mon, 24 Oct 2022 18:06:14 +0000 (21:06 +0300)]
ci: Replace obselete variable

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3258>

19 months agocore/base: Only post latency messages if the latency values have actually changed
Sebastian Dröge [Thu, 27 Oct 2022 12:13:36 +0000 (15:13 +0300)]
core/base: Only post latency messages if the latency values have actually changed

Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1525

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3282>

19 months agovideodecoder: Only post latency message if it changed
Edward Hervey [Thu, 27 Oct 2022 05:21:19 +0000 (07:21 +0200)]
videodecoder: Only post latency message if it changed

Posting latency messages causes a full and potentially expensive latency
recalculation of the pipeline. While subclasses should check whether the latency
really changed or not before calling this function, we ensure that we do not
post such messages if it didn't change.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3282>

19 months agoavdec_h265: Fix endless renegoation with alternate interlacing
Nicolas Dufresne [Wed, 26 Oct 2022 20:30:31 +0000 (16:30 -0400)]
avdec_h265: Fix endless renegoation with alternate interlacing

The picture parameter picture->top_field_first is reused in this mode
to signal the TOP fields. As a side effect, it will change every frame
and current code assumed that if this changes then a renegotiation is
needed. Fixed this by ignoring that change whenever we are decoding one field
only.

Fixes #1523

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3276>

19 months agoh265bitwriter: Correct the all API to byte aligned.
He Junyan [Thu, 27 Oct 2022 07:21:30 +0000 (15:21 +0800)]
h265bitwriter: Correct the all API to byte aligned.

In fact, all the h265 bit writer have byte aligned output. So we
change the API from bit size in unit to byte size, which is easy
to use.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3193>

19 months agoh264bitwriter: Correct the all API to byte aligned.
He Junyan [Thu, 27 Oct 2022 05:42:17 +0000 (13:42 +0800)]
h264bitwriter: Correct the all API to byte aligned.

In fact, all the h264 bit writer have byte aligned output except
the slice header. So we change the API from bit size in unit to
byte size, which is easy to use. For slice header, we add a extra
"trail_bits_num" to return the unaligned bits number.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3193>

19 months agobitwriter: Fix a nal conversion bug when input is not byte aligned.
He Junyan [Thu, 27 Oct 2022 06:40:49 +0000 (14:40 +0800)]
bitwriter: Fix a nal conversion bug when input is not byte aligned.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3193>

19 months agomsdkvpp: Set va mem caps as higher priority
Mengkejiergeli Ba [Mon, 24 Oct 2022 03:56:51 +0000 (11:56 +0800)]
msdkvpp: Set va mem caps as higher priority

We use va pool as msdkvpp's bufferpool, which means both va memory
and dma memory will be allocated by va pool. Considering drm modifier
stuff is not ready, we use va memory with higher priortiry than
dma memory when deciding vpp caps.

Besides, this patch removes the specified "interlace-mode" in vpp caps.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3253>

19 months agoconcat: Properly propagate EOS seqnum
Edward Hervey [Thu, 27 Oct 2022 09:18:24 +0000 (11:18 +0200)]
concat: Properly propagate EOS seqnum

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3284>

19 months agomsdkav1enc: Remove reorder TU workaround
Mengkejiergeli Ba [Tue, 18 Oct 2022 03:36:23 +0000 (03:36 +0000)]
msdkav1enc: Remove reorder TU workaround

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3225>

19 months agomsdkav1enc: Remove pts workaround
Mengkejiergeli Ba [Tue, 18 Oct 2022 03:10:43 +0000 (03:10 +0000)]
msdkav1enc: Remove pts workaround

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3225>

19 months agocodecparsers: {h264,h265}bitwriter: Don't install headers yet
Seungha Yang [Wed, 26 Oct 2022 19:15:01 +0000 (04:15 +0900)]
codecparsers: {h264,h265}bitwriter: Don't install headers yet

Those APIs are quite early stage of development, and we might want to
change them in the near future

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3275>

19 months agomsdkvpp: Fix upper frc
Mengkejiergeli Ba [Tue, 18 Oct 2022 08:34:41 +0000 (16:34 +0800)]
msdkvpp: Fix upper frc

Refact vpp commit 4c6b7194451ff6fbfe88834219d982302114d74b broke the
upper FRC, here to fix this by using outbuf_new.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3223>

19 months agobad: Add msdkav1enc docs
Mengkejiergeli Ba [Fri, 29 Jul 2022 10:15:08 +0000 (18:15 +0800)]
bad: Add msdkav1enc docs

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2971>

19 months agomeson: Fix path for webrtc validate tests
Nicolas Dufresne [Wed, 26 Oct 2022 17:41:10 +0000 (13:41 -0400)]
meson: Fix path for webrtc validate tests

This fixes a crash when trying to run gst-validate-launcher from inside
the meson devenv. The error was:

  ModuleNotFoundError: No module named 'observer'

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3273>

19 months agoavviddec: Avoid flushing on framerate changes
Nicolas Dufresne [Wed, 26 Oct 2022 14:44:01 +0000 (10:44 -0400)]
avviddec: Avoid flushing on framerate changes

A framerate change does not require flushing the decoder and causes
issues with some specific fragmented files if the two fragments have
different framerate.

Fixes #1522

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3270>

19 months agoximagesink, xvimagesink: set the _NET_WM_PID atom on the window
Daniels Umanovskis [Wed, 26 Oct 2022 08:25:43 +0000 (10:25 +0200)]
ximagesink, xvimagesink: set the _NET_WM_PID atom on the window

This makes it easier for X11 window management to work with windows created by these sinks

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3267>

19 months agoalphacombine: Add missing query handler for gaps
Nicolas Dufresne [Tue, 25 Oct 2022 12:14:18 +0000 (08:14 -0400)]
alphacombine: Add missing query handler for gaps

The gap handling was in place, but there was no event handler to trigger it.
Implement the alpha sink event handler for the gaps. This fixes handling of
valid streams which may not refresh the alpha frames for every video frames.
It will also allow a clean error if the stream was missing the initial
alpha frame, at least until we find a better way to handle these
invalid frames.

Related to #1518

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3264>

19 months agoavfdeviceprovider: do not leak the properties
Ignacio Casal Quinteiro [Wed, 26 Oct 2022 09:47:43 +0000 (11:47 +0200)]
avfdeviceprovider: do not leak the properties

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3268>

19 months agoci: Fix traceback when user doesn't have a cerbero fork
Nirbheek Chauhan [Wed, 26 Oct 2022 09:17:52 +0000 (14:47 +0530)]
ci: Fix traceback when user doesn't have a cerbero fork

```
Traceback (most recent call last):
  File "ci/gitlab/trigger_cerbero_pipeline.py", line 59, in <module>
    if cerbero is None:
NameError: name 'cerbero' is not defined
```

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3063>

19 months agovaencoder: Fix caps semantics.
Víctor Manuel Jáquez Leal [Fri, 21 Oct 2022 08:57:39 +0000 (10:57 +0200)]
vaencoder: Fix caps semantics.

When using gst_va_caps_from_profiles() the semantics of sink/src caps
depends if the element is an encoder or a decoder.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3063>

19 months agova: Fix typos.
Víctor Manuel Jáquez Leal [Wed, 19 Oct 2022 14:44:07 +0000 (16:44 +0200)]
va: Fix typos.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3063>

19 months agovah264enc: Fail if unsupported rate control.
Víctor Manuel Jáquez Leal [Thu, 11 Aug 2022 10:51:17 +0000 (12:51 +0200)]
vah264enc: Fail if unsupported rate control.

Handle when encoder doesn't support rate control, which is set as
VA_RC_NONE, and if the set rate control mode is not supported by the
GStreamer element, the element configuration fails.

Also it logs out max and target bitrate.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3063>

19 months agovah264enc: Add todo item.
Víctor Manuel Jáquez Leal [Thu, 15 Sep 2022 10:56:14 +0000 (12:56 +0200)]
vah264enc: Add todo item.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3063>

19 months agovaencoder: Honor entrypoint at constructor.
Víctor Manuel Jáquez Leal [Wed, 19 Oct 2022 14:08:17 +0000 (16:08 +0200)]
vaencoder: Honor entrypoint at constructor.

The entrypoint is set when the encoder helper is constructed,
nonetheless it was also passed as parameter when opening. That's
buggy.

In order to simplify the code, the entrypoint at construction is
honored.

But gst_va_encoder_has_profile_and_entrypoint() now doesn't rely in
the internal list of profiles since it only contains those that
belongs to codec and entrypoint, thus it queries directly the VA
driver.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3063>

19 months agovabaseenc: Scope error bail out.
Víctor Manuel Jáquez Leal [Thu, 11 Aug 2022 10:50:27 +0000 (12:50 +0200)]
vabaseenc: Scope error bail out.

Though this is not enforced by the GStreamer code style, it's clearer
to add a nested scope for error handling using label/goto.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3063>

19 months agovabaseenc: Use class entrypoint.
Víctor Manuel Jáquez Leal [Tue, 20 Sep 2022 13:00:15 +0000 (15:00 +0200)]
vabaseenc: Use class entrypoint.

Add a macro to access to class entrypoint and use it instead of move
it to a variable.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3063>

19 months agod3d11: Move format defines to private header
Seungha Yang [Tue, 25 Oct 2022 17:55:34 +0000 (02:55 +0900)]
d3d11: Move format defines to private header

Those defines will be likely changed/deleted in the future, and we
don't need to expose them to public at the moment

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3265>

19 months agoci: Fetch all user cerbero branches when matching branch names
Nirbheek Chauhan [Tue, 25 Oct 2022 14:27:49 +0000 (19:57 +0530)]
ci: Fetch all user cerbero branches when matching branch names

Fixes CI on coordinated merges when the user has more than 20 branches
in their fork, which will happen very easily since new forks will
always have all the branches of the original remote.

```
ci/gitlab/trigger_cerbero_pipeline.py:48: UserWarning: Calling a `list()` method without specifying `get_all=True` or `iterator=True` will return a maximum of 20 items. Your query returned 20 of 37 items. See https://python-gitlab.readthedocs.io/en/v3.9.0/api-usage.html#pagination for more details. If this was done intentionally, then this warning can be supressed by adding the argument `get_all=False` to the `list()` call. (python-gitlab: /usr/local/lib/python3.7/site-packages/gitlab/client.py:979)
  if os.environ["CI_COMMIT_REF_NAME"] in [b.name for b in cerbero.branches.list()]:
```

19 months agoxingmux: move from gst-plugins-ugly to gst-plugins-good
Tim-Philipp Müller [Sun, 23 Oct 2022 19:32:35 +0000 (20:32 +0100)]
xingmux: move from gst-plugins-ugly to gst-plugins-good

Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/issues/415

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3251>

19 months agobuild: Fix building ges with tools disabled
Patrick Griffis [Mon, 24 Oct 2022 19:40:55 +0000 (14:40 -0500)]
build: Fix building ges with tools disabled

If you configure with `tools=disabled` then ges_launch is undefined.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3259>

19 months agoFix various warnings from gobject-introspection
Sebastian Dröge [Tue, 25 Oct 2022 06:39:07 +0000 (09:39 +0300)]
Fix various warnings from gobject-introspection

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3261>

19 months agofdkaac: add minimal unit test
Tim-Philipp Müller [Sat, 22 Oct 2022 10:13:10 +0000 (11:13 +0100)]
fdkaac: add minimal unit test

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1785>

19 months agofdkaacenc: fix output caps in case of implicit signaling and HE-AAC
Tim-Philipp Müller [Sat, 22 Oct 2022 10:10:24 +0000 (11:10 +0100)]
fdkaacenc: fix output caps in case of implicit signaling and HE-AAC

Need to put the actual profile in the output caps otherwise any
capsfilter after the encoder that was used to force the output
profile will fail, such as

  fdkaacenc ! audio/mpeg,stream-format=adts,profile=he-aac-v1 ! ..

because we put profile=lc in there to match the profile signaled
in the ADTS header. This is expressed through the base-profile=lc
in the GStreamer caps though, the profile needs to carry the
'real' profile.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1785>

19 months agofdkaacenc: don't set base-profile=lc for non-backwards compatible output
Tim-Philipp Müller [Fri, 21 Oct 2022 16:10:57 +0000 (17:10 +0100)]
fdkaacenc: don't set base-profile=lc for non-backwards compatible output

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1785>

19 months agofdkaacenc: rename profile=sbr|ps to profile=he-aac-v1|he-aac-v2
Tim-Philipp Müller [Fri, 21 Oct 2022 12:15:29 +0000 (13:15 +0100)]
fdkaacenc: rename profile=sbr|ps to profile=he-aac-v1|he-aac-v2

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1785>

19 months agofdkaacenc: add support for AAC-LD
Piotrek Brzeziński [Tue, 1 Mar 2022 13:12:27 +0000 (14:12 +0100)]
fdkaacenc: add support for AAC-LD

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1785>

19 months agofdkaacenc: add support for HE-AACv1 and HE-AACv2
Piotrek Brzeziński [Wed, 23 Feb 2022 16:17:25 +0000 (17:17 +0100)]
fdkaacenc: add support for HE-AACv1 and HE-AACv2

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1785>

19 months agowebrtc: Fix double free in webrtc-recvonly-h264 demo
Patrick Griffis [Mon, 24 Oct 2022 17:21:47 +0000 (12:21 -0500)]
webrtc: Fix double free in webrtc-recvonly-h264 demo

The "message" signal does not transfer ownership of the GBytes passed
to it so calling g_bytes_unref() on it is incorrect.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3257>

19 months agogst-inspect: Hide GST_PARAM_DOC_SHOW_DEFAULT flag
Seungha Yang [Fri, 21 Oct 2022 16:43:22 +0000 (01:43 +0900)]
gst-inspect: Hide GST_PARAM_DOC_SHOW_DEFAULT flag

It's known flag but only for documentation purpose. Don't show
its (and user cannot understand) value 0x2000

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3241>

19 months agoges: transition: Notify vtype change on ges_extractable_set_asset call
Fabian Orccon [Tue, 18 Oct 2022 00:45:30 +0000 (19:45 -0500)]
ges: transition: Notify vtype change on ges_extractable_set_asset call

Fixes #1454

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3215>

19 months agogst-plugins-bad: Update Windows plugins cache
Seungha Yang [Fri, 21 Oct 2022 19:28:03 +0000 (04:28 +0900)]
gst-plugins-bad: Update Windows plugins cache

Add/update d3d11, qsv, nvcodec, wic, directshow, and amfcodec plugins cache

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3250>

19 months agonvcodec: Update for documentation
Seungha Yang [Fri, 21 Oct 2022 18:02:56 +0000 (03:02 +0900)]
nvcodec: Update for documentation

* Use GST_PARAM_DOC_SHOW_DEFAULT flags for GPU ID related
  properties
* Fix some typos
* Add since markers

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3250>

19 months agomediafoundation: Update for documentation
Seungha Yang [Fri, 21 Oct 2022 17:59:13 +0000 (02:59 +0900)]
mediafoundation: Update for documentation

* Use GST_PARAM_DOC_SHOW_DEFAULT flags for GPU ID related
  properties
* Add doc caps
* Add since markers

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3250>

19 months agomfvideoencoder: Document only hardware encoders
Seungha Yang [Fri, 21 Oct 2022 19:09:39 +0000 (04:09 +0900)]
mfvideoencoder: Document only hardware encoders

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3250>

19 months agomfvideoencoder: Fix device enumeration
Seungha Yang [Sat, 22 Oct 2022 13:37:33 +0000 (22:37 +0900)]
mfvideoencoder: Fix device enumeration

Although a GPU does not support the codec, the other GPU might
be able to support the codec

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3250>

19 months agoamfcodec: Update for documentation
Seungha Yang [Fri, 21 Oct 2022 17:56:23 +0000 (02:56 +0900)]
amfcodec: Update for documentation

* Use GST_PARAM_DOC_SHOW_DEFAULT flags for GPU ID related
  properties
* Add doc caps

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3250>

19 months agoqsv: Use GST_PARAM_DOC_SHOW_DEFAULT flag
Seungha Yang [Fri, 21 Oct 2022 17:53:16 +0000 (02:53 +0900)]
qsv: Use GST_PARAM_DOC_SHOW_DEFAULT flag

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3250>

19 months agod3d11: Update for documentation
Seungha Yang [Fri, 21 Oct 2022 17:49:00 +0000 (02:49 +0900)]
d3d11: Update for documentation

* Use GST_PARAM_DOC_SHOW_DEFAULT flags for GPU ID related
  properties
* Add doc caps
* Increase deinterlace max resolution

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3250>

19 months agod3d11: Run indent
Seungha Yang [Fri, 21 Oct 2022 17:48:23 +0000 (02:48 +0900)]
d3d11: Run indent

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3250>

19 months agowic: Add since marker
Seungha Yang [Sat, 22 Oct 2022 13:33:01 +0000 (22:33 +0900)]
wic: Add since marker

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3250>

19 months agodirectshow: Add since marker
Seungha Yang [Fri, 21 Oct 2022 18:12:19 +0000 (03:12 +0900)]
directshow: Add since marker

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3250>

19 months agoexamples: webrtc: Update to gstreamer-rs 0.19 release
Sebastian Dröge [Mon, 24 Oct 2022 10:18:42 +0000 (13:18 +0300)]
examples: webrtc: Update to gstreamer-rs 0.19 release

Also update the macOS workaround for gstreamer-gl requiring a
`NSRunLoop` / `NSApp` on the main thread, and update from strucopt to
clap 4.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3255>

19 months agoqsv: Enable MinGW toolchain support
Seungha Yang [Fri, 21 Oct 2022 14:20:47 +0000 (23:20 +0900)]
qsv: Enable MinGW toolchain support

Use PCRE regex method to work around (likely) GCC std::regex bug,
and enable building for non-MSVC

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3239>

19 months agortspsrc: Only EOS on timeout if all streams are timed out/EOS
Sebastian Dröge [Fri, 21 Oct 2022 13:23:08 +0000 (16:23 +0300)]
rtspsrc: Only EOS on timeout if all streams are timed out/EOS

Otherwise a stream that is just temporarily inactive might time out and
then can never become active again because the EOS event was sent
already.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3238>

19 months agogl/vulkan: Fix static linking on macOS
Nirbheek Chauhan [Fri, 21 Oct 2022 16:20:01 +0000 (21:50 +0530)]
gl/vulkan: Fix static linking on macOS

duplicate symbol '__invoke_on_main' in:
    /Library/Frameworks/GStreamer.framework/Versions/1.0/lib/libgstvulkan-1.0.a(cocoa_gstvkwindow_cocoa.m.o)
    /Library/Frameworks/GStreamer.framework/Versions/1.0/lib/libgstgl-1.0.a(cocoa_gstglwindow_cocoa.m.o)
ld: 1 duplicate symbol for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Also make the same change in iOS for consistency.

Continuation of https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/issues/1132

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3242>

19 months agowebrtcbin: configure rtpulpfecdec passthrough property
Matthew Waters [Tue, 18 Oct 2022 06:05:41 +0000 (17:05 +1100)]
webrtcbin: configure rtpulpfecdec passthrough property

This allows downstream (payloaders mostly) to be able to correctly
detect actual packet loss from rtp sequence numbers.

See
https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/581
for background.

Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1407

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3212>

19 months agortpulpfecdec: add property for passthrough
Matthew Waters [Tue, 18 Oct 2022 05:51:39 +0000 (16:51 +1100)]
rtpulpfecdec: add property for passthrough

Support for enabling and disabling decoding of FEC data decoding on
packet loss events and unconditional seqnum rewriting of packets.

See
https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/581
for background.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3212>

19 months agowebrtc: Fix critical in webrtc-recvonly-h264 example
Patrick Griffis [Sun, 23 Oct 2022 19:56:32 +0000 (14:56 -0500)]
webrtc: Fix critical in webrtc-recvonly-h264 example

This signal only takes 2 properties yet a third was passed.
This would cause a critical in GLib.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3252>

19 months agonet: Add missing nullable annotation on the name parameter in the net/NTP clock const...
Sebastian Dröge [Sat, 22 Oct 2022 15:34:14 +0000 (18:34 +0300)]
net: Add missing nullable annotation on the name parameter in the net/NTP clock constructors

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3249>

19 months agopadtemplate: Fix annotations
Seungha Yang [Sat, 22 Oct 2022 13:04:57 +0000 (22:04 +0900)]
padtemplate: Fix annotations

gst_caps_replace() does not take ownership of the new caps

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3248>

19 months agogst-libav: Fix synchronization issues and errors created by the forwarding of
Devin Anderson [Tue, 18 Oct 2022 11:37:30 +0000 (11:37 +0000)]
gst-libav: Fix synchronization issues and errors created by the forwarding of
segment events by demuxer.

In order to play nicely with `ffmpeg`, demuxers in `gst-libav` have to make
buffers available to `ffmpeg` while taking the blocking I/O model in `ffmpeg`
into account, which results in buffers not being sent downstream until `ffmpeg`
has processed them in its separate thread.

In constrast, many `gstreamer` events are simply forwarded downstream.
Currently `GST_EVENT_SEGMENT` events are forwarded downstream without any
processing, which can potentially result in:
 * `GST_EVENT_SEGMENT` events being out of sync with buffers
 * `GST_EVENT_SEGMENT` events going out that are incorrect because they apply
   to data seen by the demuxer, but not necessarily seen by downstream elements

I came across this bug when I was attempting to enable G723.1 demuxing/decoding
using the G723.1 demuxer and decoder provided by `ffmpeg`.  I wrote tests to
verify support for the functionality, and found that, in push mode,
`GST_EVENT_SEGMENT` events pushed to the demuxer by the upstream `filesrc`
element would be forwarded to the decoder without modification, resulting in
an internal data streaming error.  With this patch, tests work in both push and
pull mode.

This patch solves the problem by disabling the forwarding of
`GST_EVENT_SEGMENT` events downstream (an initial `GST_EVENT_SEGMENT` event is
still pushed downstream by the demuxer).  It's possible there's a better way to
do this, but, having looked at how a few different `gstreamer` demuxers deal
with `GST_EVENT_SEGMENT` events, it seems like the processing is somewhat
specific to the demuxer implementation, whereas `gst-libav` has one general way
of handling the situation for any `ffmpeg` demuxer.  Perhaps there's a better
way to solve this using the `ffmpeg` API to take advantage of specific demuxer
details.  IDK.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3218>

19 months agogst-inspect: Don't print link to doc if it's known to be unavailable
Seungha Yang [Fri, 21 Oct 2022 20:29:59 +0000 (05:29 +0900)]
gst-inspect: Don't print link to doc if it's known to be unavailable

"gst_element_factory_get_skip_documentation() == true" means
documentation was intentionally skipped for the element feature

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3243>

19 months agogst: uri query: fix inconsistent `uri` nullability assertion
François Laignel [Fri, 21 Oct 2022 09:47:11 +0000 (11:47 +0200)]
gst: uri query: fix inconsistent `uri` nullability  assertion

Functions `gst_query_set_uri` and `gst_query_set_uri_redirection`
can both set a `NULL` `uri`, as annotated in the documentation.
However the functions bodies reject `NULL` `uri`s.

See [1] for a discussion on that matter.

[1]: https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1134#note_1600988

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3237>

19 months agod3d11screencapture: Add WinRT API based capture mode
Seungha Yang [Thu, 6 Oct 2022 19:20:29 +0000 (04:20 +0900)]
d3d11screencapture: Add WinRT API based capture mode

Add Windows Graphics Capture (WGC) API based screen capture mode.
The conditions where this mode is used:
* Explicitly requested by user (capture-api property)
* To capture specific window
* When DXGI desktop duplication API does not work on hybrid graphics systems
  (e.g., multi-gpu laptop)

Full features of this implementation require Windows 11. And Windows 11
SDK is required to build this feature.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3144>

19 months agod3d11screencapture: Subclassing capture implementation
Seungha Yang [Thu, 6 Oct 2022 14:54:14 +0000 (23:54 +0900)]
d3d11screencapture: Subclassing capture implementation

Preparation to use WinRT capture API

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3144>

19 months agoqsv: Add plugin doc
Seungha Yang [Fri, 21 Oct 2022 10:08:49 +0000 (19:08 +0900)]
qsv: Add plugin doc

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2738>

19 months agoqsv: Update SDK version to v2022.2.4
Seungha Yang [Fri, 8 Jul 2022 20:38:05 +0000 (05:38 +0900)]
qsv: Update SDK version to v2022.2.4

See release note
https://github.com/oneapi-src/oneVPL/releases/tag/v2022.2.0

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2738>

19 months agoav1parse: Correct the pts for frames and OBUs inside a TU.
He Junyan [Fri, 14 Oct 2022 08:05:28 +0000 (16:05 +0800)]
av1parse: Correct the pts for frames and OBUs inside a TU.

When the output alignment is smaller than the input alignment, for
example, When the output alignment is "FRAME" and the parse is likely
connecting to a decoder, the current PTS setting for AV1 frames inside
a TU is not very correct.

For example, a TU may begin with non-displayed frames and end with a
displayed frame. The current way will assign the PTS to the first
non-displayed frame, which is a decode-only frame and the PTS will be
discarded in the video decoder. While the last displayed frame has
invalid PTS, and so the video decoder needs to guess its PTS based on
the frame rate and previous frame's PTS. This is not a decent and
robust way. And more important, when the previous frames provide DTS,
the video decoder will also guess the PTS based on the previous frames'
DTS and trigger the warning like:

  gstvideodecoder.c:3147:gst_video_decoder_prepare_finish_frame: \
  <vavp9dec0> decreasing timestame

It sets the reordered_output and makes the decoder in free run mode.

We should correct the PTS for a TU, let the non-displayed frames have
no PTS while set the correct PTS to the displayed one. Also, when the
AV1 stream has multi spatial layers, there are more than one displayed
frames inside one TU with the same PTS.

Note: If the input alignment is not TU aligned, we can not know the
exact PTS of this TU, and so we just clear the PTS of the decode only
frame and leave others unchanged.

We also correct all the PTS if the output is OBU aligned. All their
PTS and DTS are set to the input buffer's PTS.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3182>

19 months agoav1parse: Only check the TU bound when the alignment is TU.
He Junyan [Fri, 14 Oct 2022 09:25:45 +0000 (17:25 +0800)]
av1parse: Only check the TU bound when the alignment is TU.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3182>

19 months agoav1parse: push all data once when input alignment not smaller than output.
He Junyan [Fri, 14 Oct 2022 07:46:16 +0000 (15:46 +0800)]
av1parse: push all data once when input alignment not smaller than output.

When the incoming data has big alignment than the output, we do not need to
call finish_frame() and exit the current handle_frame() for each splitted
frame. We can push them all at one shot with in one handle_frame(), whcih
may improve the performance and can help us to find the edge of TU.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3182>

19 months agoav1parse: Set the output buffer flags correctly.
He Junyan [Fri, 14 Oct 2022 07:27:52 +0000 (15:27 +0800)]
av1parse: Set the output buffer flags correctly.

The current code forgets to clear some flags and has some typo.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3182>

19 months agodocs: plugins-scanner: Handle interface used for plugin API properties
Thibault Saunier [Fri, 21 Oct 2022 09:11:13 +0000 (11:11 +0200)]
docs: plugins-scanner: Handle interface used for plugin API properties

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3236>

19 months agowebrtcbin: also add rtcp-fb ccm fir for video mlines by default
Matthew Waters [Thu, 20 Oct 2022 23:50:36 +0000 (10:50 +1100)]
webrtcbin: also add rtcp-fb ccm fir for video mlines by default

In addition to the 'nack pli' already added.  Both are supported by
rtpbin/rtpsession by default already.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3235>

19 months agobuild/gl: fix automatic dispmanx detection for rpi4
Matthew Waters [Tue, 4 Oct 2022 04:39:51 +0000 (05:39 +0100)]
build/gl: fix automatic dispmanx detection for rpi4

rpi4 doesn't contain dispmanx but still contains bcm_host.pc which
confuses the configure detection.  Add an explicit check for
EGL_DISPMANX_WINDOW_T to ensure that we only build with dispmanx when
the types are available.

Fixes: https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/issues/893
Fixes: https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/issues/952
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3230>

19 months agowebrtcbin: Improve documentation of 'turn-server' property
Sangchul Lee [Wed, 19 Oct 2022 07:03:55 +0000 (16:03 +0900)]
webrtcbin: Improve documentation of 'turn-server' property

Description about how to set time-limited credentials is added.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3229>

19 months agodocs: plugin-scanner: Stop updating "long-name" metadata
Seungha Yang [Mon, 17 Oct 2022 18:08:44 +0000 (03:08 +0900)]
docs: plugin-scanner: Stop updating "long-name" metadata

The "long-name" value can be environment dependent, and it's not
actually used by our documentation.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3208>

19 months agoparse: Adjust debug log level
Seungha Yang [Wed, 19 Oct 2022 13:30:38 +0000 (22:30 +0900)]
parse: Adjust debug log level

That's not an error case at all

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3228>

19 months agodocs/glcontextconfig: rename title to not be GstGLContext
Matthew Waters [Wed, 19 Oct 2022 11:08:17 +0000 (22:08 +1100)]
docs/glcontextconfig: rename title to not be GstGLContext

Can be confusing havint two pages that both have GstGLContext as the
title.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3227>

19 months ago{element,deviceprovider}factory: g_object_new() can't ever return NULL
Sebastian Dröge [Wed, 19 Oct 2022 10:34:28 +0000 (13:34 +0300)]
{element,deviceprovider}factory: g_object_new() can't ever return NULL

So treat it as the assertion it is.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3226>

19 months agoelementfactory: Handle element factory loading failure in gst_element_factory_create_...
Sebastian Dröge [Wed, 19 Oct 2022 10:33:39 +0000 (13:33 +0300)]
elementfactory: Handle element factory loading failure in gst_element_factory_create_valist() not as assertion

In gst_element_factory_create_with_properties() it is a normal error
path so let's keep this consistent.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3226>

19 months agogst: Use G_TYPE_INVALID instead of 0 for GTypes
Sebastian Dröge [Wed, 19 Oct 2022 10:28:06 +0000 (13:28 +0300)]
gst: Use G_TYPE_INVALID instead of 0 for GTypes

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3226>

19 months agotests: parse-launch: remove assignment order tests
Mathieu Duponchelle [Wed, 14 Sep 2022 22:06:49 +0000 (00:06 +0200)]
tests: parse-launch: remove assignment order tests

These tests relied on setting the name of an element twice to verify
that the last one set took precedence, however name is a CONSTRUCT property
and the parser now errors out when such properties are set twice, in
g_object_new_with_properties .

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3026>

19 months agoparse: refactor to make use of gst_element_factory_make_with_properties
Mathieu Duponchelle [Tue, 13 Sep 2022 21:16:08 +0000 (23:16 +0200)]
parse: refactor to make use of gst_element_factory_make_with_properties

Instead of creating the element first, then setting properties and
presets, we gather those and construct the element with the properties.

This means users of gst_parse_launch can now set construct-only
properties.

Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1380

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3026>

19 months agogstminiobject: shares capacity increase
Bunio_FH [Tue, 18 Oct 2022 14:41:36 +0000 (16:41 +0200)]
gstminiobject: shares capacity increase

during the MSE (WebKit) tests from Apple suite:
https://hls-streaming.cdn-apple.com/hls_conformance/dist/v1.1/index.html?pretty=true&whitelist=MSE%20Suite
webkit attempts to add a single audio buffer containing ~35.5k frames.
when corresponding GstSamples are pulled buffer is being referenced
more than object capacity allows: 2^15-1. since the case could be considered
malformed a surgical patch is applied to increase the capacity.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3221>

19 months agofake{video|audio}sink: don't proxy properties at instance init.
Mathieu Duponchelle [Fri, 23 Sep 2022 16:25:41 +0000 (18:25 +0200)]
fake{video|audio}sink: don't proxy properties at instance init.

Instead proxy properties from the GstBaseSink class at class_init time,
and duplicate the rest of the fakesink properties manually.

Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1442

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3073>

19 months agocdparanoia: Ignore compiler warning coming from the cdparanoia header
Jordan Petridis [Wed, 6 Jul 2022 18:45:24 +0000 (21:45 +0300)]
cdparanoia: Ignore compiler warning coming from the cdparanoia header

When trying to build the plugin, GCC starts complaining about issues
with one of the cdparanoia headers and it block us from being able
to build the plugin with Werror.

The current warning in the header look like this:

```
[1/2] Compiling C object subprojects/gst-plugins-base/ext/cdparanoia/libgstcdparanoia.so.p/gstcdparanoiasrc.c.o
In file included from ../subprojects/gst-plugins-base/ext/cdparanoia/gstcdparanoiasrc.h:37,
                 from ../subprojects/gst-plugins-base/ext/cdparanoia/gstcdparanoiasrc.c:31:
/usr/include/cdda/cdda_interface.h:164:3: warning: initialization discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
  164 |   "Success",
      |   ^~~~~~~~~
...
/usr/include/cdda/cdda_interface.h:163:14: warning: ‘strerror_tr’ defined but not used [-Wunused-variable]
  163 | static char *strerror_tr[]={
      |              ^~~~~~~~~~~
[2/2] Linking target subprojects/gst-plugins-base/ext/cdparanoia/libgstcdparanoia.so
```

Last release of cdparanoia was in 2008, so our best bet for the
time is to ignore the warnings.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2722>

19 months agowebrtcbin: support adding TURN servers after pipeline start
Alba Mendez [Tue, 18 Oct 2022 09:16:20 +0000 (11:16 +0200)]
webrtcbin: support adding TURN servers after pipeline start

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

When a TURN server is added for the first time, propagate
the change to all nice streams that already exist. This
lets us add servers after the pipeline has been started
(and streams have been added).

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3217>

19 months agomeson: Use run_command check: true for windows binary subprojects
Nirbheek Chauhan [Wed, 19 Oct 2022 03:52:21 +0000 (09:22 +0530)]
meson: Use run_command check: true for windows binary subprojects

Fixes a warning about using the check kwarg

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3224>

19 months agoexamples: webrtc: mp-sendrecv: add bus handler
Sam Van Den Berge [Tue, 18 Oct 2022 13:28:32 +0000 (15:28 +0200)]
examples: webrtc: mp-sendrecv: add bus handler

Without this bus handler, messages posted to the bus will keep a ref to
their source elements, preventing them from being disposed.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3219>

19 months agoexamples: webrtc: mp-sendrecv: set element states to NULL after removing them from...
Sam Van Den Berge [Tue, 18 Oct 2022 13:27:20 +0000 (15:27 +0200)]
examples: webrtc: mp-sendrecv: set element states to NULL after removing them from pipeline

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3219>

19 months agoexamples: webrtc: mp-sendrecv: remove wrong gst_object_unrefs
Sam Van Den Berge [Tue, 18 Oct 2022 13:17:40 +0000 (15:17 +0200)]
examples: webrtc: mp-sendrecv: remove wrong gst_object_unrefs

In !2958 some gst_object_unrefs were added. However these two don't
belong there because ownership is transfered due to the gst_bin_add_many
call a bit above.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3219>

19 months agosrtp: Fix test skipping when plugin option is disabled
Fabian Orccon [Mon, 17 Oct 2022 11:48:12 +0000 (06:48 -0500)]
srtp: Fix test skipping when plugin option is disabled

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3200>

19 months agod3d11videosink: Add "emit-present" property
Seungha Yang [Thu, 13 Oct 2022 15:17:52 +0000 (00:17 +0900)]
d3d11videosink: Add "emit-present" property

Controls the decision for "present" signal use, and
allows delayed "present" signal handler install via the property

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3176>

19 months agoplay: Add/fix various annotations
Sebastian Dröge [Mon, 17 Oct 2022 16:36:13 +0000 (19:36 +0300)]
play: Add/fix various annotations

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3194>

19 months agosdp: Add/fix various annotations
Sebastian Dröge [Mon, 17 Oct 2022 11:43:42 +0000 (14:43 +0300)]
sdp: Add/fix various annotations

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3194>

19 months agotag: Add/fix various annotations
Sebastian Dröge [Mon, 17 Oct 2022 11:51:03 +0000 (14:51 +0300)]
tag: Add/fix various annotations

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3194>

19 months agoallocators: Add/fix various annotations
Sebastian Dröge [Mon, 17 Oct 2022 08:31:05 +0000 (11:31 +0300)]
allocators: Add/fix various annotations

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3194>

19 months agovulkan: Add/fix various annotations
Sebastian Dröge [Mon, 17 Oct 2022 08:29:02 +0000 (11:29 +0300)]
vulkan: Add/fix various annotations

And fix a memory leak in gst_vulkan_display_wayland_new() in error
cases.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3194>