platform/upstream/gstreamer.git
2 years agomeson: Add some messages when selecting libsoup
Nirbheek Chauhan [Fri, 25 Mar 2022 19:32:02 +0000 (01:02 +0530)]
meson: Add some messages when selecting libsoup

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

2 years agosoup: Fix usage of symbols / defines that are gone in libsoup3
Nirbheek Chauhan [Fri, 25 Mar 2022 19:29:12 +0000 (00:59 +0530)]
soup: Fix usage of symbols / defines that are gone in libsoup3

I am not sure about the SOUP_MESSAGE_OVERWRITE_CHUNKS change, but it
was definitely already broken when using libsoup-3.0 in a shared
build. souphttpsrc probably needs to be ported from SoupMessage to
SoupServerMessage when using libsoup-3.0.

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

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

2 years agosoup: Fix pre-processor macros in souploader for libsoup-3.0
Nirbheek Chauhan [Fri, 25 Mar 2022 19:26:04 +0000 (00:56 +0530)]
soup: Fix pre-processor macros in souploader for libsoup-3.0

Some of the preprocessor conditionals in the loader were very broken
with libsoup-3.0 + --default-library=static

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

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

2 years agopbutils: Fix wmv screen detection
Edward Hervey [Mon, 28 Mar 2022 10:13:12 +0000 (12:13 +0200)]
pbutils: Fix wmv screen detection

strncmp vs !strncmp :)

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

2 years agoges: remove memory leak with description
Stéphane Cerveau [Mon, 28 Mar 2022 11:47:52 +0000 (13:47 +0200)]
ges: remove memory leak with description

free the capsdesc

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

2 years agonle: clear seek event properly
Stéphane Cerveau [Mon, 28 Mar 2022 11:20:40 +0000 (13:20 +0200)]
nle: clear seek event properly

Use gst_clear_event instead of g_clear_object
avoiding a failing gobject unref

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

2 years agoqsvencoder: Add support for dynamic bitrate update
Seungha Yang [Sun, 27 Mar 2022 14:27:54 +0000 (23:27 +0900)]
qsvencoder: Add support for dynamic bitrate update

... and add more encoding options.

QSV API supports dynamic bitrate change without IDR insertion.
That's more efficient way of runtime encoding option update
than starting from new sequence with IDR per bitrate option change.

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

2 years agoqsvh265enc: Add missing gop-size property
Seungha Yang [Fri, 25 Mar 2022 14:15:33 +0000 (23:15 +0900)]
qsvh265enc: Add missing gop-size property

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

2 years agoqsv: Fix mfxFrameAllocator::Lock for encoder
Seungha Yang [Fri, 25 Mar 2022 12:13:22 +0000 (21:13 +0900)]
qsv: Fix mfxFrameAllocator::Lock for encoder

Only read map is possible for encoder input system memory

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

2 years agopython: Add a suppression file for a leak in PyGObject
Thibault Saunier [Tue, 29 Mar 2022 16:43:56 +0000 (18:43 +0200)]
python: Add a suppression file for a leak in PyGObject

And ensure that the CI runs GES valgrind test when we change the
overrides as many GES tests are implemented in python

Proper fix is at: https://gitlab.gnome.org/GNOME/pygobject/-/merge_requests/204

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

2 years agoavviddec: Remove vc1/wmv3 override
Edward Hervey [Tue, 29 Mar 2022 07:36:06 +0000 (09:36 +0200)]
avviddec: Remove vc1/wmv3 override

FFMPEG 5+ doesn't allow overriding the codec anymore (causes a segfault if you
attempt to do that). But the best part is ... that with the current caps
implementation in pad template and gst_ffmpeg_caps_to_codecid() we would never
replace it by anything different than the existing codec id.

Fixes #1054

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

2 years agodocs: Fix doc generation example
Edward Hervey [Tue, 29 Mar 2022 07:24:55 +0000 (09:24 +0200)]
docs: Fix doc generation example

They need to be generated from the devenv else it just hangs for no reason.

See #1108

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

2 years agopython: Add support for the GstURIHandlerInterface
Thibault Saunier [Mon, 6 Dec 2021 22:27:24 +0000 (19:27 -0300)]
python: Add support for the GstURIHandlerInterface

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

2 years agovalidate/media-info: silence unsed variable warning
Matthew Waters [Mon, 28 Mar 2022 10:15:15 +0000 (21:15 +1100)]
validate/media-info: silence unsed variable warning

Fixes:

../validate/gst/validate/gst-validate-media-info.c:714:28: error: variable 'total_sink_count' set but not used [-Werror,-Wunused-but-set-variable]
  guint id, ncounters = 0, total_sink_count = 0;
                           ^

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

2 years agortsp-stream: remove unused variable:
Matthew Waters [Mon, 28 Mar 2022 10:03:16 +0000 (21:03 +1100)]
rtsp-stream: remove unused variable:

Fixes:

