Commit graph

5740 commits

Author SHA1 Message Date
Víctor Manuel Jáquez Leal bf7a01f3fd vkvideoutils: add video capabilities structure
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4850>
2023-11-20 13:32:19 +00:00
Víctor Manuel Jáquez Leal 8023e3c19a vkvideoutils: add gst_vulkan_video_profile_is_equal()
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4850>
2023-11-20 13:32:19 +00:00
Víctor Manuel Jáquez Leal 13d78652b7 vkvideoutils: add gst_vulkan_video_profile_is_valid()
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4850>
2023-11-20 13:32:19 +00:00
Víctor Manuel Jáquez Leal f896e2a347 vkvideoutils: add VkVideoDecodeUsageInfoKHR in profile
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4850>
2023-11-20 13:32:19 +00:00
Víctor Manuel Jáquez Leal fd1b1332b7 vkvideoutils: if unknown codec nullify pNext
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4850>
2023-11-20 13:32:19 +00:00
Víctor Manuel Jáquez Leal d5036e4429 vkvideoutils: mark as private members of profile structure
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4850>
2023-11-20 13:32:19 +00:00
Víctor Manuel Jáquez Leal e3054056ff vkimagebufferpool: set image's number of layers
Handle the image's number of layers as configuration so it can be set by the
user, still isn't exposed as function since it's very niche.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4850>
2023-11-20 13:32:19 +00:00
Stéphane Cerveau d52d50570e vkmemory: avoid the property flag check
During the video session memory allocation, the property flags can
be different from the expected ones, so do not expect all the
property flags and test it with G_MAXUINT32

It's failing with driver 525.47.26 and NVidia HW NVIDIA GeForce
RTX 3050 and 2060

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4850>
2023-11-20 13:32:19 +00:00
Seungha Yang e235599fe9 d3d11: Update plugin doc cache
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5691>
2023-11-20 20:41:07 +09:00
Seungha Yang 522d883fc3 d3d11: Add support for Y210 and Y212 formats
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5691>
2023-11-20 20:29:13 +09:00
Seungha Yang 0ad1c07b20 d3d11testsrc: Bind UAV if needed
YUV packed formats require UAV

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5691>
2023-11-20 20:29:13 +09:00
Seungha Yang ca14eeeeaa d3d11convert: Add support for YUY2 and Y410 output
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5691>
2023-11-20 20:29:13 +09:00
Seungha Yang 2afa0fe7d0 d3d11converter: Port to converter helper
... add support YUY2 and Y410 output

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5691>
2023-11-20 20:29:13 +09:00
Seungha Yang c57fe82a93 d3d11: Implement helper object for converter
This object will upload system memory to GPU and preprocess
texture using compute shader or software converter if needed

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5691>
2023-11-20 20:29:13 +09:00
Jordan Yelloz 66f51f642f bad: Added W3C Media Source Extensions library
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2992>
2023-11-19 13:48:43 +00:00
Nicolas Dufresne bac3de1d83 valgrind: Supress racy cancellable source leak
Creating a socket source, creates a cancellable source internally. This
mechanism is racy and in order to workaround the race, the final unref
can be delayed. Unfortunatly, it seams that this is randomly leaked.
This affects users of glib 2.65 and up. Add a suppression on our side
in order to avoid this leak showing up randomly in our CI.

See https://gitlab.gnome.org/GNOME/glib/-/merge_requests/1400 for more
about the glib implementation detail. And follow this link for an
example of failing CI pipeline:
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/jobs/51694889

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5688>
2023-11-17 15:21:48 -05:00
Thibault Saunier 2f7d402f7b validate: utils: Plug some leaks
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5636>
2023-11-17 15:57:46 +00:00
Thibault Saunier ef62696505 fakevideodec: Add some tests
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5636>
2023-11-17 15:57:46 +00:00
Thibault Saunier 47dbd03604 validate: scenario: Add a 'fill-mode' to the appsrc-push action type
So the user doesn't need a file

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5636>
2023-11-17 15:57:46 +00:00
Julien Isorce 94d74c8900 debug: add new element fakevideodec
The fake video decoder ignores input bitstream except
to enforce caps restrictions. It reads video width,
height and framerate from caps. Then it just pushes
video frames without doing any decoding.

The fake video decoder just draws a snake moving from
left to right in the middle of the frame. This is a
light weight drawing while it still provides an idea
about how smooth is the rendering.

The fake video decoder inherits from GstVideoDecoder.
It is useful to measure how smooth will be the whole
rendering pipeline if you had the most efficient video
decoder. Also useful to bisect issues for example when
suspecting issues in a specific video decoder.

Handles mpeg2, mpeg4, h263, h264, theora, vp8, wmv3, msmpeg,
flash-video, vp6, vp9, wmv1, wmv2, divx but more can be
added if needed.

For now it can only output RGBA, RGBx, BGRA, BGRx.

Its rank is 0 (none) but I added a property to change it so
that it can be selected by decodebin.

gst-launch-1.0 fakevideodec rank=512 \
  playbin uri=http://clips.vorwaerts-gmbh.de/big_buck_bunny.mp4

http://bugzilla.gnome.org/show_bug.cgi?id=723778

Closes #679

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5636>
2023-11-17 15:57:46 +00:00
Robert Mader 414512d922 glcontext/egl: Prefer GLES2 over GL/GL3 by default
From a multimedia perspective GLES >= 2 has the big advantage of
supporting external textures (`OES_EGL_image_external` /
`OES_EGL_image_external_essl3`), allowing various YUV formats to be
imported directly by drivers.

It appears unlikely by now that the extension will ever be ported to
GL with Vulkan becoming more popular, leaving GL without an "official"
way to import YUV formats.

Further more, for Gst internal purposes it's likely that GLES2 works
equally well if not better on most drivers these days, especially on
embedded devices.

Thus switch the default for EGL context creation to GLES2. This won't
affect apps that create their own context, but `gst-launch-1.0` etc.,
which are often used for testing so people don't have to pass
`GST_GL_API=gles2`.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5509>
2023-11-17 15:02:50 +00:00
Robin Gustavsson 38a8411bdf rtpklvdepay: Recover after invalid fragmented KLV unit
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4816>
2023-11-17 09:01:10 +00:00
Nicolas Dufresne e523dd9f08 allocators: shm: Remove future write sealing
By sealing for future writes, we broke Wayland SHM support. It seems like the
wayland library maps the SHM in read/write mode. This is visible through no
display and an error message like this:

  wl_shm@7: error 2: failed mmap fd 43: Operation not permitted

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5684>
2023-11-17 08:17:05 +00:00
Hosang Lee 2afe7cb97e glstereomix: Fix typo
Fix typo in example. vid -> video

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5685>
2023-11-17 04:42:32 +00:00
U. Artie Eoff c5e99ce6db vaapi: add device env to plugin dependencies
In a multi-gpu system, each device may support different
features.

Add GST_VAAPI_DRM_DEVICE to plugin dependencies to ensure
registered features are re-evaluated according to user
specified device.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5675>
2023-11-17 03:27:45 +00:00
Alexander Slobodeniuk 263b08bc53 doc/pipeline-manipulation: mention "insertbin" and "switchbin"
Using one of these elements might save a lot of struggle hours
to the user, because they actually target the case.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5514>
2023-11-17 01:09:49 +01:00
Alexander Slobodeniuk 2922c6182d insertbin/doc: add "Since" markers to pass CI
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5514>
2023-11-17 01:09:49 +01:00
Alexander Slobodeniuk 709913b1d2 insertbin: make it available in the registry
so it could also be used from the gst-parse-launch

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5514>
2023-11-16 21:36:32 +01:00
Seungha Yang d2c9200828 avviddec: Unlock stream lock while waiting for decoded frame
FFmpeg might request buffer from other threads, it will result
in deadlock

Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/2558
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5681>
2023-11-16 18:02:30 +00:00
Robert Mader de92a6c7f2 camerabin: Fix source updates with user filters
Take the case into account when user filters have been set before the
source gets updated.

Note that the further linking of the filters, if present, happens below
in the `gst_camera_bin_check_and_replace_filter()` calls.

The audio filter is still affected by the same issue but left out for
now.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5527>
2023-11-16 17:26:03 +00:00
Sebastian Dröge db77deef00 rtpjitterbuffer: Add new "rfc7273-reference-timestamp-meta-only" property
If this property is enabled then the jitterbuffer will do the normal PTS
calculations according to the configured mode instead of making use of
the RFC7273 media clock.

