Commit graph

112906 commits

Author SHA1 Message Date
Seungha Yang
80567ca939 deinterlace: Drop "field-order" field while transforming caps
Like other basetransform subclasses are doing, drop field
which can be converted by deinterlace.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/997>
2021-05-27 12:58:30 +00:00
Seungha Yang
9a8aea4a6a deinterlace: Drop field-order field if outputting progressive
Progressive with field-order doesn't make sense

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/997>
2021-05-27 12:58:30 +00:00
Seungha Yang
ad65081ef9 interlace: Don't set field-order field for progressive caps
That would cause negotiation issue

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2282>
2021-05-27 08:15:15 +00:00
Seungha Yang
1ac30ad53f interlace: Drop framerate from query caps of sinkpad
Query caps should return caps which represent the element can accept,
not resulting format.

Fixing negotiation error with
gst-launch-1.0 videotestsrc ! video/x-raw,framerate=25/1 ! interlace field-pattern=0 ! fakesink

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2282>
2021-05-27 08:15:15 +00:00
Seungha Yang
5ad59ce725 audiobasesrc: Fix divide by zero assertion
GstAudioRingBufferSpec can be cleared from other thread, then
rate value will be zero

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1179>
2021-05-27 07:51:48 +00:00
Marijn Suijten
9a502c15c6 audio,video-format: Make generate_raw_formats idempotent for assertions
When compiling without assertions `g_assert` and its contents disappear
resulting in no list being deserialized at all and the
`gst_{audio,video}_formats_raw` functions to return an empty collection.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1177>
2021-05-26 23:35:16 +02:00
Tim-Philipp Müller
e539f0cd67 Use new gst_buffer_new_memdup()
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1170>
2021-05-26 11:46:27 +00:00
Seungha Yang
da33921f8d d3d11compositor: Fix caps update handling
New caps is applied only when previous buffer is consumed if any.
So, the lastest given caps might not be corresponding to the current buffer
to be handled.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2284>
2021-05-26 16:42:39 +09:00
Víctor Manuel Jáquez Leal
9514340d2d libs: va: display: Handle auto clean up macros.
Add G_DEFINE_AUTOPTR_CLEANUP_FUNC macro for display classes, so auto
pointers are possible to users.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2269>
2021-05-26 05:42:33 +00:00
Havard Graff
26c94af2ea rtpssrcdemux: fix "data flow before segment event" crash
This crash could happen at any time a RTP and RTCP buffer arrived
simultaneously in ssrcdemux.

The problem was that sticky-event arriving while the rtp and rtcp pads
were being set up could arrive just too late to be included in the initial
forwarding.

The fix checks if the stickies have been sent on the srcpad about to be
pushed on, and if not sends them. It also blocks any stickes from
being forwarded *prior* to this happening, to avoid them arriving on
the srcpad multiple times.

Since the test loops 1000 times, this will make running under valgrind
take forever, so use the RUNNING_ON_VALGRIND variable to detect we
are running under valgrind, and reduce the loop-count to 2 in that case.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/992>
2021-05-25 22:04:41 +00:00
Havard Graff
de3a3882e9 rtpssrcdemux: refactor destruction of GstRtpSsrcDemuxPads
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/992>
2021-05-25 22:04:41 +00:00
Havard Graff
c721c6fe72 rtpssrcdemux: make naming consistent
Use plural for GstRtpSsrcDemuxPads, since it contains two pads, and
use the variable-name 'dpads' everywhere.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/992>
2021-05-25 22:04:41 +00:00
Philippe Normand
ac88851587 validate: launcher: Simplify fakesink handling
Now the function returns either a fakeaudiosink or a fakevideosink, depending on
the media type.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-devtools/-/merge_requests/246>
2021-05-25 10:46:47 +00:00
He Junyan
c4bb5f06c9 va: h265dec: Add current picture into reference list for SCC.
The current picture is not in the DPB, so we need to add it manually
to the reference list when SCC is enabled.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2255>
2021-05-25 12:11:05 +02:00
He Junyan
ceb2df1751 va: h265dec: Set Screen Content extension (SCC) for picture parameters.
We already declare the support of HEVC screen content extension profiles
in the profile mapping list, but we fail to generate the correct VA picture
parameters buffers. This may cause the GPU hang.

We need to fill the buffer of VAPictureParameterBufferHEVCExtension correctly.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2255>
2021-05-25 12:11:05 +02:00
He Junyan
bfbb49144c va: h265dec: Use get_profile_from_sps() to recognize the profile.
The function of gst_h265_get_profile_from_sps() is better than the
function gst_h265_profile_tier_level_get_profile() when we recognize
the profile of the stream, becaue it considers the compatibility.