../gst/rtsp-server/rtsp-stream.c:2670:9: error: variable 'n_messages' set but not used [-Werror,-Wunused-but-set-variable]
  guint n_messages = 0;
        ^

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

2 years agoapplemeida/texturecache: remove unused variable
Matthew Waters [Mon, 28 Mar 2022 09:51:35 +0000 (20:51 +1100)]
applemeida/texturecache: remove unused variable

Fixes:

../sys/applemedia/videotexturecache.m:71:20: error: variable 'features' set but not used [-Werror,-Wunused-but-set-variable]
  GstCapsFeatures *features;
                   ^

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

2 years agoapplemedia/corevideobuffer: remove unused variable
Matthew Waters [Mon, 28 Mar 2022 09:50:27 +0000 (20:50 +1100)]
applemedia/corevideobuffer: remove unused variable

Fixes:

../sys/applemedia/corevideobuffer.c:209:19: error: variable 'video_meta' set but not used [-Werror,-Wunused-but-set-variable]
    GstVideoMeta *video_meta;
                  ^

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

2 years agoapplemedia/iosgl: remove unused variable
Matthew Waters [Mon, 28 Mar 2022 09:49:01 +0000 (20:49 +1100)]
applemedia/iosgl: remove unused variable

Fixes:

../sys/applemedia/iosurfaceglmemory.c:219:41: error: variable 'texfmt' set but not used [-Werror,-Wunused-but-set-variable]
    GLuint tex_id, tex_target, texifmt, texfmt;
                                        ^

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

2 years agovtdec: remove unused variable
Matthew Waters [Mon, 28 Mar 2022 09:37:54 +0000 (20:37 +1100)]
vtdec: remove unused variable

Fixes:

../sys/applemedia/vtdec.c:611:35: error: variable 'output_flags' set but not used [-Werror,-Wunused-but-set-variable]
  VTDecodeFrameFlags input_flags, output_flags;
                                  ^

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

2 years agoavsamplevideosink: remove unused variable
Matthew Waters [Mon, 28 Mar 2022 09:24:59 +0000 (20:24 +1100)]
avsamplevideosink: remove unused variable

Fixes

../sys/applemedia/avsamplevideosink.m:80:20: error: variable 'gstelement_class' set but not used [-Werror,-Wunused-but-set-variable]
  GstElementClass *gstelement_class;
                   ^

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

2 years agoavfassetsrc: fix unused-but-set warning
Matthew Waters [Mon, 28 Mar 2022 09:11:29 +0000 (20:11 +1100)]
avfassetsrc: fix unused-but-set warning

../sys/applemedia/avfassetsrc.m:1014:12: error: variable 'caps' set but not used [-Werror,-Wunused-but-set-variable]
  GstCaps *caps;
           ^

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

2 years agospeed: fix unused-but-set warning
Matthew Waters [Mon, 28 Mar 2022 08:42:04 +0000 (19:42 +1100)]
speed: fix unused-but-set warning

../gst/speed/gstspeed.c:523:39: error: variable 'base' set but not used [-Werror,-Wunused-but-set-variable]
      gint64 start_value, stop_value, base;
                                      ^

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

2 years agoresindvd: silence unused-but-set warning
Matthew Waters [Mon, 28 Mar 2022 07:38:23 +0000 (18:38 +1100)]
resindvd: silence unused-but-set warning

../ext/resindvd/gstpesfilter.c:117:11: error: variable 'STD_buffer_size_bound' set but not used [-Werror,-Wunused-but-set-variable]
  guint16 STD_buffer_size_bound;
          ^

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

2 years agompegts: don't shadow res variable
Matthew Waters [Mon, 28 Mar 2022 07:23:20 +0000 (18:23 +1100)]
mpegts: don't shadow res variable

Fixes unused-but-set warning:

../gst/mpegtsmux/gstbasetsmux.c:2115:43: error: variable 'res' set but not used [-Werror,-Wunused-but-set-variable]
      gboolean all_headers, done = FALSE, res = FALSE;
                                          ^

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

2 years agompeg: fix unused-but-set warning
Matthew Waters [Mon, 28 Mar 2022 07:12:43 +0000 (18:12 +1100)]
mpeg: fix unused-but-set warning

../gst-libs/gst/mpegts/gst-dvb-section.c:206:9: error: variable 'i' set but not used [-Werror,-Wunused-but-set-variable]
  guint i = 0, allocated_events = 12;
        ^
../gst-libs/gst/mpegts/gst-dvb-section.c:365:9: error: variable 'i' set but not used [-Werror,-Wunused-but-set-variable]
  guint i = 0, allocated_streams = 12;
        ^
../gst-libs/gst/mpegts/gst-dvb-section.c:543:9: error: variable 'i' set but not used [-Werror,-Wunused-but-set-variable]
  guint i = 0, allocated_streams = 12;
        ^
../gst-libs/gst/mpegts/gst-dvb-section.c:885:9: error: variable 'i' set but not used [-Werror,-Wunused-but-set-variable]
  guint i = 0, allocated_services = 8;
        ^