The timestamp calculated from the RFC7273 media clock will only be
stored in the reference timestamp meta, if addition of that meta is enabled.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5512>
2023-11-16 15:23:29 +00:00
Sebastian Dröge eae3ef7461 rtpjitterbuffer: Add new rfc7273-use-system-clock property
When this property is used, it is assumed that the system clock is
synced close enough to the media clock used by an RFC7273 stream.

As long as both clocks are at most a few seconds from each other this
will give the correct results and avoids having to create an actual
network clock that has to sync first.

If the system clock is actually synchronized to the media clock then
everything will behave exactly the same, otherwise the reference
timestamp meta will be correct but the buffer timestamps will be off by
the difference between the two clocks.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5512>
2023-11-16 15:23:29 +00:00
Sebastian Dröge 2956ba48fc rtpjitterbuffer: Improve handling of media clocks
Do more checks for clock equality than just checking pointers. The same
NTP/PTP clock might be used as pipeline clock but a new instance, so
instead also check what clock they are synced to.

Also handling setting / resetting of the media clock and pipeline clock
correctly by resetting the media clock's state accordingly.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5512>
2023-11-16 15:23:29 +00:00
Sebastian Dröge ba5684d0d7 ptp: Add ttl configuration to gst_ptp_init_full()
This allows configuring the TTL that is used for multicast packets sent
out on the sockets, and is defaulting to 1 as before. The default might
change at some point.

In some networks multiple hops are needed to reach the PTP clock and
this allows to configure GStreamer in a way that works in such networks.

At a later time, per-domain or per-interface TTL configurations might be
added when needed.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5649>
2023-11-16 12:26:02 +00:00
Sebastian Dröge 12159cb294 ptp: Add new gst_ptp_init_full()
This takes a free-form GstStructure as parameter that allows to easily
extend it with new configuration at a later time without having to add
new API.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5649>
2023-11-16 12:26:02 +00:00
Philippe Normand d6c425fc58 ges: Expose FrameCompositionMeta in public API
Knowing the positioning and size of each frame in the composition can help
applications optimize their rendering pipeline.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5652>
2023-11-16 11:45:40 +00:00
Seungha Yang 0afeacce92 d3d11screencapturesrc: Fix wrong color with HDR enabled
Even if IDXGIOutput6 says current display colorspace is HDR,
captured texture via IDXGIOutputDuplication::AcquireNextFrame()
is converted frame by OS unless we use IDXGIOutput5::DuplicateOutput1()
with DXGI_FORMAT_R16G16B16A16_FLOAT format, in order for captured
frame to be scRGB color space. Then application should perform
tonemap operation based on reported display white level, color primaries, etc.

Since we don't have any tonemapping implementation, ignores colorimetry
reported by IDXGIOutput6.

Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3128
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5671>
2023-11-16 19:00:24 +09:00
Daniel Moberg 8a89f4eba7 gstpad: Recheck pads when linking after temporary unlock
This commit makes sure that pads are valid for linking
after the pads has been temporarily unlocked in the linking process.
Not doing this opens up for a race condition where
pads potentially can be linked twice.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5670>
2023-11-16 08:30:14 +00:00
Thibault Saunier a075264215 validate: scenario: Avoid reporting issue with SCENARIO_LOCK taken
This might lead to deadlock and is not needed here

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5666>
2023-11-15 19:07:36 +00:00
Thibault Saunier a56abe2c9d validate: launcher: Lower some 'coredumpctl' info messages
Those are verbose and are not really useful in our context

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5666>
2023-11-15 19:07:36 +00:00
Thibault Saunier e251522805 validate: scenario: Add a "select-streams" action type
This is a "non-blocking" action type which will send the `select-streams`
event when a `GST_STREAM_COLLECTION` message is received on the bus.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5666>
2023-11-15 19:07:36 +00:00
Thibault Saunier d81fe1352c validate: ssim: Minor debug message enhancements
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5666>
2023-11-15 19:07:36 +00:00
Thibault Saunier ad68ce7f64 validate: launcher: Make the output markdown file more readable
Without ansi color codes and marking logs as such

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5666>
2023-11-15 19:07:36 +00:00
Thibault Saunier c530c94239 validate: launcher: Keep gst debug logs in main log fails in debug mode
It makes reading the logs much simpler

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5666>
2023-11-15 19:07:36 +00:00
Thibault Saunier 89434a077c validate: launcher: Add a way to specify the source to use for precise seeking tests
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5666>
2023-11-15 19:07:36 +00:00
Thibault Saunier ca584da58d validate: scenario: Add a way to wait for a property to reach a specified value
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5666>
2023-11-15 19:07:36 +00:00
Thibault Saunier 158f469de6 validate: scenario: Add a way to accept suposdely invalid position reporting
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5666>
2023-11-15 19:07:36 +00:00
Sebastian Dröge 6b22f53fa9 player: Without dispatcher emit signals directly instead of via the default main context
This is how it was documented and how it worked before the port to GstPlay.

Without this, applications expecting signals to be emitted directly
without anything running the main context will simply not receive any
signals.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5672>
2023-11-15 17:16:36 +00:00
Seungha Yang cb3c1390f2 d3d11: Avoid ID3D11DeviceContext::Map if possible
Allocate resource with initial date instead of calling Map/Unmap
after allocation

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5660>
2023-11-15 23:38:59 +09:00
Seungha Yang ac11ccd4ff dwrite: Protect entire draw operation with D3D11 lock
d2d runtime seems to execute pending GPU command list
when DXGI ID2D1RenderTarget is being released, and it will invoke
d3d11 immediate context APIs. Should protect all rendering operations
and DXGI resources with lock.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5659>
2023-11-15 19:25:46 +09:00
Piotr Brzeziński 4037334143 qtdemux: Ignore raw audio streams when adjusting seek
Because we treat raw audio chunks/samples as keyframes, they were interfering
with seek time adjustment.
Became apparent when the accompanying video stream was I-frame only,
for example ProRes.
Since raw audio streams can be seeked freely, it's fine to just ignore them here,
giving priority to the real keyframes in the video stream.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4946>
2023-11-15 07:55:27 +00:00
Mengkejiergeli Ba cef1f179c6 msdk: Add device env in plugin dependencies
Add env vars GST_MSDK_DRM_DEVICE in plugin_add_dependencies to register
msdk plugins according to user's choice in a multi-gpu platform.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5615>
2023-11-15 02:34:27 +00:00
Thibault Saunier 23c5025619 ges: Include ges-discoverer-manager.h in ges.h
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5665>
2023-11-14 22:01:04 +00:00
Thibault Saunier a2bb04c899 discoverer: Fix accumulating discoverer info when loading from cache
With the previous accumualator loading stopped after the first handler,
even if it return NULL which is unexpected, instead we want to use the
first non-value returned by handlers.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5665>
2023-11-14 22:01:04 +00:00
Michael Grzeschik 23a4b72631 codecparsers: h264bitwriter: Fix trace typo
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5661>
2023-11-14 14:41:37 -05:00
Seungha Yang 75560329c1 cea608mux: Fix buffer leak
Release buffer after use

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5648>
2023-11-14 11:14:26 +00:00
Dongyun Seo 8db184085a dcaparse: keep upstream buffer meta
Some audio decoders cannot decode DTS stream if there is no
valid timestamp. So, keep upstream buffer meta.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5655>
2023-11-14 16:51:44 +09:00
Olivier Crête 7104c867c0 webrtcsdp: Don't require fingerprint in inactive media
Inactive m-lines don't need a fingerprint as they may not
have a connection.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1118>
2023-11-13 20:51:31 +00:00
Olivier Crête 9eddf844f0 webrtcsdp: Remove comparison between media and session fingerprint
The code seems to validate that the media-level fingerprint matches
the fingerprint of the previous media or of the whole session. There
is no such requirement in any RFC I found. The session-session one
is just meant to act as a fallback when there is no media-level
fingerprint.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1118>
2023-11-13 20:51:31 +00:00
qian hu b8455ae989 video: dma-drm: add color format mappping about RGB and BGR
add mapping relationship between GST and DRM about RGB888/BGR888

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5641>
2023-11-13 17:44:56 +00:00
Stéphane Cerveau fdc3db68cd codecparsers: introduce h265 level enum
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5644>
2023-11-13 16:37:46 +00:00
Benjamin Gaignard 8cd8eeff20 codec2json: Add h2652json element
This element convert H.265 frame parameters into human readable json data.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3865>
2023-11-13 14:09:59 +00:00
Benjamin Gaignard 3a7fec4ea1 codec2json: Add h2642json element
This element convert H.264 frame header into human readable
json data.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3865>
2023-11-13 14:09:59 +00:00
Philippe Normand 99fa06e73f play: Improve documentation header
If the application relies on GstPlaySignalAdapter, no special clean-up is
required.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5643>
2023-11-12 11:07:37 +00:00
HuQian 050e7f4831 waylandsink: fix incorrect RGB and BGR mapping about GST DRM and WL_SHM
This commit corrects the mapping relationship between RGB and BGR in GST and DRM.
The previous mapping was incorrect, causing potential color mismatches in the output.

