Commit graph

3813 commits

Author SHA1 Message Date
Jordan Petridis
14c1bedb45 gstvafilter: Add back missing property comments
In b1cda4439b the property comments
were removed, even though these are marked as public api.

Add back the comments, and a Since version for interpolation-method.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7455>
2024-10-25 13:55:18 +00:00
Edward Hervey
38c07a2d01 all: Fix closure annotations
This was misused almost everywhere.

See
https://gi.readthedocs.io/en/latest/annotations/giannotations.html#support-for-gobject-closures

and: https://www.bassi.io/articles/2023/02/20/bindable-api-2023/

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7725>
2024-10-25 08:58:29 +00:00
Diego Nieto
43c9c3a020 debugutils: videocodectestsink: support GRAY8 and GRAY10_LE{16,32}
Add support for:
    * GST_VIDEO_FORMAT_GRAY8
    * GST_VIDEO_FORMAT_GRAY10_LE16
    * GST_VIDEO_FORMAT_GRAY10_LE32

These formats are used by Fraunhofer VVC encoder and decoder.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7706>
2024-10-25 05:53:22 +00:00
Carlos Falgueras García
561ca94916 video: Add GRAY10_LE16 support
This adds a 10-bit variant of grayscale packed into 16 bits little-endian
words. The MSB 6 bits are padding and should be ignored. This format is
used by Fraunhofer VVC encoder and decoder libraries.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7706>
2024-10-25 05:53:22 +00:00
Peter Stensson
06d4629521 codectimestamper: Fix gint wraparound in pts_compare_func
The diff between compared timestamps might be outside the gint range
resulting in wrong sorting results. This patch corrects that by
comparing the timestamps and then returning -1, 0 or 1 depending on the
result.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7726>
2024-10-25 01:49:10 +00:00
Andoni Morales Alastruey
e8ab9349f5 vtdec: add support for level 6 6.1 and 6.2
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7729>
2024-10-24 21:45:32 +00:00
Jordan Yelloz
bcaf72ba62 mpegtsmux: Schedule PMT update on stream removal
Following the behavior of tsmux_program_add_stream(), this ensures that a PMT
update will also be caused by removal of a stream from a program.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7719>
2024-10-24 16:08:12 +00:00
Sebastian Dröge
493f8e440a mpegtsdemux: Handle PTS/DTS wraparound with ignore-pcr=true
The wraparound handling code assumes that the PCR gets updated regularly for
being able to detect wraparounds. With ignore-pcr=true that was not the case and
it stayed initialized at 1h forever.

To avoid this problem, update the fake PCR whenever the PTS advanced by more
than 5s, and also detect wraparounds in these fake PCRs.

Problem can be reproduced with

  $ gst-launch-1.0 videotestsrc pattern=black ! video/x-raw,framerate=1/5 ! \
    x264enc speed-preset=ultrafast tune=zerolatency ! mpegtsmux ! \
    tsdemux ignore-pcr=true ! fakesink