../gst-libs/gst/mpegts/gst-dvb-section.c:1316:9: error: variable 'i' set but not used [-Werror,-Wunused-but-set-variable]
  guint i = 0, allocated_services = 8;
        ^

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

2 years agoosxcoreaudio: fix unused-but-set warning
Matthew Waters [Mon, 28 Mar 2022 07:12:03 +0000 (18:12 +1100)]
osxcoreaudio: fix unused-but-set warning

../sys/osxaudio/gstosxcoreaudio.c:480:18: error: variable 'interleaved' set but not used [-Werror,-Wunused-but-set-variable]
  gboolean sign, interleaved;
                 ^

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

2 years agovideo-format: Move NV12_8L128 into the correct position in GST_VIDEO_FORMATS_ALL
Sebastian Dröge [Mon, 28 Mar 2022 07:10:45 +0000 (10:10 +0300)]
video-format: Move NV12_8L128 into the correct position in GST_VIDEO_FORMATS_ALL

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

2 years agompegdemux: silence unused-but-set werror
Matthew Waters [Mon, 28 Mar 2022 04:56:22 +0000 (15:56 +1100)]
mpegdemux: silence unused-but-set werror

../gst/mpegdemux/gstpesfilter.c:117:11: error: variable 'STD_buffer_size_bound' set but not used [-Werror,-Wunused-but-set-variable]
  guint16 STD_buffer_size_bound;
          ^

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

2 years agoFix GstAmcSurfaceTexture segfault
Andrew Pritchard [Fri, 25 Mar 2022 03:25:02 +0000 (14:25 +1100)]
Fix GstAmcSurfaceTexture segfault
Check that `self` and `self->callback` are defined. `self` can be set to
`NULL` in `remove_listener`, and `self->callback` can be set to `NULL`
inside `gst_amc_surface_texture_jni_set_on_frame_available_callback`.
This can cause a segfault since the Java object can outlive the C
object, and call the callback after `remove_listener` is called.

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

2 years agoexamples/player/android: add missing dummy.cpp
Matthew Waters [Mon, 28 Mar 2022 03:36:24 +0000 (14:36 +1100)]
examples/player/android: add missing dummy.cpp

allows libc++_shared.so to be placed in the application

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

2 years agodeinterlace: silence unused-but-set werror from imported code
Matthew Waters [Mon, 28 Mar 2022 02:35:17 +0000 (13:35 +1100)]
deinterlace: silence unused-but-set werror from imported code

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

2 years agoexamples/player/android: update for android changes
Matthew Waters [Mon, 28 Mar 2022 02:28:56 +0000 (13:28 +1100)]
examples/player/android: update for android changes

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

2 years agoosxvideosink: fix unused-but-set-variable warning
Matthew Waters [Sun, 27 Mar 2022 22:50:38 +0000 (09:50 +1100)]
osxvideosink: fix unused-but-set-variable warning

../sys/osxvideo/osxvideosink.m:859:11: error: variable 'data' set but not used [-Werror,-Wunused-but-set-variable]
  guint8 *data, *readp, *writep;
          ^

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

2 years agorawvideoparse: set format from caps in gst_raw_video_parse_set_config_from_caps
Corentin Damman [Wed, 16 Mar 2022 10:31:56 +0000 (10:31 +0000)]
rawvideoparse: set format from caps in gst_raw_video_parse_set_config_from_caps

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

2 years agoglmixerbin: slightly better pad/element creation
Matthew Waters [Sun, 27 Mar 2022 05:35:14 +0000 (16:35 +1100)]
glmixerbin: slightly better pad/element creation

Use the return value from gst_element_link_pads() and gst_bin_add()

Fixes:

../ext/gl/gstglmixerbin.c:305:12: error: variable 'res' set but not used [-Werror,-Wunused-but-set-variable]
  gboolean res = TRUE;
           ^

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

2 years agoccconverter: ensure correct ordering of cea608 across output buffers
Matthew Waters [Wed, 23 Mar 2022 06:31:37 +0000 (17:31 +1100)]
ccconverter: ensure correct ordering of cea608 across output buffers

e.g. if a 60fps output is configured, we can only produce a single field
of cea608 that must alternate between field 1 and field 2.

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

2 years agoccconverter: ignore padding cea608 data even if marked as 'valid'
Matthew Waters [Wed, 23 Mar 2022 04:13:10 +0000 (15:13 +1100)]
ccconverter: ignore padding cea608 data even if marked as 'valid'

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

2 years agov4l2codecs: Detect missing M2M_HOLD_CAPTURE_BUF
Nicolas Dufresne [Wed, 23 Mar 2022 14:36:28 +0000 (10:36 -0400)]
v4l2codecs: Detect missing M2M_HOLD_CAPTURE_BUF

Produce an error if we try to use the feature of holding capture buffer
but it is not supported by the driver. Ingoring this can lead to stalls
as the driver will run-out of capture buffer to decode into. This
affects slice decoders but also split-field interlaced decoding.

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