The changes are as follows:

  {WL_SHM_FORMAT_RGB888, DRM_FORMAT_RGB888, GST_VIDEO_FORMAT_BGR},
  {WL_SHM_FORMAT_BGR888, DRM_FORMAT_BGR888, GST_VIDEO_FORMAT_RGB},

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5620>
2023-11-11 14:41:18 +00:00
Jordan Petridis e436f87ea2 launcher: Fix ambigious python strings
```
gst-devtools/validate/launcher/baseclasses.py:2399: SyntaxWarning: invalid escape sequence '\.'
  if re.findall("%s\..*\.%s$" % (re.escape(mfile_bname), self.FILE_EXTENSION), f):
gst-devtools/validate/launcher/apps/gstvalidate.py:1354: SyntaxWarning: invalid escape sequence '\.'
  ("file\.transcode.*mxf",
```

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5541>
2023-11-11 12:47:12 +00:00
Jordan Petridis bbdf6d4653 meson: Workaround python 3.12 warning
When we are building againt python 3.12, ignore redundant-decls warning
that will come from the python headers.

```
/usr/include/python3.12/longobject.h:10:26: warning: redundant redeclaration of ‘PyLong_Type’ [-Wredundant-decls]
   10 | PyAPI_DATA(PyTypeObject) PyLong_Type;
      |                          ^~~~~~~~~~~
```

https://github.com/python/cpython/issues/106560

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5541>
2023-11-11 12:47:11 +00:00
Sebastian Dröge a238caebbb play: Automatically flush the bus when disposing the signal adapter
See https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3107

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5642>
2023-11-11 14:11:30 +02:00
Philippe Normand 66373721d5 gstplay: Add a minimal documentation header
Also mentioning the need to set the bus to flushing state before disposing the
player in order to avoid reference cycles.

Fixes #3107

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5631>
2023-11-11 10:48:27 +00:00
Daniel Morin 1fc3d43952 audiodecoder: propagate resync flag
- propagate resync flag on last input frame to output frame
- resync TS when RESYNC flag is set

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5529>
2023-11-10 21:45:13 +00:00
Olivier Crête c2a357c867 rtpopusdepay: set resync flag
- Set re-sync flag on output buffer when rtp had the marker flag set.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5529>
2023-11-10 21:45:13 +00:00
Víctor Manuel Jáquez Leal 43ce583460 vulkan/operation: wait for pending objects at reset
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5591>
2023-11-10 16:36:44 +01:00
Víctor Manuel Jáquez Leal 0296c8a53a vulkan/operation: get query only if a operation is submitted
To avoid a validation error if get query is performed before.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5591>
2023-11-10 16:36:44 +01:00
Víctor Manuel Jáquez Leal 3464710bf0 vulkan/operation: remove stored fences at the end
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5591>
2023-11-10 16:36:44 +01:00
Víctor Manuel Jáquez Leal 405ae91ed7 vulkan/operation: don't fail if extension isn't available
gst_vulkan_operation_add_dependency_frame() is a noop if the required extensions
aren't available.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5591>
2023-11-10 16:36:44 +01:00
Sebastian Dröge 274551d450 mxfdemux: Store GstMXFDemuxEssenceTrack in their own fixed allocation
Previously they were stored inline inside a GArray, but as references to
the tracks were stored in various other places although the array could
still be updated (and reallocated!), this could lead to dangling
references in various places.

Instead now store them in a GPtrArray in their own allocation so each
track's memory position stays fixed.

Fixes ZDI-CAN-22299

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

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5635>
2023-11-10 14:38:40 +00:00
Benjamin Gaignard 1db83d3f74 codecparsers: av1: Clip max tile rows and cols values
Clip tile rows and cols to 64 as describe in AV1 specification.

Fixes ZDI-CAN-22226 / CVE-2023-44429

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

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5634>
2023-11-10 13:45:43 +00:00
Philippe Normand 18fcd14fb8 streamcollection: Fixup doc blurbs
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5605>
2023-11-10 00:28:42 +00:00
Mathieu Duponchelle 39efd788a8 timecodestamper: set drop-frame property default to TRUE
After talking with Vivia on IRC, she does not remember why the default
was FALSE and it is in my opinion preferable to stick to whatever
representation best represents time for a given framerate as a default
behavior.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5628>
2023-11-09 21:05:02 +00:00
Víctor Manuel Jáquez Leal 9f5b2c4e25 va: use GstVideoInfoDmaDrm when importing buffers
In the case of encoders and filters when importing a DMABuf, use
GstVideoInfoDmaDrm to get the drm fourcc and modifier.

In both cases, instead of keeping the original GstVideoInfoDmaDrm from caps, the
GstVideoInfo part of the structure is converted as canonical one, given the
format from the fourcc. It's kept in the way to handle V4L2 linear DMABufs and
to avoid too many changes in the current code.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5264>
2023-11-09 17:36:06 +00:00
Víctor Manuel Jáquez Leal 7c0227145c vaallocator: use GstVideoInfoDmaDrm for dmabuf setup
Instead of guessing the DRM format and modifier, pass a DRM video info to
gst_va_dmabuf_memories_setup().

Still, it checks for the DRM parameters in DRM info, if they are not available,
as in the case of V4L2 buffers, the part of the video info is used.

This is an API breakage, but since the plugin is still in stage, it's still
allowed.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5264>
2023-11-09 17:36:06 +00:00
Víctor Manuel Jáquez Leal d1210d6dc0 vaallocator: use VADRMPRIMESurfaceDescriptor to create surfaces
To import DMAbufs we used VASurfaceAttribExternalBuffers which works, but it's
not specific for DRM PRIME 2, since it lacks of many metadata. This patch
replaces VASurfaceAttribExternalBuffers with VADRMPRIMESurfaceDescriptor in
va_create_surfaces().

Still, this patch assumes linear modifier only.

The hack for RGB surfaces in I965 driver was pushed down into
va_create_surfaces() to avoid handling both structures.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5264>
2023-11-09 17:36:06 +00:00
Víctor Manuel Jáquez Leal 76115528ac vallocator: remove n_planes argument in dmabuf_memories_setup()
Instead of passing the number of planes to process, take that number from the
passed GstVideoInfo.

This is an API breakage, but since the plugin is still in stage, it's still
allowed.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5264>
2023-11-09 17:36:06 +00:00
Víctor Manuel Jáquez Leal 2d358cb22a vaallocator: fix assumption object size equal fd size
Remove the comment and warning message that object size should be equal to the
file descriptor size.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5264>
2023-11-09 17:36:06 +00:00
Tobias Rapp cd98d12f2e decklink: Fix typo in element documentation
DechLink -> DeckLink

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5625>
2023-11-09 07:53:12 +00:00
Tobias Rapp 7ec3a97a70 decklink: Increase section level of video sink/source element documentation
Should fix auto-generated follow-up sections like "Hierarchy" or
"Factory details" to be listed under the element name in the
table-of-contents of the document, instead of a stand-alone
"Duplex-Mode" section.

Also cleanup some spurious colon suffix after section names.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5625>
2023-11-09 07:53:12 +00:00
Jordan Yelloz b1f3722530 gst-validate: Fixed compatibility with Python 3.12
config.readfp() was removed in python 3.12 and config.read_file() does the same
thing and has been available since Python 3.2

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5624>
2023-11-08 15:50:52 -07:00
Patricia Muscalu bd4a9fde89 rtsp-server: Unprepare media that is in error state
Without this patch a prepared media that entered an error state
remains unprepared.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5621>
2023-11-08 14:39:01 +00:00
Víctor Manuel Jáquez Leal d7b5b54eda vadisplay: only register elements of allowed drivers
Now that nvidia-vaapi-driver appeared and isn't yet supported by GstVA, we've to
add an allowed list of supported drivers.