which restarts timestamps at 0 after around 26h30m.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7588>
2024-10-24 15:09:15 +00:00
Seungha Yang
8c3d516a14 d3d12: Additional fixes for MinGW build
Various fixes for GCC build, including actual bug fixes

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7722>
2024-10-24 06:54:30 +09:00
Seungha Yang
703cc1783e d3d12: Fix MinGW build with installed DirectX-Headers
Required for cerbero MinGW build

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7154>
2024-10-22 21:25:11 +00:00
Daniel Morin
db78446576 tensordecoder: Correct Klass, for ssd TD
Tensor decoder need a specific klass to be able to auto-plug them

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7698>
2024-10-22 20:23:32 +00:00
Jochen Henneberg
2ae846a77a examples: va: Added VP8 encoder to dynamic reconfigure
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6959>
2024-10-22 11:48:49 +00:00
Jochen Henneberg
f31581544c va: Added VP8 encoder
Fixes #3430
Fixes #3576

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6959>
2024-10-22 11:48:49 +00:00
Jochen Henneberg
982bfe4f5d codecparsers: vp8parser: Added frame type enums
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6959>
2024-10-22 11:48:49 +00:00
Seungha Yang
fb6a5c8a0c d3d12mipmapping: Fix debug category
Fixing copying-and-pasting mistake

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7701>
2024-10-20 16:01:10 +00:00
Benjamin Gaignard
451b32574f v4l2codecs: dynamically discovers supported pixels formats
If the driver allows it, for each stateless decoder,
enumerate all the pixels formats and use this list for source
pad instead of a static template.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7686>
2024-10-19 22:14:13 +00:00
Benjamin Gaignard
3a52cbcc67 v4l2codecs: Update videodev2.h with V4L2_FMTDESC_FLAG_ENUM_ALL flag
Add V4L2_FMTDESC_FLAG_ENUM_ALL flag to support discovering all
possible pixel formats.
Add V4L2_FMT_FLAG_META_LINE_BASED to not create a hole in flag
definition.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7686>
2024-10-19 22:14:13 +00:00
Víctor Manuel Jáquez Leal
45b01f9456 h26xbitwriter: false have_space if aligning fails on aud
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7655>
2024-10-19 17:28:41 +00:00
Edward Hervey
360787ef27 qrbaseoverlay: Add doc/since
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7692>
2024-10-19 16:31:13 +00:00
He Junyan
dce250beb8 vaav1enc: Do not enable palette mode by default
Palette mode should only be enabled only when we know that the content
of the picture is simple. For example, only white letters on black
screen in SCC mode. So, by default, we need to disable it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7668>
2024-10-19 12:34:40 +00:00
Benjamin Gaignard
c67e6cdec7 kmssink: Add IMX-DCSS auto-detection
Add IMX DCSS display controller into list of
auto-detected modules.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7685>
2024-10-19 04:54:18 +00:00
Benjamin Gaignard
e13065b22a v4l2codecs: vp9: Allow inter-frames resolution change
When the stream resolution change it is needed to negotiate
a new pools and to update the caps.
Resolution change could occurs on a new sequence or a new
picture so move resolution change detection code in a common
function.
For memory allocation reasons, only allows resolution change
on non keyframe if the driver support remove buffer feature.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7684>
2024-10-19 01:39:04 +00:00
Benjamin Gaignard
34997e88ae codecs:vp9 decoder: Remove unsused info field
Video info field is never used so remove it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7684>
2024-10-19 01:39:04 +00:00
Benjamin Gaignard
0f171b2086 codecs: vp9 decoder: Drain output buffers before resolution change
We must drain the pending output picture so that subclass can renegotiate
the caps. Not doing so while still renegotiating would mean that the
subclass would have to do an allocation query before pushing the caps.
Pushing the caps now without this would also not work since these caps
won't match the pending buffers format.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7684>
2024-10-19 01:39:04 +00:00
Benjamin Gaignard
ad537ef934 v4l2codecs: Add remove buffers helpers
Add helpers function to call VIDIOC_REMOVE_BUFS ioctl.
If the driver support this feature buffers are removed from the queue when:
- the pool when is detached from the decoded.
- the pool is released.
- allocation failed.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7684>
2024-10-19 01:39:04 +00:00
Benjamin Gaignard
fecdfe18ca v4l2codecs: Do not register stateless decoder if the driver doesn't support VIDIOC_CREATE_BUFS
If the driver can't allocate buffers with VIDIOC_CREATE_BUFS do not
register it has stateless decoder.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7684>
2024-10-19 01:39:04 +00:00
Benjamin Gaignard
2753a8f0c1 v4l2codecs: Replace VIDIOC_REQBUFS calls by VIDIOC_CREATE_BUFS
Use VIDIOC_CREATE_BUFS ioctl to create buffers instead of VIDIOC_REQBUFS
because it allows to create buffers also while streaming.
To prepare the introduction of VIDIOC_REMOVE_BUFFERS create
the buffers one per one instead of a range of them. This way
it can, in the futur, fill the holes.
gst_v4l2_decoder_request_buffers() is stil used to remove all
the buffers of the queue.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7684>
2024-10-19 01:39:04 +00:00
Benjamin Gaignard
c25c4355b1 v4l2codecs: udpate videodev2.h
Update videodev2.h to be aligned with kernel version v6.10

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7684>
2024-10-19 01:39:03 +00:00
Emil Ljungdahl
68bbfdc9a2 webrtcbin: Clean up bin elements when datachannel is removed
When a datachannel within a session is removed after proper close,
reference to the error_ignore_bin elements of the datachannel
appsrc/appsink were left in webrtcbin.

This caused the bin-objects to be left and not freed until the whole
webrtc session was terminated. Among other things that includes a thread
from the appsrc.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7675>
2024-10-18 23:14:09 +00:00
Francisco Javier Velázquez-García
f6e8b88128 srtsink: Add guard for null error when SRT open fails
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7628>
2024-10-18 16:36:59 +00:00
Francisco Javier Velázquez-García
2caa6721f9 srtsink: Register SRT listen callback before binding socket
This change https://github.com/Haivision/srt/pull/2683 forces us to
call `srt_listen_callback` before `srt_listen`.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7628>
2024-10-18 16:36:59 +00:00
Daniel Morin
9fc017667f test: Adding a test for segmentation analytics-meta
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6026>
2024-10-17 18:13:03 +00:00
Daniel Morin
6db6d44ff5 analytics: add segmentation analytics-meta
- Add a new analytics-meta to store segmentation analysis result.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6026>
2024-10-17 18:13:03 +00:00
Daniel Morin
98653aa43a analytics: Allow specific analytics-meta (Mtd) to handle their clear
- Add mtd_meta_clear to allow specific analytics-meta to handle their clear
  operation specific to their type.

- Clear mtd's attached when analytic-meta is freed. When the buffer where
  analytics-meta is attached is not from a buffer pool
  gst_analytics_relation_meta_clear will not be called unless we explicitly call
  it in _free. This important otherwise _mtd_clear are not called and lead to
  leak if embedded mtd's allocated memory