2 years agov4l2codecs: h264: Set other field poc if available
Nicolas Dufresne [Wed, 23 Mar 2022 13:11:35 +0000 (09:11 -0400)]
v4l2codecs: h264: Set other field poc if available

Whenever the other field POC is available, pass it back to the
driver. This should not be strictly required, but it makes things
easier to debug and more forgiven.

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

2 years agov4l2codecs: Trace request by it FD
Nicolas Dufresne [Tue, 21 Dec 2021 15:59:37 +0000 (10:59 -0500)]
v4l2codecs: Trace request by it FD

This helps when crossing the debug logs with the kernel logs.

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

2 years agov4l2codecs: h264: Fix dpb entry flag FLAG_FIELD
Nicolas Dufresne [Tue, 21 Dec 2021 15:55:58 +0000 (10:55 -0500)]
v4l2codecs: h264: Fix dpb entry flag FLAG_FIELD

The logic to guess back this value was broken. Use the value
now saved into the picture instead. This was tested using
LibreELEC patched 5.15 kernel, and fixed the interlaced decode
issues.

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

2 years agocodecs: h264: Save the field_pic_flag
Nicolas Dufresne [Tue, 21 Dec 2021 15:52:32 +0000 (10:52 -0500)]
codecs: h264: Save the field_pic_flag

This flag is set when the stream is interlaced and the specific
slice is made of single parity fields rather the paired at the
macroblock layer. This is rarely needed in late decoding process
but the Rockchip RKVDEC HW interface requires it, hence needs to
be passed through V4L2 Stateless interface.

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

2 years agod3d11: Fix example build error
Xavier Claessens [Fri, 25 Mar 2022 17:26:52 +0000 (13:26 -0400)]
d3d11: Fix example build error

```
../subprojects/gst-plugins-bad/tests/examples/d3d11/d3d11device.cpp:129:50: error: invalid conversion from ‘int’ to ‘DXGI_FORMAT’ [-fpermissive]
  129 |     D3D11_SHADER_RESOURCE_VIEW_DESC srv_desc = { 0, };
```

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

2 years agogl: cocoa: fix warnings of unused variables
Stéphane Cerveau [Fri, 25 Mar 2022 12:00:13 +0000 (13:00 +0100)]
gl: cocoa: fix warnings of unused variables

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

2 years agoFetch libxml2 subproject using http instead of ftp
Johan Sternerup [Wed, 23 Mar 2022 12:58:24 +0000 (13:58 +0100)]
Fetch libxml2 subproject using http instead of ftp

The official releases of libxml2 have been migrated to gitlab where
they are published for download via HTTP instead of FTP. Besides
adapting to the new location we now also get the benefit that the
tarball can be downloaded in restricted networks where FTP might be
blocked.

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

2 years agonavigationtest: Add some support for modifiers
Thibault Saunier [Fri, 25 Mar 2022 14:42:03 +0000 (11:42 -0300)]
navigationtest: Add some support for modifiers

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

2 years agonavigation: Add support for key Modifiers in all relevant events
Thibault Saunier [Fri, 18 Mar 2022 16:59:32 +0000 (16:59 +0000)]
navigation: Add support for key Modifiers in all relevant events

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

2 years agova: h265dec: Fix a crash because of missing reference frame.
He Junyan [Thu, 24 Mar 2022 13:39:30 +0000 (21:39 +0800)]
va: h265dec: Fix a crash because of missing reference frame.

Some problematic H265 stream may miss the reference frame in the DPB,
and get some message like: "No short term reference picture for xxx".
So there may be empty entries in ref_pic_list0/1 when passing to
decode_slice() function of sub class. We need to check the NULL pointer.

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

2 years agoopenexr: Specify modules when finding OpenEXR.
Chun-wei Fan [Thu, 24 Mar 2022 07:19:27 +0000 (15:19 +0800)]
openexr: Specify modules when finding OpenEXR.

Specify modules to look for OpenEXR when CMake is used, as we may have
CMake config files instead of pkg-config files that result from building
OpenEXR, which may be built with CMake which is typically the case on Visual
Studio builds.

In this case, Meson does seem to find the 'OpenEXR' package with CMake
after trying pkg-config, but does not consider it enough without the
'modules:' argument.

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

2 years agowebrtcbin: Update documentation of 'get-stats' action signal
Sangchul Lee [Mon, 21 Mar 2022 15:30:28 +0000 (00:30 +0900)]
webrtcbin: Update documentation of 'get-stats' action signal

Some stats fields are updated according to the current implementation.

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

2 years agortpptdemux: fix leak of caps when ignoring a pt
Matthew Waters [Wed, 17 Nov 2021 06:27:13 +0000 (17:27 +1100)]
rtpptdemux: fix leak of caps when ignoring a pt

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

2 years agoRevert "webrtcbin: fix msid line and allow customization"
Mathieu Duponchelle [Thu, 24 Mar 2022 23:27:42 +0000 (00:27 +0100)]
Revert "webrtcbin: fix msid line and allow customization"

