Commit graph

117145 commits

Author SHA1 Message Date
Matthew Waters
8003acf5bb gl: update docs for mixer move
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4608>
2023-05-18 19:34:15 +00:00
Matthew Waters
e9bf1c79cc glmixer: don't add rgba templates by default
Subclasses may want to override the pad template with different formats
or with a different pad subclass.

The original beahviour is still available by calling
gst_gl_mixer_class_add_rgba_pad_templates() in _class_init() of the
subclass.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4608>
2023-05-18 19:34:15 +00:00
Matthew Waters
fc85b63c2b glmixer: remove set_caps() vfunc
All of its implementors can be moved to gl_start/stop() from
GstGLBaseMixer instead.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4608>
2023-05-18 19:34:14 +00:00
Matthew Waters
331b1af468 glmixer: remove reset vfunc
This functionality is covered by GstGLBaseMixer's gl_stop() vfunc.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4608>
2023-05-18 19:34:14 +00:00
Matthew Waters
14e7e991d3 gl/mixer: make fbo instance field private and provide accessor function
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4608>
2023-05-18 19:34:14 +00:00
Matthew Waters
007a602726 gl: move gl(base)mixer to library
For use by applications/libraries outside of the opengl plugin.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4608>
2023-05-18 19:34:14 +00:00
Mengkejiergeli Ba
7613e50cbb bad:docs: Add new properties description for msdkh264enc and msdkh265enc
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4589>
2023-05-18 17:53:44 +00:00
Mengkejiergeli Ba
7d993f930b msdkenc: Add properties max/min-qp for I/P/B frame separately in avc and hevc
max-qp and min-qp will set the same quantizer scale for I/P/B frames,
while max-qp-i/p/b and min-qp-i/p/b enable the max/min quantizer for I,P,B
frame separately. When max/min-qp and max/min-qp-i/p/b are given
simultaneously, the later set one will overide the previous one.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4589>
2023-05-18 17:53:44 +00:00
Shengqi Yu
5da9a8e2f4 v4l2object: fix some errors in probe_caps_for_fromat
1, there is a mistake when print stepwise.max_height, fix it
2, modify the calculation of width and height under the step wise
condition

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4562>
2023-05-18 13:45:11 +00:00
Sangchul Lee
2a79f23e9d tests/webrtc: Validate peer connection stats
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2127>
2023-05-18 12:08:55 +00:00
Sangchul Lee
2661bf6d9a webrtc: Add data-channels-opened/closed to get-stats signal documentation
With contributions from: Matthew Waters <matthew@centricular.com>

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2127>
2023-05-18 12:08:55 +00:00
Haihua Hu
78d9d8478d gstplay: fix critical log when enable playbin3
when play rtsp stream with playbin3 enabled, there are some critical logs:

g_object_get_is_valid_property: object class 'GstPlayBin3' has no property named 'n-video'
g_object_get_is_valid_property: object class 'GstPlayBin3' has no property named 'n-audio'
g_object_get_is_valid_property: object class 'GstPlayBin3' has no property named 'n-text'

self->collection could be NULL when READY->PAUSED if the pipeline
is live, then it will fallback to query playbin2's property,
we can call gst_play_streams_info_create_from_collection
directly, it will check self->collection internal.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4460>
2023-05-18 10:27:29 +00:00
Ruben Gonzalez
5c0f6b88d8 README.md: fix current version
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4662>
2023-05-18 06:25:50 +00:00
Martin Nordholts
85e3f31740 webrtc: Track stats for data channels opened and closed
Track data channel stats for `dataChannelsOpened` and
`dataChannelsClosed` in `RTCPeerConnectionStats` as specified by
https://www.w3.org/TR/webrtc-stats/#dictionary-rtcpeerconnectionstats-members

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4638>
2023-05-18 04:31:16 +00:00
Seungha Yang
ad70dd64f9 d3d11videosink: Add render-rectangle property
... and resize HWND on GstVideoOverlay::set_render_rectangle even when
we are rendering without external HWND

Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/2563
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4653>
2023-05-17 23:06:05 +00:00
Seungha Yang
e9d8bf7532 h264parser: Define level enum values
... and stop duplicating it

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4595>
2023-05-17 21:29:25 +00:00
Hou Qi
783ebbeecb v4l2videoenc: fix set format failure when needs reset encoder
In cases that encoder needs to reset format, there is race while draining.
v4l2videoenc finish() sends CMD_STOP command to driver, and desire to return
GST_FLOW_OK. But at this time, encoder CAPTURE may have dequeued the last
buffer and got eos. finish() return value changes to be GST_FLOW_EOS which
causes set format fail. So there is no need to check return value for finish()
when set format.

Also need to flush encoder after draining to make sure flush is finished.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4495>
2023-05-17 17:59:29 +00:00
Nirbheek Chauhan
aa1fa50129 webrtc_sendrecv.py: Add AV1 support when creating the offer
Requires svtav1enc at present for simplicity.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4644>
2023-05-17 16:20:36 +00:00
Nirbheek Chauhan
61e536b546 webrtc_sendrecv.py: Fix warnings about gi version
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4644>
2023-05-17 16:20:36 +00:00
Elliot Chen
f722d9c428 gstplay: avoid getting property of playbin2 if subtitle_sid is null
There is a probability of getting "current-text" property
 when play with playbin3, and this property is available
 only in playbin2.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4106>