- Un-ref in transform if it's a copy

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6026>
2024-10-17 18:13:03 +00:00
Jordan Petridis
4b8d43446e lc3: tests: Zero out the buffer we allocate for the tests
Otherwise liblc3 will try to access the uninitialized memory
and it makes valgrind very sad.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7657>
2024-10-16 14:16:43 +00:00
Stéphane Cerveau
5e7f187d93 scenechange: fix memory leak
A reference to the last buffer(oldbuf) was kept
leading to a memory leak on stop.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7662>
2024-10-15 04:20:01 +00:00
Víctor Manuel Jáquez Leal
0e9634e17c codecparsers: add debug categories to bitwriters
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7653>
2024-10-14 22:05:04 +00:00
Nirbheek Chauhan
303dd73779 meson: Explicitly use cpp_std=c++11 for dxva
dxva is built unconditionally on all platforms where introspection is
enabled, so let's fix the build on macOS so that introspection can be
enabled there: https://gitlab.freedesktop.org/nirbheek/cerbero/-/jobs/65009118

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7659>
2024-10-13 19:31:27 +00:00
L. E. Segovia
4dcc4b6235 meson: Undefine any WINVER and _WIN32_WINNT entries before redefining them
Fixes Cerbero build with MinGW GCC 14, where specifying -DWINVER=0x0601 -DWINVER=0x0A00 is a hard -Werror.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7658>
2024-10-12 19:10:46 -03:00
L. E. Segovia
572f2d10f5 meson: amfcodec: fix build with MinGW GCC 14
>  ../sys/amfcodec/include/core/PropertyStorage.h:87:50: error: 'virtual void
>   amf::AMFPropertyStorage::RemoveObserver(amf::AMFPropertyStorageObserver*)' was hidden [-Werror=overloaded-virtual=]

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7658>
2024-10-12 19:05:23 -03:00
L. E. Segovia
4af2121189 meson: d3d12: fix build with MinGW GCC 14
Also apply the d3d11 fix since both use the same header.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7658>
2024-10-12 19:01:46 -03:00
L. E. Segovia
f8d6b3d568 meson: d3d11: fix build with MinGW GCC 14
In my tests with the new GCC 14 compiler for Cerbero, I got the
following error:

> In file included from include/directxmath/DirectXMath.h:2275,
> from ../gst-libs/gst/d3d11/gstd3d11converter.cpp:46:
> include/directxmath/DirectXMathMatrix.inl: In function 'bool
>   DirectX::XMMatrixDecompose(XMVECTOR*, XMVECTOR*, XMVECTOR*, FXMMATRIX)':
> include/directxmath/DirectXMathMatrix.inl:1161:16:
>  error: variable 'aa' set but not used [-Werror=unused-but-set-variable]

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7658>
2024-10-12 19:01:13 -03:00
Jan Schmidt
6b94f22bd6 webrtcbin: Retrieve RR stats from internal sources
Check and generate remote reception statistics from the info stored on
internal sources, as they are stored there  when running against newer rtpbin
since MR !7424

This fixes cases where statistics are incomplete when
peers send RR reports from a single remote ssrc, which GStreamer does
when bundling is enabled and other RTP stacks may too.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7425>
2024-10-12 04:12:22 +00:00
Nirbheek Chauhan
80bb69ba66 vtdec: Set input formats when we get incomplete caps
In some cases, decodebin3 will send us incomplete caps (not containing
codec_data), and then a GAP event, which will force a negotiation.
This segfaults due to a null pointer deref because self->input_state
is NULL.

The only possible fix is to avoid negotiating when we get incomplete
caps (to avoid re-negotiationg immediately afterwards, which isn't
supported by some muxers), but also set as much input state as
possible so that a renegotiation triggered by a GAP event can complete
successfully.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7634>
2024-10-12 01:31:52 +00:00
Xavier Claessens
b4ccd940d4 qroverlay: Change pixel-size to percent of width or height
The size is now expressed in percent of the smallest dimention. 100
means the biggest square that fits the render area.

Fixes: #3695
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7638>
2024-10-11 04:07:26 +00:00
Víctor Manuel Jáquez Leal
809ab829d0 tests: va: fix vapostproc test for DMABuf
Now it picks the first format in the template srcpad list and do
the convertion. Also the format size is reduced because not all
drives support 4K as DMABuf (radeonsi).

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7636>
2024-10-10 16:34:04 -04:00
Seungha Yang
7c06001705 d3d12: Shorten various names
Update names of various objects and method to be shorter, for instance
GstD3D12CommandAllocator is changed to GstD3D12CmdAlloc.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7642>
2024-10-10 10:35:36 -04:00
Seungha Yang
024f450204 d3d12: Fix typo in docs
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7642>
2024-10-10 09:21:54 -04:00
Seungha Yang
ef55b31f46 d3d12: Early error out on Signal() fail
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7642>
2024-10-10 09:21:54 -04:00
Jordan Petridis
ab54e45f67 tests/lc3: Allocate the same size for the buffer and the data
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/7631>
2024-10-09 22:16:13 +00:00