This reverts commit 3cad3455377d5a22faa138d9df840257059776c8.

That commit was breaking the association between an audio and
a video track in the standard case.

In practice, to support carrying separate MediaStream, we are
going a way to map what MediaStreamTrack belong to what MediaStream,
but that will require some thinking about the API.

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

2 years agotsdemux: Don't check SCTE events for being too far from the PCR
Vivia Nikolaidou [Thu, 24 Mar 2022 17:55:48 +0000 (19:55 +0200)]
tsdemux: Don't check SCTE events for being too far from the PCR

Otherwise it happens that SCTE events can only be scheduled up to 15
seconds since the last seen PCR, which is a useless restriction.

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

2 years agonavigation: Add missing annotation to send_event_simple
Vivienne Watermeier [Thu, 24 Mar 2022 12:01:52 +0000 (13:01 +0100)]
navigation: Add missing annotation to send_event_simple

Adds the missing "transfer full" annotation for the event argument.

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

2 years agowebrtcbin: fix msid line and allow customization
Mathieu Duponchelle [Mon, 21 Mar 2022 22:03:36 +0000 (23:03 +0100)]
webrtcbin: fix msid line and allow customization

From https://datatracker.ietf.org/doc/html/draft-ietf-mmusic-msid-16:

> Multiple media descriptions with the same value for msid-id and
> msid-appdata are not permitted.

Our previous implementation of simply using the CNAME as the msid
identifier and the name of the transceiver as the msid appdata was
misguided and incorrect, and created issues when bundling multiple
video streams together: the ontrack event was emitted with the same
streams for the two bundled medias, at least in Firefox.

Instead, use the transceiver name as the identifier, and expose
a msid-appdata property on transceivers to allow for further
customization by the application. When the property is not set,
msid-appdata can be left empty as it is specified as optional.

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

2 years agowebrtc: Update dependencies of the Rust examples
Sebastian Dröge [Thu, 24 Mar 2022 10:05:29 +0000 (12:05 +0200)]
webrtc: Update dependencies of the Rust examples

And also clean up code a bit while updating to new APIs.

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

2 years agoFix license as GES is released under the LGPL2+ license
Thibault Saunier [Mon, 14 Mar 2022 12:06:46 +0000 (09:06 -0300)]
Fix license as GES is released under the LGPL2+ license

This was a mistake that some of the licensing notice in a few files was
referring to GPL3+ and it needs fixing

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

2 years agowpe: Mark first audio buffer as discont
Thibault Saunier [Wed, 5 Jan 2022 13:15:34 +0000 (10:15 -0300)]
wpe: Mark first audio buffer as discont

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

2 years agowpe: Use `about:blank` as default URL to support only using load-bytes
Thibault Saunier [Tue, 4 Jan 2022 18:49:35 +0000 (15:49 -0300)]
wpe: Use `about:blank` as default URL to support only using load-bytes

WebKit is not going to render anything until a URI is set, leading to a
WPE posting a `WPE View did not render a buffer` error message. To avoid
requiring the user to know it if they only want to use
`wpesrc::load-bytes` we can just use `about:blank` as default and
everything will work as users would expect.

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

2 years agovalidate:scenario: Support args in the `emit-signal` action
Thibault Saunier [Tue, 4 Jan 2022 17:53:06 +0000 (14:53 -0300)]
validate:scenario: Support args in the `emit-signal` action

This was never needed before but it is generally useful and there
was a todo about it

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

2 years agowebrtc_sendrecv.py: Link pads instead of elements
Nirbheek Chauhan [Wed, 23 Mar 2022 09:59:55 +0000 (15:29 +0530)]
webrtc_sendrecv.py: Link pads instead of elements

This was not a problem here because even if we end up accidentally
linking to the wrong pad, things will work out eventually as long as
one pad-added is emitted for each pad that is added.

But it will be a huge problem if someone copies this code and changes
something that requires different handling for different sorts of
pads. The resultant code will be racy. Let's not do this, it's a bad
example.

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

2 years agoREADME: update documentation for macOS
Stéphane Cerveau [Fri, 25 Feb 2022 14:03:11 +0000 (15:03 +0100)]
README: update documentation for macOS

Give hints regarding the certificates
needed by Python.