2023-05-17 15:24:29 +08:00
Seungha Yang
289bc9c91d wasapi2: fix "device" property description
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4651>
2023-05-17 04:50:04 +00:00
Tim-Philipp Müller
c80b0a589a wasapi: fix "device" property description
Fixes gstreamer/gst-plugins-bad#1620

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4651>
2023-05-17 04:50:04 +00:00
Carlos Rafael Giani
5cf384a632 avdtputil: Use int instead of int range for fixed bitpool values
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/issues/1698

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4650>
2023-05-17 03:13:54 +00:00
Seungha Yang
7a3be74b63 cudaconvertscale: Add support for flip/rotation
Similar to the d3d11convert element, colorspace conversion, resizing and
flip/rotation operations can be done in a single kernel function call

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4640>
2023-05-16 19:24:36 +00:00
Seungha Yang
d335eb8c7c d3d11convert: Fix for runtime property update
Every setup happens in set_caps() method but basetransform will not
call the set_caps() if in/out caps were not changed

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4646>
2023-05-16 16:03:35 +00:00
Haihua Hu
36333a5152 decodebin3: fix random hang when remove failing stream
When reconfigure_output_stream entry missing decoder path,
requested_selection should been update with what is really
active/selected immdiately with SELECTION_LOCK hold. So
use an optional message return from reconfigure_output_stream
and post it after release SELECTION_LOCK. This can make sure
other thread call to check_slot_reconfiguration will got
a correct requested_selection.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4599>
2023-05-16 12:43:12 +00:00
Sebastian Dröge
99285bb566 qtmux: Fix extraction of CEA608 data from S334-1A packets
The index is already incremented by 3 every iteration so multiplying it
by 3 additionally on each array access is doing it twice and does not
work.

This caused invalid files to be created if there's more than one CEA608
triplet in a buffer, and out of bounds memory reads.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4634>
2023-05-16 11:29:45 +00:00
He Junyan
3497bbb8a8 va: No need to sort the device after registered
The va devices are already registered by the drm path order, so
there is no need to sort them again after registered.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4643>
2023-05-16 08:37:48 +00:00
He Junyan
8e52e42444 va: Sort udev path name before register the va plugins
The devices list returned by g_udev_client_query_by_subsystem() may
contain udev devices in disorder path name. For example, on some
platform it may contain renderD129 before renderD128 device. This
will cause we register wrong va plugin name. In this case, the
renderD129 will be registered as default plugins such as vah265dec,
while the renderD128 will be registered as varenderD128h265dec.
This conflicts with the non-udev version of gst_va_device_find_devices().

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4643>
2023-05-16 08:37:48 +00:00
Jan Schmidt
131d59518e splitmuxsrc: Make PTS contiguous by preference
Make splitmuxsrc deal better with stream reordering by
making the largest observed PTS contiguous in the
next fragment. Previously, it selected DTS, but then
aligned that with the segment start of the next fragment,
which holds PTS values - leading to glitches in
streams that don't have PTS = DTS at the start.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4637>
2023-05-16 04:34:16 +00:00
Víctor Manuel Jáquez Leal
ad40a9323e jpegparse: fix warning text and debug data
They were backwards or missing.

Fix: #2567
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4641>
2023-05-15 17:31:58 +02:00
Johan Sternerup
a1f0727186 sctpenc: Fix potential shutdown deadlock
When transitioning from state PAUSED to READY, the sctpenc element
could previously be stuck in an endless loop trying to resend data
in case the underlying sctp stream was in the process of
resetting. usrsctp_sendv() would repeatedly return EAGAIN with the
result that 0 bytes were sent and then sctpenc would retry forever.

To bring sctpenc out of the resend loop we just need to inform the
sink pad that it is flushing, which is already done for the associated
data queue, but we also need to set the bools associated with the
sinkpads that are used as the loop criterion.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4601>
2023-05-15 06:57:07 +00:00
Yinhang Liu
c5748c2051 msdkmjpegdec: Fix ColorFormat for BGRx format
For msdkmjpegdec, the BGRx format is supported in src caps,
set the ColorFormat to MFX_JPEG_COLORFORMAT_RGB.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4489>
2023-05-15 05:41:35 +00:00
Yinhang Liu
3883ae8c2a msdk: Fix initialization of the msdk_session.impl_idx
This fixes the issue of msdk_session.impl_idx not being initialized.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4448>
2023-05-15 01:22:29 +00:00
Sebastian Dröge
bb2c5981fe pulse: Change bitfield booleans to normal gbooleans
Assigning TRUE (1) to a signed 1 bit integer will cause truncation
from 1 to -1 because the only non-zero value that can be stored is -1
due to how two's-complement works.

As this is a proper GObject let's not bother with all this and simply
use a normal gboolean instead.