It is also used by h265parse to recognize the profile. So it is
better to keep the same behaviour with the parse and other decoders.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2255>
2021-05-25 12:11:05 +02:00
He Junyan
08dc70b6f4 va: h265dec: Set range extension for picture and slice parameters.
We already declare the support of HEVC range extension profiles in
the profile mapping list, but we fail to generate the correct VA
picture and slice parameters buffers. This may cause the GPU hang.

We need to fill the buffer of VAPictureParameterBufferHEVCExtension
and VASliceParameterBufferHEVCExtension correctly.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2255>
2021-05-25 12:11:05 +02:00
Víctor Manuel Jáquez Leal
0edc2f6b98 va: h265dec: Use picture and slide extension parameters.
This is transitional commit to later implement extended and screen
profiles.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2255>
2021-05-25 12:11:05 +02:00
Tim-Philipp Müller
8e04651b8b Use gst_buffer_new_memdup()
Update for function rename in core.

https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/827

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2281>
2021-05-24 19:05:27 +01:00
Tim-Philipp Müller
dd22ec68d2 buffer: rename new gst_buffer_new_copy() to gst_buffer_new_memdup()
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/826

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/827>
2021-05-24 19:01:58 +01:00
Tim-Philipp Müller
a5b30f179b rtsp-stream: use new gst_buffer_new_memdup()
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-rtsp-server/-/merge_requests/208>
2021-05-24 18:58:00 +01:00
Seungha Yang
a3c662b2e3 meson: Fix build error caused by missing rtp dep
Missing RTP dep causes build error on Windows
webrtc-sendrecv.c.obj : error LNK2019: unresolved external symbol
  __imp_gst_rtp_header_extension_set_id referenced in function start_pipeline
webrtc-sendrecv.c.obj : error LNK2019: unresolved external symbol
  __imp_gst_rtp_header_extension_create_from_uri referenced in function start_pipeline

... and match required GStreamer to gst-example project version

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-examples/-/merge_requests/40>
2021-05-25 00:36:29 +09:00
Sebastian Dröge
0b6cd6862e compositor: Consider the converter-config when deciding whether one pad obscures another
If the converter configuration is set to not fill any borders, or if the
border fill color is not full opaque, then the pad has to be handled
as potentially transparent and can't be considered to obscure another
one.

This prevents pads from being wrongly skipped and doing alpha-blending
with uninitialized memory.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1172>
2021-05-24 14:28:49 +03:00
Philippe Normand
a0b37e9d1a wpe: Bump wpebackend-fdo version requirement to 1.8
Debian bullseye has this version already, and this allows us to get rid of many
ifdefs. The mouse scroll handling is actually functional now as well.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2278>
2021-05-23 17:18:20 +00:00
Tim-Philipp Müller
0151276d7f Use new gst_buffer_new_copy()
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2279>
2021-05-23 17:20:16 +01:00
Tim-Philipp Müller
80966ed0a3 wavparse: use g_strndup() for copying text data
So we don't rely on NUL terminators inside the data.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/994>
2021-05-23 15:20:16 +01:00
Tim-Philipp Müller
5353ff355f wavparse: clean up adtl/note/labl chunk parsing
We were passing the size of the adtl chunk to the note/labl
sub-chunk parsing function, which means we may memdup lots of
data after the chunk string's NUL terminator that doesn't
really belong to it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/994>
2021-05-23 15:19:41 +01:00
Tim-Philipp Müller
3dd8de1d7c wavparse: guard against overflow when comparing chunk sizes
Could be rewritten as lsize > (size - 8) a well, but the
extra check seems clearer. Doesn't look like it was problematic,
lsize wasn't actually used when parsing the sub-chunks.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/994>
2021-05-23 15:17:27 +01:00
Tim-Philipp Müller
04fe2233f0 buffer: add gst_buffer_new_copy() convenience function
More convenient and discoverable variant of the fairly widely-used
gst_buffer_new_wrapped(g_memdup(data,size),size).

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/826>
2021-05-23 07:32:09 +00:00
Nicolas Dufresne
07fe3289bc doc: Update cache for AV12 pixel format
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1152>
2021-05-21 21:16:24 -04:00
Nicolas Dufresne
0df31ae9d4 video: Update video-orc-dist
This adds the new symbols needed for AV12 support.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1152>
2021-05-21 21:16:24 -04:00
Daniel Almeida
3a3385f35c gl: add support for AV12
AV12 is an internally conceived format that is actually the
combination of NV12 and an alpha plane.

This format is to add to gstreamer's webM transparency support for
vp8 and vp9. To this end, two I420 streams are independently decoded
simultaneously for the actual content and the alpha plane respectively
and these are then combined into A420.