This patch implements it adding a environment variable to disable this driver
check: GST_VA_ALL_DRIVERS

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5616>
2023-11-08 13:53:26 +00:00
Piotr Brzeziński 49865826b0 basetextoverlay: Fix overlay never rendering again if width reaches 1px
If text width ever reached 1px, for example after resizing the output window, the overlay would stop rendering
and never return again. The 1px condition itself does not seem to make much sense here anyway.

This was a chain of events: width reached 1, so the composition was set to NULL. Then, after resizing the output window,
push_frame() was called but would not attempt to renegotiate because composition is NULL. This caused the width/height
to never be updated again, as that only happens during negotiation, so the overlay was gone for good.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5614>
2023-11-08 11:19:39 +00:00
Vivia Nikolaidou dd00dab5e9 ccutils: Add padding also for ccp data
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5423>
2023-11-08 10:06:45 +00:00
Philippe Normand 1fc2bd8032 adaptivedemux2-stream: Use gst_clear_object when releasing collection
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5606>
2023-11-08 09:16:55 +00:00
Thibault Saunier d159cc624a ges: discoverer-manager: Fix race when freeing unused discoverer
When a new discoverer was created for a thread so discovery could
recurse we could end up removing the wrong discoverer info from the
cache leading to freeing it while it was still discovering URIS, which
lead to the following assertion:

``` bt
Thread 1 (Thread 0x7fcc2e1a5840 (LWP 1855496)):
 #0  __pthread_kill_implementation (threadid=<optimized out>, signo=signo@entry=6, no_tid=no_tid@entry=0) at pthread_kill.c:44
 #1  0x00007fcc2e9d98a3 in __pthread_kill_internal (signo=6, threadid=<optimized out>) at pthread_kill.c:78
 #2  0x00007fcc2e9878ee in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
 #3  0x00007fcc2e96f8ff in __GI_abort () at abort.c:79
 #4  0x00007fcc2ed80056 in g_assertion_message (domain=domain@entry=0x7fcc2f2c19f9 "GES", file=file@entry=0x7fcc2f2dfd68 "../subprojects/gst-editing-services/ges/ges-discoverer-manager.c", line=line@entry=20, func=func@entry=0x7fcc2f2e0030 <__func__.7> "ges_discoverer_data_free", message=message@entry=0x12dab70 "assertion failed: (data->n_uri == 0)") at ../glib/gtestutils.c:3497
 #5  0x00007fcc2ede1d87 in g_assertion_message_expr (domain=domain@entry=0x7fcc2f2c19f9 "GES", file=file@entry=0x7fcc2f2dfd68 "../subprojects/gst-editing-services/ges/ges-discoverer-manager.c", line=line@entry=20, func=func@entry=0x7fcc2f2e0030 <__func__.7> "ges_discoverer_data_free", expr=expr@entry=0x7fcc2f2dfcf1 "data->n_uri == 0") at ../glib/gtestutils.c:3523
 #6  0x00007fcc2f2bd5c5 in ges_discoverer_data_free (data=0x160e430) at ../subprojects/gst-editing-services/ges/ges-discoverer-manager.c:20
 #7  0x00007fcc2ed8509d in g_atomic_rc_box_release_full (clear_func=0x7fcc2f2bd4f0 <ges_discoverer_data_free>, mem_block=0x160e430) at ../glib/garcbox.c:355
 #8  g_atomic_rc_box_release_full (mem_block=0x160e430, clear_func=0x7fcc2f2bd4f0 <ges_discoverer_data_free>) at ../glib/garcbox.c:338
 #9  0x00007fcc2eda6809 in g_hash_table_remove_internal (notify=1, key=0x10448a0, hash_table=0x12e0be0) at ../glib/ghash.c:1776
 #10 g_hash_table_remove (hash_table=0x12e0be0, key=0x10448a0) at ../glib/ghash.c:1804
 #11 0x00007fcc2f2bd95f in cleanup_discoverer_cb (discoverer_data=discoverer_data@entry=0x13e7000) at ../subprojects/gst-editing-services/ges/ges-discoverer-manager.c:379
 #12 0x00007fcc2edbc759 in g_timeout_dispatch (source=0x15a6060, callback=0x7fcc2f2bd910 <cleanup_discoverer_cb>, user_data=0x13e7000) at ../glib/gmain.c:5121
 #13 0x00007fcc2edbbe1c in g_main_dispatch (context=0x1044700) at ../glib/gmain.c:3476
 #14 g_main_context_dispatch_unlocked (context=0x1044700) at ../glib/gmain.c:4284
 #15 0x00007fcc2ee16d78 in g_main_context_iterate_unlocked.isra.0 (context=0x1044700, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/gmain.c:4349
 #16 0x00007fcc2edbd407 in g_main_loop_run (loop=0x12ccbd0) at ../glib/gmain.c:4551
 #17 0x00007fcc2f285791 in ges_uri_clip_asset_request_sync (uri=uri@entry=0x12d7980 "file:///var/home/phil/gstreamer/build/subprojects/gst-integration-testsuites/logs/ges/scenarios/check_seek_on_very_deeply_nested_timeline/nested_timeline_depth6.xges", error=error@entry=0x7fff499015a8) at ../subprojects/gst-editing-services/ges/ges-uri-asset.c:688
 #18 0x00007fcc2f28949b in ges_project_create_asset_sync (project=0x12c1c70, id=id@entry=0x12d7980 "file:///var/home/phil/gstreamer/build/subprojects/gst-integration-testsuites/logs/ges/scenarios/check_seek_on_very_deeply_nested_timeline/nested_timeline_depth6.xges", extractable_type=extractable_type@entry=Python Exception <class 'gdb.error'>: value has been optimized out , error=error@entry=0x7fff499015a8) at ../subprojects/gst-editing-services/ges/ges-project.c:959
 #19 0x00007fcc2f2ba484 in _ges_get_asset_from_timeline (timeline=timeline@entry=0x12bdc80, type=type@entry=Python Exception <class 'gdb.error'>: value has been optimized out , id=id@entry=0x12d7980 "file:///var/home/phil/gstreamer/build/subprojects/gst-integration-testsuites/logs/ges/scenarios/check_seek_on_very_deeply_nested_timeline/nested_timeline_depth6.xges", error=error@entry=0x7fff49901728) at ../subprojects/gst-editing-services/ges/ges-structured-interface.c:540
 #20 0x00007fcc2f2ba9b2 in _ges_add_clip_from_struct (timeline=0x12bdc80, structure=0x157f690, error=0x7fff49901728) at ../subprojects/gst-editing-services/ges/ges-structured-interface.c:697
 #21 0x00007fcc2f2b6a9d in _validate_action_execute (scenario=0x15f7620, action=0x157f500) at ../subprojects/gst-editing-services/ges/ges-validate.c:922
 #22 0x00007fcc2eef5c9c in gst_validate_execute_action (action=0x157f500, action_type=0x13e0500) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2541
 #23 gst_validate_execute_action (action_type=0x13e0500, action=0x157f500) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2507
 #24 0x00007fcc2eef8ce3 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2782
 #25 0x00007fcc2eef9dee in _action_set_done (action=0x157efb0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #26 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x157efb0, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #27 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x157efb0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #28 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #29 0x00007fcc2eef9dee in _action_set_done (action=0x157ea60) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #30 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x157ea60, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #31 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x157ea60) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #32 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #33 0x00007fcc2eef9dee in _action_set_done (action=0x157e510) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #34 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x157e510, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #35 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x157e510) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #36 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #37 0x00007fcc2eef9dee in _action_set_done (action=0x157df10) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #38 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x157df10, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #39 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x157df10) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #40 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #41 0x00007fcc2eef9dee in _action_set_done (action=0x157d9e0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #42 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x157d9e0, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #43 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x157d9e0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #44 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #45 0x00007fcc2eef9dee in _action_set_done (action=0x157d3e0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #46 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x157d3e0, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #47 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x157d3e0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #48 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #49 0x00007fcc2eef9dee in _action_set_done (action=0x157cf70) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #50 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x157cf70, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #51 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x157cf70) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #52 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #53 0x00007fcc2eef9dee in _action_set_done (action=0x157cb00) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #54 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x157cb00, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #55 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x157cb00) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #56 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #57 0x00007fcc2eef9dee in _action_set_done (action=0x157c690) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #58 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x157c690, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #59 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x157c690) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #60 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #61 0x00007fcc2eef9dee in _action_set_done (action=0x157c220) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #62 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x157c220, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #63 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x157c220) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #64 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #65 0x00007fcc2eef9dee in _action_set_done (action=0x15233c0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #66 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x15233c0, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #67 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x15233c0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #68 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #69 0x00007fcc2eef9dee in _action_set_done (action=0x1522f80) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #70 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x1522f80, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #71 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x1522f80) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #72 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #73 0x00007fcc2eef9dee in _action_set_done (action=0x1522ae0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #74 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x1522ae0, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #75 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x1522ae0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #76 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #77 0x00007fcc2eef9dee in _action_set_done (action=0x1522190) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #78 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x1522190, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #79 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x1522190) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #80 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #81 0x00007fcc2eef9dee in _action_set_done (action=0x1520ea0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6368
 #82 0x00007fcc2edbd26d in g_main_context_invoke_full (context=0x1044700, priority=200, function=0x7fcc2eef9ab0 <_action_set_done>, data=0x1520ea0, notify=0x7fcc2eeea5d0 <gst_validate_action_unref>) at ../glib/gmain.c:6533
 #83 0x00007fcc2eef6cf2 in gst_validate_action_set_done (action=0x1520ea0) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:6411
 #84 0x00007fcc2eef9018 in execute_next_action_full (scenario=<optimized out>, message=<optimized out>) at ../subprojects/gst-devtools/validate/gst/validate/gst-validate-scenario.c:2803
 #85 0x00007fcc2edbc759 in g_timeout_dispatch (source=0x14b6340, callback=0x7fcc2eef99c0 <execute_next_action>, user_data=0x15f7620) at ../glib/gmain.c:5121
 #86 0x00007fcc2edbbe1c in g_main_dispatch (context=0x1044700) at ../glib/gmain.c:3476
 #87 g_main_context_dispatch_unlocked (context=0x1044700) at ../glib/gmain.c:4284
 #88 0x00007fcc2ee16d78 in g_main_context_iterate_unlocked.isra.0 (context=context@entry=0x1044700, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/gmain.c:4349
 #89 0x00007fcc2edb9a93 in g_main_context_iteration (context=context@entry=0x1044700, may_block=may_block@entry=1) at ../glib/gmain.c:4414
 #90 0x00007fcc2ec14c3d in g_application_run (application=application@entry=0x1042ab0, argc=argc@entry=4, argv=argv@entry=0x7fff499031e8) at ../gio/gapplication.c:2577
 #91 0x0000000000405dfd in real_main (argv=0x7fff499031e8, argc=4) at ../subprojects/gst-editing-services/tools/ges-launch.c:38
 #92 main (argc=4, argv=0x7fff499031e8) at ../subprojects/gst-editing-services/tools/ges-launch.c:56

```

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5619>
2023-11-08 08:24:15 +00:00
Slava Andrejev 93b4272e6c meson: change Wayland scanner command from "code" to "private-code"
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5593>
2023-11-07 18:40:35 +00:00
Slava Andrejev cad42b0511 meson: add processing of "staging" Wayland protocols
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5593>
2023-11-07 18:40:35 +00:00
Slava Andrejev c48e96fd76 meson: prevent sandbox violation if GStreamer and wayland-protocols are subprojects
Suppose you have a project where GStreamer and wayland-protocols are
pulled in as dependencies via .wrap files. In that case, Meson's setup
step will fail for gst-plugins-bad with the message "Sandbox violation:
Tried to grab file viewporter.xml outside current (sub)project." To
avoid this exception, one should use Meson's `files` and `join_paths`
functions. The suggested solution is identical to how GTK 4 processes
Wayland files.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5593>
2023-11-07 18:40:35 +00:00
Balló György 6f8b9574f2 gstwayland: Don't depend on wayland-protocols
wayland-protocols are needed to build gstwayland, but not for dependent projects.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4724>
2023-11-07 17:52:31 +00:00
Seungha Yang 02bf1dbf1f d3d11window: Fix scale factor setting
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5602>
2023-11-07 11:19:31 +00:00
Seungha Yang 0bcddfc894 d3d11: Enable DirectXMath SIMD
* Enable SIMD except for x86 target
* Use aligned matrix struct
* Remove unnecessary matrix copy operations

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5602>
2023-11-07 11:19:31 +00:00
Piotr Brzeziński 4c5aaa742f gloverlaycompositor: Add GL sync point when uploading overlays
In rare cases - notably on macOS, because of multiple GL contexts - the lack of a sync point was causing overlays
to disappear for a frame after being redrawn, or sometimes not appear at all. This change makes sure that the display
in one GL context will be correctly synchronised with the other GL context where the overlay texture was uploaded.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5610>
2023-11-07 00:32:39 +01:00
Philippe Normand 05ce97c5c1 ges: discoverer-manager: Use appropriate key hash function
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5608>
2023-11-06 14:23:45 +00:00
Thibault Saunier b8a7b2c9e2 ges: discoverer-manager: Support for delayed clean-up of discoverers
The manager keeps track of one discoverer per thread and in large applications
with hundreds of threads this can significantly increase memory pressure. So we
need to periodically clean-up the unused discoverers.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5608>
2023-11-06 14:23:45 +00:00
Philippe Normand 101205d429 ges: timeline: Fix message leaks
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5608>
2023-11-06 14:23:45 +00:00
Thibault Saunier 114ef64465 ges: Expose GESDiscovererManager::source-setup
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5608>
2023-11-06 14:23:45 +00:00
Thibault Saunier 71aa451870 ges: discoverer-manager: Allow recursing discovery
When using deeply nested timelines with the `ges:` protocol the
formatters ends up trying to do discovery from the same thread current
discovery happens, leading to infinite freeze as GstDiscoverer can't run
several discoveries at the same time.