../subprojects/gst-plugins-good/ext/pulse/pulsesink.c:1490:19: warning: implicit truncation from 'int' to a one-bit
        wide bit-field changes value from 1 to -1 [-Wsingle-bit-bitfield-constant-conversion]
  pbuf->in_commit = TRUE;
                  ^ ~~~~

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4617>
2023-05-14 15:58:35 +00:00
Sebastian Dröge
f9a3b3eacf rtpjitterbuffer: Fix uninitialized variable compiler warning
It could indeed be used uninitialized, but only if one of the
g_return_val_if_fail() caused an early return.

../subprojects/gst-plugins-good/gst/rtpmanager/rtpjitterbuffer.c: In function ‘rtp_jitter_buffer_append_query’:
../subprojects/gst-plugins-good/gst/rtpmanager/rtpjitterbuffer.c🔢10: warning: ‘head’ may be used uninitialized
      [-Wmaybe-uninitialized]
 1234 |   return head;
      |          ^~~~
../subprojects/gst-plugins-good/gst/rtpmanager/rtpjitterbuffer.c:1232:12: note: ‘head’ was declared here
 1232 |   gboolean head;
      |            ^~~~

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4616>
2023-05-14 14:26:05 +00:00
Sebastian Dröge
186d8a99cc avviddec: Temporarily unlock stream lock while flushing buffers
This can call into the decoder again from other threads and try to take
the stream lock from there, which would cause a deadlock.

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

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4610>
2023-05-13 10:20:32 +00:00
Seungha Yang
e34397ab09 d3d11: Update element meta
Make them consistent, update outdated description and fix some typos

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4619>
2023-05-12 20:13:58 +00:00
Mathieu Duponchelle
9914b34bf5 parse/grammar: fix missing unref of looked up child
the target parameter of gst_child_proxy_lookup() is (transfer full)

Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/2560
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4622>
2023-05-12 19:07:09 +00:00
Víctor Manuel Jáquez Leal
7df7efdc3f vulkan: minor meson clean ups
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4621>
2023-05-12 18:04:52 +00:00
Sebastian Dröge
0219b6f6fa ptp-helper: Add some tests for functionality and memory safety of unsafe code
These tests are mostly for ensuring that the calls to system APIs are
done correctly and that there are no memory bugs (that would be caught
by valgrind) in the unsafe code.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4458>
2023-05-12 17:06:01 +00:00
Philippe Normand
fe4f034c8a wpe: Add support for the WPEWebKit 2.0 API version
Most notably this disables console messages support when the 2.0 API is used,
because there is no replacement for it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4159>
2023-05-12 14:20:31 +00:00
Michael Olbrich
b660f258a6 theoradec: make sure the selected pool accepts the new config
If gst_buffer_pool_set_config() fails then the pool will use its old
config. This may include different width or height when
pic_width/pic_height != frame_width/frame_height.
As a result, the assertions in theora_handle_image() will fail.

So check the result of gst_buffer_pool_set_config() and only use the pool
if it succeeds. Otherwise let the parrent decide_allocation() create a new
pool.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4600>
2023-05-12 14:37:06 +02:00
Michael Olbrich
802b3b9898 theoradec: add another assert to check the buffer size
If the buffer has no video meta then the meta is created from the local
data. In this case, the other asserts don't actually check anything. So add
another one to ensure that the buffer is actually large enough.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4600>
2023-05-12 14:37:06 +02:00
Michael Olbrich
9dd6b08fcc theoradec: remove unused codec state variable
The last user of this state was removed in 9a541157cf "theoradec: Fix
decoding in the presence of GstVideoCropMeta".

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4600>
2023-05-12 14:37:06 +02:00
Nirbheek Chauhan
681f042f27 meson: Install viv-fb GL headers, needed by i.MX
Needed by qmlglsink at build time to allocate a viv-fb display.

Without this, the GL fastpath doesn't work, and performance is really
bad.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4613>
2023-05-12 15:05:56 +05:30
Yinhang Liu
f04a1eee71 video: video-info-dma: Fix return value
The return value of gst_video_info_dma_drm_new_from_caps is a pointer type,
and should not return a boolean type. Fix this issue.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4612>
2023-05-12 15:38:08 +08:00
Matthew Waters
b10ec569d7 webrtc: advertise end-of-candidate with an empty candidate string
Just like what is done in the browsers.  When this is sent to the peer,
they will be able to know that no more candidates are coming and can
complete ICE.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4598>
2023-05-12 04:52:22 +00:00
Piotr Brzeziński
5e45a1b1bd macos: Set activation policy in osxvideosink and glimagesink
Upon creating a window, glimagesink and osxvideosink now set the policy to
NSApplicationActivationPolicyRegular, which lets us show an icon in the Dock
for convenience and appear in the top menu bar like other apps.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4573>
2023-05-12 01:14:44 +02:00
Lukas Geiger
1815061e26 macos: Set activation policy in gst_macos_main
Setting the policy to NSApplicationActivationPolicyAccessory by default makes
sure that we can activate windows programmatically or by clicking on them.
Without that, windows would disappear if you clicked outside them and there
would be no way to bring them to front again. This change also allows osxvideosink
to receive navigation events correctly.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4573>
2023-05-12 01:11:19 +02:00