This patch adds GL conversion support so that it is possible to convert
from AV12 to RGBA for the purposes of rendering it on a display.

The reverse conversion is also supplied.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1152>
2021-05-21 21:16:24 -04:00
Daniel Almeida
6760c7fd76 video: add support for AV12
AV12 is an internally conceived format that is actually
the combination of NV12 and an alpha plane.

This format is to add to gstreamer's webM
transparency support for vp8 and vp9. To this end, two
I420 streams are independently decoded simultaneously for
the actual content and the alpha plane respectively
and these are then combined into A420.

Since most hardware decoders output NV12, this patch adds
NV12+A to make the same workflow possible.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1152>
2021-05-21 21:16:24 -04:00
Daniel Almeida
038ba1bffe video: video-orc: remove trailing spaces
Remove unnecessary trailing spaces at the end of some orc functions.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1152>
2021-05-21 21:16:24 -04:00
Daniel Almeida
87d97f01f5 doc: update gst_plugins_cache.json
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1152>
2021-05-21 21:06:38 -04:00
Thibault Saunier
712f3d32d4 uriclip: Add an error message when creating a clip failed
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-editing-services/-/merge_requests/252>
2021-05-21 21:26:19 +00:00
Thibault Saunier
cb4dab37a1 examples: c: Sensibly simplify the simple example
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-editing-services/-/merge_requests/252>
2021-05-21 21:26:19 +00:00
Thibault Saunier
b24d1918f8 examples: python: Simplify the simple example
We shouldn't show assets usage in the simplest example we have
as it is useful for more advanced use cases.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-editing-services/-/merge_requests/252>
2021-05-21 21:26:19 +00:00
Thibault Saunier
7f17367ce5 tests: Update expectation files with sorted structure fields 2021-05-21 17:11:14 -04:00
Thibault Saunier
4188959a79 tests: Update expectation files with sorted structure fields 2021-05-21 17:10:07 -04:00
Daniel Almeida
4f2189a6e1 doc: update gst_plugins_cache.json
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/991>
2021-05-21 16:42:04 -04:00
Thibault Saunier
d77d5669d4 meson: Fix the name of the sdp_deps variable
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1167>
2021-05-21 18:54:22 +00:00
Jakub Adam
fa05f19f14 dxgiscreencapsrc: renegotiate caps on resolution change
When desktop gets resized, recreate the textures and renegotiate the
source caps with the updated video dimensions.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2249>
2021-05-21 17:03:20 +02:00
Philippe Normand
6691cd4687 tests/check: Use fake{audio,video}sink
The tests already depend on -bad, so this should be OK.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-editing-services/-/merge_requests/254>
2021-05-21 14:44:12 +01:00
Philippe Normand
df2cb6104a launcher: Switch to fake{audio,video}sink
Simplifies the code a bit, though introducing runtime dependency on -bad.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-editing-services/-/merge_requests/254>
2021-05-21 14:38:36 +01:00
He Junyan
3bca4045e5 va: h265dec: Set LastSliceOfPic for multi sliced frames.
VA-API HEVC decoding needs to known which is the last slice of a
picture, but slices are processed sequencially, so we know the
last slice until all the slices are already pushed into the
VABuffer array.

In order to mark the last slice, they are pushed into the
VABuffer array with a delay of one slice: the first slice is
hold, and when the second slice come, the first one is pushed
while holding the second, and so on. Finally, at end_picture(),
the last slice is marked and pushed into the array.

Co-author: Victor Jaquez <vjaquez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2246>
2021-05-21 13:22:03 +02:00
Víctor Manuel Jáquez Leal
7a25c5d4ec vaapi: Demote vaapidecodebin to rank NONE.
One of the main reasons of vaapidecodebin was because it mitigated the
possible surface exhaustion. But that problem is currently
solved. Nowadays, vaapidecodebin brings more problems than it
solves. Thus this patch demotes vaapidecodebin to NONE rank while
bumping PRIMARY + 1 the most common decoders.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/426>
2021-05-21 09:36:26 +00:00
Matthew Waters
512160a1c8 gl/context/wgl: implement a better get_proc_address()
Look in opengl32.dll first, then wglGetProcAddress(), and only then
possibly from any linked in libraries.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1165>
2021-05-21 14:12:11 +10:00
Matthew Waters
f8510ae3c8 gl/context: add opengl32.dll as a library to dlopen() on windows
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1165>
2021-05-21 14:12:11 +10:00
Tim-Philipp Müller
a983bea1a9 overlaycomposition: fix cut-off example code in docs
Include everything to the end.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/1164>
2021-05-21 00:36:10 +01:00