By ensuring that when calling `gst_discoverer_discover_uri_async` no
`GstDiscoverer` is set as "thread discoverer" we know that another
discoverer will be created if discovery recurses, effectively removing
the freeze.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5608>
2023-11-06 14:23:45 +00:00
Vivia Nikolaidou 78bc3d53dd ccutils: Keep upstream padding payload
A payload of 0x80 0x80 means that it's padding. It's not a good idea to
throw this away though, because of the cc_valid field.

According to CEA 10-B section 25.2.1, if cc_valid is zero, the run-in
clock and start bit should not be generated. In practice, this means
that any closed captions will be erased and the end-user TV will show
that captions are not available for this stream. This might have
undesired consequences, e.g. we were just showing a long line of
captions and we disable it before the user has had time to read it, or
you can't enable closed captions during silence/music intervals.

We cannot reliably detect whether there's a currently-silent closed
caption stream or just nothing, but we have this information coming from
upstream, so we can at least not discard it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5508>
2023-11-06 13:44:36 +00:00
Philippe Normand ca18e48882 decodebin3: Tidy-up dispose function
Protect code with mutexes

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5607>
2023-11-06 13:07:54 +00:00
Philippe Normand f0e1b4f415 parsebin: Fix a potential stream collection leak
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5607>
2023-11-06 13:07:54 +00:00
Seungha Yang b12d43bd89 wasapi2device: Ignore activation failed device
Enumerates all devices even if activation error is detected

Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3090
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5599>
2023-11-06 12:28:50 +00:00
Fabian Orccon b3245aff28 gst-inspect: Remove current caps print
At GST_STATE_NULL, all pads are deactivated and have no caps.
It can be observed with `gst-inspect-1.0 -a` that no element
is reaching this removed code.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5604>
2023-11-06 07:21:18 +00:00
Marek Vasut 5d2d602e4a v4l2codecs: Avoid QBUF/DQBUF struct timeval .tv_usec wrap-around at frame 1000000
When decoding stream using hardware V4L2 decoder element, in any of the
currently supported formats, the decoding will fail once frame number
1000000 is reached. The reported error clearly indicates a wrap-around
occured, instead of receiving decoded frame 1000000, frame 0 is received
from the hardware V4L2 decoder driver.

The problem is actually not in the driver itself, but rather in gstreamer,
which uses `struct v4l2_buffer` member `.timestamp` in a special way. The
timestamp of buffers with encoded data added to the SINK (input) queue of
the driver is copied by the driver into matching buffers with decoded data
added to the SOURCE (output) queue of the driver. In fact, the timestamp
is not a timestamp at all, but rather in this special case, only part of
it is used as an incrementing frame counter.