urllib.error.URLError: urlopen error [SSL ..

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

2 years agofakevideosink,fakeaudiosink: Proxy handoff and preroll-handoff signals
Seungha Yang [Thu, 27 Jan 2022 14:54:34 +0000 (23:54 +0900)]
fakevideosink,fakeaudiosink: Proxy handoff and preroll-handoff signals

Proxy signals for application to be able to consume them

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

2 years agoaom: av1enc: Specify Temporal Unit alignment
Seungha Yang [Fri, 24 Dec 2021 10:49:34 +0000 (19:49 +0900)]
aom: av1enc: Specify Temporal Unit alignment

Encoded bitstream consists of leading Temporal delimiter OBU
with frame, that's Temporal Unit alignment.

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

2 years agoqsvencoder: Clear caps after debug print
Seungha Yang [Wed, 23 Mar 2022 17:52:45 +0000 (02:52 +0900)]
qsvencoder: Clear caps after debug print

Otherwise debug function will print (null) for alread cleared pointer

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

2 years agoqsvh264enc: Fix profile and level setting in codec data
Seungha Yang [Wed, 23 Mar 2022 17:43:43 +0000 (02:43 +0900)]
qsvh264enc: Fix profile and level setting in codec data

The profile field in SPS is located after header byte

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

2 years agonvcodec: Add new Direct3D11/CUDA mode encoder implementation
Seungha Yang [Tue, 15 Mar 2022 19:58:16 +0000 (04:58 +0900)]
nvcodec: Add new Direct3D11/CUDA mode encoder implementation

Adding new encoder elements nvd3d11{h264,h265}enc for Direct3D11
input support and re-written nvcuda{h264,h265}enc elements.
Newly writeen elements have some differences compared with old
nv{h264,h265}enc including non-backward compatible changes.

* RGBA is not a supported input format any more:
  New elements will support only YUV formats to avoid implicit conversion
  done by hardware. Ideally it should be done by upstream element
  in order to have more control on it. Moreover, RGBA support can cause
  redundant RGBA -> YUV conversion if multiple encoders are
  used for the same RGBA input
* Subsampled planar format support is dropped:
  I420 and YV12 format are not supported formats for Direct3D11.
  Although it's supported in CUDA mode, it's not a hardware friendly
  memory layout and it will waste GPU memory since UV planes
  will have large padding due to the memory layout requirement of NVENC.
* GL support is dropped: Similar to the RGBA case,
  GL support in encoder would be suboptimal if GL input is
  used by multiple encoders, because each encoder will copy GL memory
  into CUDA memory.
  Upstream cudaupload element can be used for GL <-> CUDA
  interop instead.
* No more pre-allocation of encoder input surfaces. New implementation
  will use input CUDA memory without copy (zero-copy) or
  will copy into a NVENC's input buffer struct in case of
  system memory input.

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

2 years agoqt: Add touch event support
Vivienne Watermeier [Wed, 23 Feb 2022 11:53:04 +0000 (12:53 +0100)]
qt: Add touch event support

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

2 years agogtk: Add touch event support
Vivienne Watermeier [Mon, 21 Feb 2022 19:16:06 +0000 (20:16 +0100)]
gtk: Add touch event support

Add a handler for touch events to gtkbasewidget.

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

2 years agowpevideosrc: Add touch event support
Vivienne Watermeier [Thu, 10 Feb 2022 09:21:01 +0000 (10:21 +0100)]
wpevideosrc: Add touch event support

Dispatches a list of active touch events to the wpe view on each
received TOUCH_FRAME event. Touch inputs currently only move the cursor,
since wpe doesn't seem to support clicking/scrolling or zooming with
touch input.

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

2 years agoxvimagesink: Add touch event support
Vivienne Watermeier [Tue, 22 Mar 2022 20:13:31 +0000 (21:13 +0100)]
xvimagesink: Add touch event support

Send touch events for XI_TouchBegin, XI_TouchEnd, and XI_TouchUpdate
events, grouping events with identical timestamps into one TOUCH_FRAME.

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

2 years agoximagesink: Add touch event support
Vivienne Watermeier [Thu, 3 Feb 2022 14:01:46 +0000 (15:01 +0100)]
ximagesink: Add touch event support

Send touch events for XI_TouchBegin, XI_TouchEnd, and XI_TouchUpdate
events, grouping events with identical timestamps into one TOUCH_FRAME.

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

2 years agonavigationtest: Display touchscreen events, log all events
Vivienne Watermeier [Wed, 2 Feb 2022 14:46:57 +0000 (15:46 +0100)]
navigationtest: Display touchscreen events, log all events

Represents touchscreen events as a trail of black squares, one for each
reported position. Additionally, this adds the `display-mouse` and
`display-touch` properties to toggle visibility of mouse/touchscreen
events, since touchscreens often emulate mouse events, as well as
logging for all received navigation events.

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

2 years agonavigation: Add API for touchscreen events
Vivienne Watermeier [Mon, 31 Jan 2022 19:25:23 +0000 (20:25 +0100)]
navigation: Add API for touchscreen events

Add 5 new navigation event types for touchscreen events, with the same
naming and meaning as in libinput - touch-down, touch-motion, touch-up,
touch-frame and touch-cancel - as well as constructors and parse
functions for them.

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

2 years agoall: Use new navigation interface and API
Vivienne Watermeier [Mon, 14 Feb 2022 15:08:23 +0000 (16:08 +0100)]
all: Use new navigation interface and API

Use and implement the new navigation interface in all relevant sink elements,
and use API functions everywhere instead of directy accessing the event structure.

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

2 years agonavigation: Add coordinate helper functions
Vivienne Watermeier [Mon, 14 Feb 2022 13:22:29 +0000 (14:22 +0100)]
navigation: Add coordinate helper functions

Add a function to get x/y coordinates from suitable navigation events,
and one to create a copy with given coordinate values.

For e.g. translating event coordinates, this avoids having to either
switch on the event type to select the right parse function, or
having to rely on implementation details of the underlying event
structure.

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

2 years agonavigation: Improve interface to avoid exposing implementation details
Vivienne Watermeier [Mon, 14 Feb 2022 13:06:12 +0000 (14:06 +0100)]
navigation: Improve interface to avoid exposing implementation details

This deprecates the current send_event interface, and the wrapper
functions based on it, replacing it with a send_event_simple interface and
wrapper function. Together with the new event constructors, this avoids
implementations having to directly access the underlying structure.

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

2 years agomsdkenc: add macro definitions to avoid the gst-inspect error
Tong Wu [Tue, 22 Mar 2022 02:37:59 +0000 (10:37 +0800)]
msdkenc: add macro definitions to avoid the gst-inspect error

Since the strings are empty for GST_MSDK_CAPS_MAKE_WITH_DMABUF_FEATURE
and GST_MSDK_CAPS_MAKE_WITH_VA_FEATURE, when excuting
gst-inspect-1.0.exe msdkh265enc, there will be convert static caps error
because of the extra semicolon between two empty strings. Now macro
definitions are added to avoid this issue.

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

2 years agowavparse: handle query in any parse state
Stéphane Cerveau [Fri, 18 Mar 2022 14:20:49 +0000 (15:20 +0100)]
wavparse: handle query in any parse state

In order to create the stream_id, we need to
pass the query to the default query handler.

If the parse state is different from GST_WAVPARSE_DATA
the query should be passed to the default query
handler.

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

2 years agoflvmux: Clean up aggregate's control flow
Jan Alexander Steffens (heftig) [Sun, 13 Sep 2020 00:17:59 +0000 (02:17 +0200)]
flvmux: Clean up aggregate's control flow

This unifies exits to go through a single out label. It mostly
simplifies how EOS is handled.

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

2 years agomsdkdec: Check width and height of mfxVideoParam before allocation
Mengkejiergeli Ba [Wed, 26 Jan 2022 06:55:51 +0000 (14:55 +0800)]
msdkdec: Check width and height of mfxVideoParam before allocation

DecodeHeader must be called to fill the mfxVideoParam before allocation,
and thus the check for width and height in mfxVideoParam is necessary.

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

2 years agodoc: Update cache after NV12_8L128 addition
Nicolas Dufresne [Fri, 18 Mar 2022 20:34:38 +0000 (16:34 -0400)]
doc: Update cache after NV12_8L128 addition

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

2 years agov4l2: Add NV12_8L128 and NV12_10BE_8L128
Ming Qian [Tue, 19 Oct 2021 06:41:04 +0000 (14:41 +0800)]
v4l2: Add NV12_8L128 and NV12_10BE_8L128

These formats are used by i.MX 8QXP/8QM VPU.

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

2 years agovideo: Add support for linear 8x128 NV12 tiles and 10bit BE tiles
Ming Qian [Thu, 12 Aug 2021 03:00:11 +0000 (11:00 +0800)]
video: Add support for linear 8x128 NV12 tiles and 10bit BE tiles

This adds linear 8x128 NV12 based tiles and NV12 10bit big endian tiles.
These formats are used by i.MX 8QXP/8QM VPU and exposed in V4L2.

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

2 years agov4l2codecs: Fix memory leak
Benjamin Gaignard [Mon, 21 Mar 2022 12:01:03 +0000 (13:01 +0100)]
v4l2codecs: Fix memory leak

Free pending_requests array when releasing decoder to avoid memory leak

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

2 years agoav1decoder: Sync duplicate_picture with VP9 one
Daniel Almeida [Wed, 2 Feb 2022 13:05:16 +0000 (10:05 -0300)]
av1decoder: Sync duplicate_picture with VP9 one

Pass the current frame to the duplicate_picture callback. This makes it easier
to set the frame's output_buffer if we already have one available. Also
documented that unlike VP9, it is not optional to implement this as the
picture will populate the DPB if it is a key-frame. To ensure this, remove the
default implementation.

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

2 years agovp9decoder: Copy system_frame_number in duplicate_picture
Nicolas Dufresne [Fri, 18 Mar 2022 19:59:21 +0000 (15:59 -0400)]
vp9decoder: Copy system_frame_number in duplicate_picture

Just like AV1, copy the system_frame_number from the original picture to make
it clear they reference the same data.

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

2 years agocdoecs: av1: Copy system_frame_number in duplicate_picture
Nicolas Dufresne [Wed, 9 Mar 2022 21:35:56 +0000 (16:35 -0500)]
cdoecs: av1: Copy system_frame_number in duplicate_picture

The system_frame_number is notably used by V4L2 decoder as a unique
indentifier for the frame that was decoded. This value is used to tell driver
which frame to reference, as V4L2 does not have an efficient mechanism to
otherwise pass back the frames.

For this reason, and because it is more ligical, copy the original
system_frame_number into the duplicate picture instead of using the current
frame.

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

2 years agomeson: va: Define GST_USE_UNSTABLE_API
Seungha Yang [Mon, 21 Mar 2022 13:03:53 +0000 (22:03 +0900)]
meson: va: Define GST_USE_UNSTABLE_API

Remove extra_c_args which is not defined in this meson file at all,
and define GST_USE_UNSTABLE_API to avoid build warnings

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

2 years agortpmanager/rtx: implement initial support for reading/writing rid extensions
Matthew Waters [Thu, 9 Sep 2021 13:43:33 +0000 (23:43 +1000)]
rtpmanager/rtx: implement initial support for reading/writing rid extensions

Two RTP Header extensions are very relevant for rtprtxsend/receive.
1. "urn:ietf:params:rtp-hdrext:sdes:rtp-stream-id": will always be removed
2. "urn:ietf:params:rtp-hdrext:sdes:repaired-rtp-stream-id": will be written
    instead of the "rtp-stream-id" header extension.

Currently it's only a simple replacement of one header extension for
another however a future change would only add the relevant extension
based on some heuristics (like, video frames only on one of the rtp key
frame buffers, or only until the rtx ssrc has been validated by the peer)
in order to reduce the required bandwidth.

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

2 years agotest: add tests for sdes-based RTP header extensions
Matthew Waters [Wed, 25 Aug 2021 06:59:40 +0000 (16:59 +1000)]
test: add tests for sdes-based RTP header extensions

mid, stream id and repaired stream id.

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

2 years agortpmanager: add support for RFC8852 (rid) RTP header extensions
Matthew Waters [Wed, 25 Aug 2021 06:58:16 +0000 (16:58 +1000)]
rtpmanager: add support for RFC8852 (rid) RTP header extensions

Both for regular RID and for adding on a repaired (RTX) etc stream.

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

2 years agortpmanager: add support for writing RFC8843 (BUNDLE mid) RTP header extension
Matthew Waters [Wed, 25 Aug 2021 06:38:44 +0000 (16:38 +1000)]
rtpmanager: add support for writing RFC8843 (BUNDLE mid) RTP header extension

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

2 years agocodecs: av1: Fix state when we show existing keyframe
Nicolas Dufresne [Wed, 16 Mar 2022 17:17:21 +0000 (13:17 -0400)]
codecs: av1: Fix state when we show existing keyframe

Showing existing keyframe have special meaning in AV1. All the references
frame will be refreshed with the original keyframe information. The refresh
process (7.20) is implemented by saving data from the frame_header into the
state. To fix this special case, load all the relevant information into the
frame_header.

As there is nothing happening in between this and the loading of the key-frame
into the state, this patch also remove the separate API function, using it
internally instead.

Fixes #1090

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

2 years agovideocrop: Add support for v210
Sebastian Dröge [Fri, 18 Mar 2022 17:33:00 +0000 (19:33 +0200)]
videocrop: Add support for v210

Like UYVY and similar formats this is rounding down to the start of the
previous macro-pixel to not mix up the different components.

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

2 years agovideocrop: Use GST_ROUND_DOWN_2 instead of re-defining a local version
Sebastian Dröge [Fri, 18 Mar 2022 17:06:05 +0000 (19:06 +0200)]
videocrop: Use GST_ROUND_DOWN_2 instead of re-defining a local version

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

2 years agovideocrop: Rename PACKED_COMPLEX to PACKED_YVYU
Sebastian Dröge [Fri, 18 Mar 2022 17:03:57 +0000 (19:03 +0200)]
videocrop: Rename PACKED_COMPLEX to PACKED_YVYU

It's not handling any kind of complex packed format, only formats that
are like YVYU.

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

2 years agod3d11: Fix some typos
Jakub Adam [Fri, 18 Mar 2022 12:04:59 +0000 (13:04 +0100)]
d3d11: Fix some typos

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

2 years agovalidate: Totally hide media descriptor node types from the API
Thibault Saunier [Fri, 18 Mar 2022 12:07:48 +0000 (09:07 -0300)]
validate: Totally hide media descriptor node types from the API

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

2 years agomeson: Fix warning about build_root() and source_root()
Nirbheek Chauhan [Fri, 18 Mar 2022 08:13:00 +0000 (13:43 +0530)]
meson: Fix warning about build_root() and source_root()

```
../meson.build:384: WARNING: Project targeting '>= 0.60.0' but tried to use feature deprecated since '0.56.0': meson.build_root. use meson.project_build_root() or meson.global_build_root() instead.
../meson.build:385: WARNING: Project targeting '>= 0.60.0' but tried to use feature deprecated since '0.56.0': meson.source_root. use meson.project_source_root() or meson.global_source_root() instead.
...
WARNING: Deprecated features used:
 * 0.56.0: {'meson.source_root', 'meson.build_root'}
 ```

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