This patch refactors gst_wl_display_callback_destroy() to use the
recently introduced gst_wl_display_object_destroy() helper. Previously,
the function manually handled wl_callback destruction with explicit
lock/unlock calls and direct invocation of wl_callback_destroy().
Switching to gst_wl_display_object_destroy() unifies the destruction
process across similar objects, reducing code duplication and potential
errors.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8242>
when received xdg config event fron wayland server,
gst_wl_display_thread_run will call handle_xdg_surface_configure
which protected by priv->sync_mutex.
and in handle_xdg_surface_configure, configure_mutex also is locked
but if waylandsink set state from paused to ready, that will dispose
wlwindow, which will try to clear configure_mutex, and try to destroy
xdg_surface,
that do not proteced by anything.
so, problem is:
1) if clear configure_mutex(with locked state), clear lock will abort
2) after xdg_surface destroy, handle_xdg_surface_config may still call
ack_configure, that will lead wayland server go wrong
so, this patch updates gst_wl_window_finalize to use the new
destruction function for xdg_toplevel and xdg_surface, ensuring all
destruction operations are properly synchronized.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8242>
When the driver prefered format is not picked by downstream, the
decoders needs to select another format from the list. The selection
was currently unsorted, resulting in 10bit data often being stripped
to 8bit.
To solve this, reorder the formats in an HW preference order. This order
deviates slightly from the preferred order in libgstvideo. This is to
prefer bandwidth saving over better CPU alignment. As an example NV15 is
prefered over P010. We also prefer tiled over linear.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8522>
Add new property to support application allocated GstCudaMemory.
CUDA memory alloc/free is a global device synchronization point
as if launching CUDA kernel on default CUDA stream. To avoid the global
synchronization, we added stream-ordered allocation support
which allocates CUDA memory asynchronously.
However, NVENC does not allow registering the stream-ordered
allocated memory. Thus encoder was allocating normal CUDA
memory in case that input CUDA memory is stream-ordered type.
In this commit, newly introduced property will allow application
to provide encoder with GstCudaBufferPool. Application can
preallocate sufficient amount of CUDA memory in advance
to avoid global device synchronization while pipeline is running.
For now, this pool is used only if input CUDA memory is allocated
via stream-ordered-allocation
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8516>
The parent class will allow the handle to be reused at the end of the function.
If we are still modifying the released fence, then another thread can acquire
the fence while we are still clearing some of its data and produce a data race
or a leaked fence depending on which thread wins.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8491>
We can only reliably use the adaptation field discontinuity flag if our input is
properly timestamped on a regular basis (ex: UDP, DVB, RTP, etc...).
For HLS and other systems which don't provide that information, we should not
reset the base observations. Otherwise we would potentially end up picking a
reference time from a long time ago.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8480>
Adding new h264ccextractor element. This element will extract
closed caption meta from H.264 stream, and output in display order.
For the frame reordering, this element is implemented as a subclass
of h264decoder but without actual frame decoding.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6580>
As per the C++ standard, any usage of a std::set::iterator after it has
been erased from the collection results in undefined behaviour. This has
resulted in application crashes due to CUDA illegal address errors.
This commit fixes the issue by copying and incrementing the iterator
within any for-loops that also invoke std::set::erase.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8472>