The `.timestamp` is of type `struct timeval`, which is defined in
`sys/time.h` [1]. Only the `tv_usec` member of this structure is used
for the incrementing frame counter. However, suseconds_t tv_usec [2]
may be limited to range [-1, 1000000]:
"
[XSI] The type suseconds_t shall be a signed integer type capable of
      storing values at least in the range [-1, 1000000].
"
Therefore, once frame 1000000 is reached, a rollover occurs and decoding
fails.

Fix this by using both `struct timeval` members, `.tv_sec` and `.tv_usec`
with matching modular arithmetic, this way the failure would occur again
just short of 2^84 frames, which should be plenty.

[1] https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/sys_time.h.html
[2] https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/sys_types.h.html

A test case using stateless hardware h264 decoder, the WARN/ERROR output
in gstreamer log indicates a failure occurred. With this change, that
error no longer occurs and the WARN/ERROR are not present:
```
pc$ gst-launch-1.0 videotestsrc num-buffers=1001001 pattern=6 ! \
                   video/x-raw,width=16,height=16,format=I420 ! \
                   x264enc ! filesink location=/tmp/test.h264

dut$ GST_DEBUG="*:3" gst-launch-1.0 filesrc location=/tmp/test.h264 ! \
                                    h264parse ! v4l2slh264dec ! fakesink
...
0:03:51.393677606 12111     0x370df400 WARN      \
  v4l2codecs-decoder gstv4l2decoder.c:1157:gst_v4l2_request_set_done:<v4l2decoder2> \
  Requested frame 1000000, but driver returned frame 0.
0:03:51.394140597 12111     0x370df400 WARN      \
  v4l2codecs-decoder gstv4l2decoder.c:1157:gst_v4l2_request_set_done:<v4l2decoder2> \
  Requested frame 1000001, but driver returned frame 1.
0:03:51.394425216 12111     0x370df400 WARN      \
  v4l2codecs-decoder gstv4l2decoder.c:1157:gst_v4l2_request_set_done:<v4l2decoder2> \
  Requested frame 1000002, but driver returned frame 2.
0:03:51.394665211 12111     0x370df400 WARN      \
  v4l2codecs-decoder gstv4l2decoder.c:1157:gst_v4l2_request_set_done:<v4l2decoder2> \
  Requested frame 1000003, but driver returned frame 3.
0:03:51.394785833 12111     0x370df400 WARN      \
  v4l2codecs-h264dec gstv4l2codech264dec.c:1059:gst_v4l2_codec_h264_dec_output_picture:<v4l2slh264dec0> \
  error: Failed to decode frame 1000000
ERROR: from element /GstPipeline:pipeline0/v4l2slh264dec:v4l2slh264dec0: Failed to decode frame 1000000
```

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5598>
2023-11-04 15:51:45 +01:00
Philippe Normand 677b6f7148 decodebin3: Dispose decoder in case linking failed
Otherwise it will be leaked and remain forever in the bin when trying the next
decoder candidate.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5551>
2023-11-04 11:02:20 +00:00
Johan Adam Nilsson 808c27b4cc wavparse: fix buffer leak with adtl tag
Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3020
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5595>
2023-11-03 19:38:38 +00:00
Xavier Claessens 47c56e3865 unixfd: Add support for abstract socket
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5328>
2023-11-03 18:22:01 +00:00
Xavier Claessens d44aa71f24 unixfd: Use DMABuf allocator when needed
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5328>
2023-11-03 18:22:01 +00:00
Xavier Claessens 1f928c6c1a unixfd: Update gst_plugins_cache.json
Sponsored-by: Netflix Inc.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5328>
2023-11-03 18:22:01 +00:00
Xavier Claessens f1a1901b8b unixfd: New plugin with unixfdsink and unixfdsrc elements
This pair of elements, inspired from shmsink/shmsrc, send unix file
descriptors (e.g. memfd, dmabuf) from one sink to multiple source
elements in other processes.

The unixfdsink proposes a memfd/shm allocator, which causes for example
videotestsrc to write directly into memories that can be transfered to
other processes without copying.

Sponsored-by: Netflix Inc.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5328>
2023-11-03 18:22:00 +00:00
Xavier Claessens 19832bd3b3 GstShmAllocator: Add documentation
Sponsored-by: Netflix Inc.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5328>
2023-11-03 18:22:00 +00:00
Xavier Claessens 5b4d37d6f2 GstShmAllocator: Respect allocation params
Sponsored-by: Netflix Inc.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5328>
2023-11-03 18:22:00 +00:00
Xavier Claessens f57dabe65c GstShmAllocator: Seal memfd for future write
The GstMemory we created is kept mapped RW, but any future mapping that
uses the fd should be RO.

Sponsored-by: Netflix Inc.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5328>
2023-11-03 18:22:00 +00:00
Xavier Claessens c0ce677dfc GstShmAllocator: Use shm_open() instead of temporary file
There is no guarantee that g_get_user_runtime_dir() is in a tmpfs. Using
an explicit shared memory API seems safer for all POSIX platforms.

Note that Android does not have shm_open() and only added memfd_create()
since API level 30 (Android 11).

Sponsored-by: Netflix Inc.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5328>
2023-11-03 18:22:00 +00:00
Xavier Claessens d59ea1caf0 GstShmAllocator: Use GST_ALLOCATOR_FLAG_NO_COPY flag
Sponsored-by: Netflix Inc.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5328>
2023-11-03 18:22:00 +00:00
Xavier Claessens 7df22b338b GstShmAllocator: New shared memory allocator
This makes Wayland's allocator public. It is generally useful to have a
shared memory allocator that can create memfd on Linux.

Sponsored-by: Netflix Inc.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5328>
2023-11-03 18:22:00 +00:00
Xavier Claessens 24c34cadec GstAllocator: Add GST_ALLOCATOR_FLAG_NO_COPY flag
Detail a bit the intention behind GST_ALLOCATOR_FLAG_CUSTOM_ALLOC, even
if implementation does not currently fully follow that usage. Introduce
a new flag specifically for copying memories using the default system
allocator.

Sponsored-by: Netflix Inc.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5328>
2023-11-03 18:22:00 +00:00
robert e3e8147a74 ximagesrc: fix xnavigation linking issue
Fixes #3083

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5589>
2023-11-03 17:36:58 +00:00
Gwyn Ciesla 2be13c82aa gst-python: Fix API call for Python 3.13
_PyUnicode_AsString() is deprecated and PyUnicode_AsUTF8() should be used
instead. The new function was introduced in Python 3.3 and returns const
since Python 3.7, which is now required.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5587>
2023-11-03 21:02:48 +05:30
Seungha Yang 34d221dad5 wasapi2: Fix build with GST_DISABLE_GST_DEBUG
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5585>
2023-11-03 13:31:03 +00:00
Seungha Yang 8009f5275a mediafoundation: Fix build with GST_DISABLE_GST_DEBUG
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5585>
2023-11-03 13:31:03 +00:00
Seungha Yang c3cef6e923 d3d12: Fix build with GST_DISABLE_GST_DEBUG
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5585>
2023-11-03 13:31:03 +00:00
Seungha Yang bf05cfea45 d3d11: Fix build with GST_DISABLE_GST_DEBUG
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5585>
2023-11-03 13:31:03 +00:00
Seungha Yang 5e147ed3b8 meson: Fix MSVC build with GST_DISABLE_GST_DEBUG
MSVC does not understand Wno-unused

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5585>
2023-11-03 13:31:03 +00:00
He Junyan e7479a8c94 libde265dec: Only decode the main profile
The src caps of the libde265 is now fixed to I420, and so if the
stream is other format, such as 4:4:4 or 10 bits format, the pipeline
will crash because the dowstream element accesses the video buffer as
I420 format.
We now restrain the input caps to "main" profile, which only contains
4:2:0 8 bits stream.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5573>
2023-11-03 12:41:59 +00:00
Philippe Normand 8f18fde21a ges-uri-asset: Fix GESDiscovererManager leaks
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5552>
2023-11-02 18:29:27 +00:00
Sebastian Dröge 2dd65d8715 mpg123audiodec: Update rank from MARGINAL to PRIMARY
This is our primary MP3 decoder after mad got removed.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5590>
2023-11-02 14:17:06 +00:00
Sebastian Dröge ffa30637c4 ptp: Use SO_BINDTOIFINDEX / SO_BINDTODEVICE on Linux
This makes sure we really really really only get packets from the
desired interface as passing a device to IP_ADD_MEMBERSHIP apparently
does not have this effect alone.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5584>
2023-11-02 11:42:44 +00:00
Fabian Orccon f6ffe34ad5 gst-inspect: Do not check for element clock
Clock is only set at GST_PLAYING state, not the case for gst-inspect

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5570>
2023-11-02 10:12:31 +00:00
Sebastian Dröge d6adaccf6d ptp: Check once a second for timeouts
While the minimum timeout duration is 5s, checking only every 5s means
that we would notice this 4.9s too late in the worst case.

Checking once a second reduces this considerably while keeping the
number of wakeups still low.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5520>
2023-11-02 09:11:09 +00:00
Sebastian Dröge 9ba8107ec6 ptp: Only warn if the clock id and interface of a timed out matches the current one
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5520>
2023-11-02 09:11:09 +00:00
Sebastian Dröge bd985ea608 ptp: Only time out SYNCs if we're actually waiting for a FOLLOW_UP
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5520>
2023-11-02 09:11:09 +00:00
Sebastian Dröge c7421c0f16 ptp: Downgrade clocks that don't send FOLLOW_UPs / DELAY_RESPs
This allows to select a different clock if there is one that is
for the same grandmaster clock and has fewer timeouts.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5520>
2023-11-02 09:11:09 +00:00
Sebastian Dröge ea7861a757 ptp: Don't switch domain's master clock if it is equivalent to the previous one
Otherwise it can happen that we regularly switch back and forth between
clocks under certain circumstances for no good reason.

Also remove redundant comparison when comparing the steps removed between two
clocks.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5520>
2023-11-02 09:11:09 +00:00
Kalev Lember cfa1d036a1 openh264: Fail gracefully if openh264 encoder/decoder creation fails
This can happen with the dummy "noopenh264" library that the freedesktop
flatpak runtime ships, and Fedora is planning on shipping as well. In
both cases the dummy implementation gets replaced with the actual
openh264 library that's downloaded directly from Cisco, but just to be
on safe side, this patch makes it careful to check the return values to
avoid crashing if the underlying library hasn't been swapped out yet.

The patch is taken from freedesktop-sdk and was originally written by
Valentin David <valentin.david@codethink.co.uk>.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5581>
2023-11-01 16:31:11 +00:00
Seungha Yang 033f98ad86 d3d11: Set MaxAnisotropy value for the best quality
... and use anisotropic filter without comparison, which is actually
intended one.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5580>
2023-11-01 15:41:08 +00:00
Seungha Yang 0e9fdabb1b d3d11converter: Simplify private struct ctor
Initialize transform matrix using memcpy

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5580>
2023-11-01 15:41:08 +00:00
Seungha Yang e134cd8e09 d3d11device: Store device formats in hash map
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5580>
2023-11-01 15:41:08 +00:00
Seungha Yang ac265bc4f9 d3d11overlaycompositor: Avoid heap allocation per upload
Don't allocate list per upload

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5580>
2023-11-01 15:41:08 +00:00
robert 737c32b9b6 ximagesrc: fix compile-time warning and XInitThreads()
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5493>
2023-11-01 09:17:24 +00:00
Slava Andrejev 3dd9411b36 glcolorconvert: add reordering for plain GBR color format
Fixes #2991

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5582>
2023-11-01 06:02:20 +00:00
Piotr Brzeziński 1db67b933a examples: Fix SSL not working in iOS tutorials
This was broken in two ways:
1) the OpenSSL module was not being loaded due to the guarding define not actually existing
2) ca-certificates were severely outdated

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5473>
2023-11-01 03:46:25 +00:00
Piotr Brzeziński edfd44d088 examples: iOS tutorial improvements
- Fixes a crash in tutorial 5, which happened when going back from video playback to the 'library' view, due to
ui_delegate already being destroyed at that point.

- Updates layouts to avoid navigation bar overlapping play/pause buttons. Colours are now correctly updated
based on light/dark mode being enabled, overall look and feel is improved with bigger buttons and paddings.
New button types are used, so target version is now iOS 15.0.

- Disables debug log coloring, as the default terminal in XCode does not render that anyway, so logs are now
more readable there.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5473>
2023-11-01 03:46:25 +00:00
Detlev Casanova 78e40a018f dev-tools: Add glib valgrind suppressions
The local glib subproject doesn't exist so the glib/glib.supp file
cannot be included.

As it is needed for the do_lookup_by_name() function call, let's add the
system wide suppression file so that its version matches the installed glib
version.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5434>
2023-10-31 12:06:30 -04:00
Nicolas Dufresne 72947f109c valgrind: Use frame-level widlcard for getaddrinfo leak
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5565>
2023-10-30 21:01:58 +00:00
Jeff Wilson 5c8fff0807 examples: webrtc: Actually create the custom ICE agent
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5568>
2023-10-30 19:58:59 +00:00
robert 2f115847c2 gstdtlsenc: fix stream_id and missing group_id
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5425>
2023-10-30 18:12:37 +00:00
Seungha Yang 107edc0c07 d3d11videosink: Add redraw-on-update property
If users update geometry related properties very frequently
for a stream to be animated, redrawing on every update
can make rendering choppy or can be a performance bottleneck.
To address the issue, adding a property to control the behavior
of redrawing scene when geometry related properties are updated.

Also, do not resize swapchain on such property update, since
re-allocating backbuffer and multi-sampled render target is
unnecessary in that case.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5575>
2023-10-30 11:15:35 +00:00
Seungha Yang 443f205c38 d3d11converter: Don't update vertex buffer on transform matrix change
Transform matrix change requires only constant buffer update

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5575>
2023-10-30 11:15:35 +00:00
Seungha Yang 795e1bac34 d3d11videosink: Fix window switching in case of fullscreen mode
Other Windows applications allow window switching even when
an application window is in fullscreen mode. Also fixing
regression introduced in 15248d8b84
which makes restored window is always located at topmost
since we do not call SetWindowPos() anymore when restoring

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5574>
2023-10-29 22:45:17 +09:00
Seungha Yang f32bb06e32 d3d11converter: Fallback to linear sampler if filter is not supported
Use linear sampler if requested filter is not supported

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5572>
2023-10-29 01:07:45 +09:00
Seungha Yang e7069984df d3d11videosink: Add sampling-method property
Identical to "method" property in d3d11convert element

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5572>
2023-10-28 23:12:30 +09:00
Seungha Yang b16665dc75 d3d11convert: Add support for sampling with anisotropic filter
Anisotropic filtering might produce better quality than linear filtering

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5572>
2023-10-28 22:56:28 +09:00
Seungha Yang af31b46992 d3d11convert: Add support for transform
Adding 3D rotation and scale transform support to d3d11convert element

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5572>
2023-10-28 22:12:17 +09:00
Seungha Yang 1813b4e3d9 d3d11: Move transform matrix related method to utils
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5572>
2023-10-28 22:12:17 +09:00
Seungha Yang 3a2a31d18b d3d11overlaycompositor: Set rasterizer state
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5572>
2023-10-28 22:12:17 +09:00
Seungha Yang 4dfdb6ec68 d3d11screencapturesrc: Set rasterizer state
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5572>
2023-10-28 22:12:17 +09:00
Seungha Yang 5389cc2cc3 d3d11compositor: Set rasterizer state
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5572>
2023-10-28 22:12:17 +09:00
Seungha Yang 1a82c9b9ab d3d11testsrc: Set rasterizer state
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5572>
2023-10-28 22:12:17 +09:00
Seungha Yang 5f44390b3e d3d11converter: Reuse rasterizer state object
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5572>
2023-10-28 22:12:17 +09:00
Seungha Yang e13612162b d3d11screencapturesrc: Use DirectXMath struct and C++ mutex
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5572>
2023-10-28 22:11:53 +09:00
Seungha Yang 63bb0b8de7 d3d11videosink: Add support for transform and MSAA
Adding properties for 3D rotation with arbitrary angle
and scaling. And adding Multi Sampling Anti-Aliasing rendering
support to smooth borders if arbitrary angle is applied

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5532>
2023-10-28 09:58:16 +00:00
Seungha Yang 524aa2badc subprojects: Add DirectXMath wrap
Will be used by d3d11 plugin

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5532>
2023-10-28 09:58:16 +00:00
Seungha Yang 0b45548f18 d3d11videosink: Fix typo
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5532>
2023-10-28 09:58:16 +00:00
Seungha Yang b7c49f8e9f d3d11converter: Add support for MSAA render target
Create multi-sample render target view if sample count > 1
and MSAA enabled rasterizer for multi-sample render target

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5532>
2023-10-28 09:58:16 +00:00
Seungha Yang eac65d248a d3d11converter: Add support for custom transform matrix
Adding gst_d3d11_converter_set_transform_matrix() method so that
user specified transform matrix can be applied when "video-direction=custom"

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5532>
2023-10-28 09:58:16 +00:00
Seungha Yang 769c6a62a4 d3d11converter: Use transform matrix for rotation/flip
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5532>
2023-10-28 09:58:16 +00:00
Seungha Yang 745a73eece wasapi2: Don't use global volume control object
ISimpleAudioVolume controls volume of corresponding audio session
and there would be only single input/output audio session
in case of share-mode, which means that it controls audio volume of the
process. Instead, use IAudioStreamVolume interface which controls
volume of the stream.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5549>
2023-10-27 18:11:51 +00:00
Seungha Yang bdc0f177f0 d3d11screencapturesrc: Fix mouse cursor blending
Ignore alpha component of source (mouse cursor texture)
when blending alpha channel, otherwise the background area of source
(which has zeros) will be written to render target. Then it will result
in black rectangle if output texture is converted to premultiplied alpha
texture

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5566>
2023-10-27 16:33:04 +00:00
Colin Kinloch 6f62b24788 debug-viewer: Use GtkFileChooserNative to open logs
This provides flatpak document portal support

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5390>
2023-10-27 15:34:31 +00:00
Colin Kinloch babc18c36e debug-viewer: Fix crash from unpacking NoneType objects
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5389>
2023-10-27 14:26:47 +00:00
Sebastian Dröge e6ff644bac aja: Move clang-format configuration from the top-level to the plugin subdirectory
This shouldn't have been left at the top-level but was forgotten to be
moved when merging the repository histories.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5558>
2023-10-27 11:44:36 +00:00
Tim-Philipp Müller 67d7df247b fpsdisplaysink: fix copy'n'paste-o in license header
It's LGPL licensed, remove confusing GPL reference.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5557>
2023-10-27 10:54:44 +00:00
Lieven Paulissen 9cc7e8c035 audioconvert: Fix fallback to identity mixing matrix when setting an empty mix-matrix
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5530>
2023-10-27 10:07:40 +00:00
Matthew Waters d20d94cc48 vkformat: also use the correct srgb vs unorm when using older
gst_video_info_from_video_info()

Fixes sRGB colorspace chosen by GstVulkanSwapper and therefore used for
display.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5316>
2023-10-27 09:13:18 +00:00
Tim-Philipp Müller 3438b7a880 kate: remove plugin
Bitrotten and not really used in the wild.

The actual render library (libtiger) is not just unmaintained
but the upstream location has disappeared, and it's also not
even packaged by e.g. debian/ubuntu.

Closes #3071

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5408>
2023-10-27 07:34:39 +00:00
Tim-Philipp Müller f6c40bb15c pngenc: mark output frames as I-frames
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5546>
2023-10-27 05:47:37 +00:00
Tim-Philipp Müller d69885e0f7 pngenc: output one frame only in snapshot mode
In snapshot mode pngenc should output exactly one frame
and then return FLOW_EOS to upstream. If upstream sends
more input frames before shutting down, it should keep
returning FLOW_EOS but not output any more encoded frames.

After a flushing seek it should output frames again though.

Fixes #3069.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5546>
2023-10-27 05:47:37 +00:00
Philippe Normand 7fd7917c78 wpesrcbin: Fix audio metadata
The meta expects the number of samples in the buffer, not the total size.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5531>
2023-10-27 04:55:20 +00:00
Jordan Petridis 7d64943b9d docs: Remove obselete appendix about parsing cli argumnets
It's a bad idea trying to mix the Options from GStramer and
GTK, in addition with cli argument being a bit wonky thing for
GUI applications in general. In the rare, now, occasion
that an application wants to parse arguments, its preferable
to parse them manually and use library apis afterwards
rather than trying to combine the option groups and hope it
works.

In addition, applications should be opening files using
`g_application_open` instead of parsing random arguments.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4788>
2023-10-27 04:46:17 +00:00
Tim-Philipp Müller 62ed87dec4 gstreamer: misc: relicense network-clock scheme files to LGPL v2.1+
Permission to relicense granted by author by e-mail:

Message-Id: <155C6D51-7F74-4C40-814A-2ADDED7707FD@pobox.com>
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5559>
2023-10-27 02:48:58 +00:00
Nicolas Dufresne 6b0124744e valgrind: Add getaddrinfo leak suppression
With Fedora 34 in our CI, we start seeing a sometime leak in getaddrinfo. At
first sight it looks like some TLS context being leaked. Could be a thread
teardown leak, just suppress it for now.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5562>
2023-10-26 22:57:39 +00:00
Víctor Manuel Jáquez Leal ce91004c3b build: opencv: disable opencv deps if it's not installed
When hotdoc documentation is enabled and opencv plugin is set as
auto-detected, but the library isn't installed, meson configuration fails
with this message:

  ../subprojects/gst-plugins-bad/docs/meson.build:139:21: ERROR: Unknown variable "gstopencv_dep".

This patch fixes this case defined gstopencv_dep as disabler() when
dependencies aren't found.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5560>
2023-10-26 20:43:14 +00:00
Mengkejiergeli Ba 38e8896887 vaallocator: Do not try derive image for d3d backend
Current codes try derive image in _update_image_info first, if
derive returns no error, the va_allocator->info is the one from derived
image, but in va_map_unlocked, we disable derive manner for d3d backend
because it doesn't seem to work, this will cause issue for d3d path,
i.e. possibly using derived info in va_get_image to do mapping...
This patch disables derive image for d3d backend in _update_image_info,
to ensure we only use info from va_create_image for d3d path.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5495>
2023-10-26 16:08:10 +00:00
Philippe Normand 03717697d9 debugutils: Ensure we always expose a bin_to_dot_data implementation
Fixes a linking issue when building with `-Dgst_debug=false`.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5550>
2023-10-26 08:24:40 +00:00
Víctor Manuel Jáquez Leal 250aa8daea vulkandownload: use GstVulkanOperation
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5079>
2023-10-26 07:26:23 +00:00
Víctor Manuel Jáquez Leal 11c8c002a5 vulkanupload: use GstVulkanOperation
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5079>
2023-10-26 07:26:23 +00:00
Víctor Manuel Jáquez Leal a2f875251f vkimagebufferpool: use GstVulkanOperation
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5079>
2023-10-26 07:26:23 +00:00
Víctor Manuel Jáquez Leal 265f1274dc vkoperation: synchronization helper object
An operation is an arbitrary amount of work to be executed on the host, a
device, or an external entity such as a presentation engine.

The purpose of this object is to help on the operation's synchronization
through declaring explicit execution dependencies, and memory dependencies
between two sets of operations defined by the command’s two synchronization
scopes.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5079>
2023-10-26 07:26:22 +00:00
Víctor Manuel Jáquez Leal c83c508c5e vulkan: add a timeline semaphore per image
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5079>
2023-10-26 07:26:22 +00:00
Víctor Manuel Jáquez Leal 964aec54b4 vkbarrier: Use guint64 for VkFlags and VkFlags2
While VkPipelineStageFlags is an enum (arguably backed as uint32 in 32bit
platforms), VkPipelineStageFlags2 is a redefinition of guint64; likewise for
VkAccessFlags and VkAccessFlags2.

This patch types both members in GstVulkanBarrierMemoryInfo as guint64 for
compatibility, so it could be used with or without synchronization2 vulkan
extension.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5079>
2023-10-26 07:26:22 +00:00
Víctor Manuel Jáquez Leal 8809ce5648 vkmemory: unref queue in barriers
Queue might be assigned for queue transfers, so we need to unref it if the
memory has been assigned to a specific queue.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5079>
2023-10-26 07:26:22 +00:00
Víctor Manuel Jáquez Leal 5acd6c23b8 vkdevice: use macro VK_KHR_synchronization2 as guard
Instead of (defined(VK_VERSION_1_3) || (defined(VK_VERSION_1_2) && VK_HEADER_VERSION >= 170))

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5079>
2023-10-26 07:26:22 +00:00