Víctor Manuel Jáquez Leal [Wed, 29 Mar 2023 10:44:00 +0000 (12:44 +0200)]
tests: vkimage: add VK_IMAGE_USAGE_SAMPLED_BIT usage bit
Running tests with Vulkan Validation enabled show an error on vkimage tests:
Code 0 : Validation Error: [ VUID-VkImageViewCreateInfo-image-04441 ]
Object 0: VK_NULL_HANDLE, type = VK_OBJECT_TYPE_COMMAND_BUFFER; Object 1: handle
= 0x50000000005, type = VK_OBJECT_TYPE_IMAGE;
| MessageID = 0xb75da543
| Invalid usage flag for VkImage 0x50000000005[] used by vkCreateImageView(). In
this case, VkImage should have VK_IMAGE_USAGE_SAMPLED_BIT |
VK_IMAGE_USAGE_STORAGE_BIT | VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT |
VK_IMAGE_USAGE_DEPTH_STENCIL_ATTACHMENT_BIT |
VK_IMAGE_USAGE_TRANSIENT_ATTACHMENT_BIT | VK_IMAGE_USAGE_INPUT_ATTACHMENT_BIT |
VK_IMAGE_USAGE_FRAGMENT_SHADING_RATE_ATTACHMENT_BIT_KHR |
VK_IMAGE_USAGE_FRAGMENT_DENSITY_MAP_BIT_EXT |
VK_IMAGE_USAGE_VIDEO_DECODE_DST_BIT_KHR |
VK_IMAGE_USAGE_VIDEO_DECODE_DPB_BIT_KHR |
VK_IMAGE_USAGE_VIDEO_ENCODE_SRC_BIT_KHR |
VK_IMAGE_USAGE_VIDEO_ENCODE_DPB_BIT_KHR | VK_IMAGE_USAGE_SAMPLE_WEIGHT_BIT_QCOM
| VK_IMAGE_USAGE_SAMPLE_BLOCK_MATCH_BIT_QCOM set during creation.
The Vulkan spec states: image must have been created with a usage value
containing at least one of the usages defined in the valid image usage list for
image views
This patch adds VK_IMAGE_USAGE_SAMPLED_BIT to the usage bits in test.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4311>
Víctor Manuel Jáquez Leal [Wed, 29 Mar 2023 09:04:20 +0000 (11:04 +0200)]
vkfullscreenquad: set enable_clear as TRUE by default
While using the validation layer with this pipeline:
gst-launch-1.0 videotestsrc num-buffers=10 ! vulkanupload ! vulkancolorconvert ! vulkansink
The validation layer throws this message:
Code 0 : Validation Error: [ VUID-VkAttachmentDescription-format-06699 ]
Object 0: handle = 0x5555562e9610, type = VK_OBJECT_TYPE_DEVICE; | MessageID = 0x52b3229e |
vkCreateRenderPass: pCreateInfo->pAttachments[0] format is
VK_FORMAT_B8G8R8A8_UNORM and loadOp is VK_ATTACHMENT_LOAD_OP_LOAD, but
initialLayout is VK_IMAGE_LAYOUT_UNDEFINED.
The Vulkan spec states: If format includes a color or depth aspect and loadOp is
VK_ATTACHMENT_LOAD_OP_LOAD, then initialLayout must not be VK_IMAGE_LAYOUT_UNDEFINED
When creating the render pass the loadOp can be either
`VK_ATTACHMENT_LOAD_OP_CLEAR` or `VK_ATTACHMENT_LOAD_OP_LOAD` depending on
`enable_clear`. While `enable_clear` is FALSE by default (which means
`VK_ATTACHMENT_LOAD_OP_LOAD`). Nonetheless, its value is explicitly changed by
`vkoverlaycompositor` to FALSE too!
This behavior was introduced in merge request #2470 where
`VK_ATTACHMENT_LOAD_OP_CLEAR` was a fixed value for loadOp. Thus, the bug
consists in a missing initialization of `enable_clear` to TRUE from that merge
request.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4311>
Matthew Waters [Mon, 27 Mar 2023 05:28:04 +0000 (16:28 +1100)]
vulkanswapper: correctly handle force-aspect-ratio=false
It was simply ignored so actually handle it.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4290>
Stéphane Cerveau [Mon, 13 Feb 2023 11:05:27 +0000 (12:05 +0100)]
openjpegdec: allow multithread decoding only in subframe mode
To avoid mis-ordered frames, allow multithread decoding only in
subframe mode.
Fixes #1786
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4275>
Sebastian Dröge [Fri, 24 Mar 2023 16:34:36 +0000 (18:34 +0200)]
datetime: Return G_MAXFLOAT instead of G_MAXDOUBLE for no timezone offset
Returning G_MAXDOUBLE from a function returning a float is not going to
work well and MSVC also correctly warns about this.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4285>
Haihua Hu [Mon, 27 Mar 2023 03:18:09 +0000 (11:18 +0800)]
decodebin3: fix hang issue when remove failing stream
Need mark selection_update to true when update selection,
otherwise, pipeline will not handle this selection update
sometimes when this flag has been reset
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4284>
Tim-Philipp Müller [Thu, 23 Mar 2023 16:40:54 +0000 (16:40 +0000)]
rtpjpegdepay: fix logic error when checking if an EOI is present
We wouldn't add the missing EOI marker if the frame ended with
either 0xFF NN or 0xNN D9.
Fixes #2407
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4269>
Seungha Yang [Thu, 23 Mar 2023 15:23:42 +0000 (00:23 +0900)]
d3d11bufferpool: Fix invalid access in debug print loop
Add missing condition check in for loop
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4258>
Seungha Yang [Tue, 21 Mar 2023 11:06:12 +0000 (20:06 +0900)]
nvh264encoder: Fix template caps
It should include progressive as well
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4253>
Piotr Brzeziński [Mon, 20 Mar 2023 15:35:45 +0000 (16:35 +0100)]
qtdemux: Fix seek adjustment with SNAP_AFTER flag
With GST_SEEK_FLAG_SNAP_AFTER present, the previous version would
adjust seek time based on the keyframe farthest away from desired_time.
This was incorrect, because we always want the *earliest* suitable keyframe
to seek to, not the last one.
With this fix, in case of the SNAP_AFTER, we now look for the closest keyframe
that can be found after desired_time. Behaviour for SNAP_BEFORE should remain
unchanged.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4251>
Michael Tretter [Tue, 31 Jan 2023 15:02:03 +0000 (16:02 +0100)]
v4l2object: mark jpeg as parsed
Assuming that V4L2 CAPTURE devices always use one buffer per JPEG image, we can
always mark JPEGs provided by a V4L2 element as parsed.
The V4L2 elements require that JPEG images sent to V4L2 OUTPUT devices must
always be parsed.
This is necessary to link a V4L2 CAPTURE device with a V4L2 OUTPUT device
without explicitly marking the stream as parsed or adding a jpegparse into the
pipeline.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4247>
Colin Kinloch [Mon, 20 Mar 2023 17:44:23 +0000 (17:44 +0000)]
gtkwaylandsink: Fix crash when rendering after the window is closed
Continuation of https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4197
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4238>
Edward Hervey [Mon, 20 Mar 2023 15:16:34 +0000 (16:16 +0100)]
parsebin: Improve elementary stream handling
The goal of parsebin is to figure out which elements to link together in order
to provide elementary streams given any random input.
The problem is that deciding whether a given stream should still have more
elements plugged in or not was dependent on ... the presence of compatible
decoders (sic).
Instead of that, if we can't plug anymore elements on a given stream *and* it is
detected as being an elementary stream, expose it.
Fixes #2118
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4237>
Edward Hervey [Mon, 20 Mar 2023 10:53:35 +0000 (11:53 +0100)]
urisourcebin: Activate pad before transferring sticky events
Otherwise they get refused since the pad is flushing
Fixes #2384 for good
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4233>
Adrien De Coninck [Sun, 19 Mar 2023 20:21:31 +0000 (21:21 +0100)]
ksdeviceprovider: Fix leak in gst_dshow_device_provider_start
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4227>
Adrien De Coninck [Sun, 19 Mar 2023 19:57:18 +0000 (20:57 +0100)]
dshowdeviceprovider: Fix leak in gst_dshow_device_provider_start
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4227>
Sebastian Dröge [Fri, 17 Mar 2023 15:13:39 +0000 (17:13 +0200)]
matroskademux: Make gst_byte_reader_get_data() usage less confusing
This is effectively the same behaviour but retrieving 0 bytes of data is
confusing to read.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4221>
Sebastian Dröge [Fri, 17 Mar 2023 14:48:51 +0000 (16:48 +0200)]
flacenc: Fix mapping of GStreamer image tag type to FLAC image tag type
These enums are not compatible so just casting them does not work.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4221>
Sebastian Dröge [Fri, 17 Mar 2023 14:32:45 +0000 (16:32 +0200)]
plugins: Fix various trivial clang compiler warnings
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4221>
Sebastian Dröge [Fri, 17 Mar 2023 13:51:53 +0000 (15:51 +0200)]
tsdemux: Fix reading of extended Opus channel configuration
Argument evaluation order is implementation defined in C, and gcc is
evaluating right-to-left (works) while clang is evaluating left-to-right
(does not work).
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4221>
Seungha Yang [Fri, 17 Mar 2023 14:28:58 +0000 (23:28 +0900)]
h264decoder: Fix DPB bumping process
As per spec C.4.5.3 "Bumping", if bumping is needed but DPB holds
no "output needed" picture, then a picture that has the smallest
POC should be considered first for output
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4219>
Edward Hervey [Fri, 17 Mar 2023 08:58:55 +0000 (09:58 +0100)]
urisourcebin: Propagate sticky events from parsebin
If sticky events are present on parsebin source pads, we propagate them to the
multiqueue source pads. Those will be propagated on the new urisourcebin source
pads like in the other code paths.
This ensures that STREAM_START event are present on new source pads. If CAPS
event are also present (not guaranteed), they will also be available.
Fixes #2384
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4218>
Seungha Yang [Fri, 17 Mar 2023 16:33:20 +0000 (01:33 +0900)]
nvencoder: Fix CQP option setting
... and zero initialize LUID and CUDA device list to address
coverity issue
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4217>
Albert Sjölund [Thu, 16 Mar 2023 12:33:46 +0000 (13:33 +0100)]
webrtc: Fix segfault traversing ice transports
Previously, reassigning loop index l in nicestream.c
could cause a segfault if l->data was null, as it could
reassign l to a null variable, triggering the loop
postassignment l->next, which then segfaults due to
l now being null. It is instead moved into the loop.
_delete_transport already performs the reassignment
inline.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4213>
Seungha Yang [Thu, 16 Mar 2023 14:09:53 +0000 (23:09 +0900)]
wasapi2: Fix potential crash on device activation failure
The activation object is live in COM thread already and therefore
self refcount hack is pointless.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4207>
Albert Sjölund [Thu, 16 Mar 2023 12:25:39 +0000 (13:25 +0100)]
webrtc: patch leak caused by early return
In webrtc_data_channel_send functions, both data and string,
an early return on a non-open datachannel caused it to leak
the buffer used for pushing to appsrc, meaning any buffer
sent after leaving the open state was leaked in full.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4206>
Vivia Nikolaidou [Thu, 16 Mar 2023 10:38:23 +0000 (12:38 +0200)]
inputselector: Wake up streaming thread before PLAYING_TO_PAUSED transition
Also take object lock before iterating the pads.
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1772
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4196>
Seungha Yang [Wed, 15 Mar 2023 13:05:33 +0000 (22:05 +0900)]
d3d11videosink: Fix tearing in case of fullscreen mode
DXGI_SWAP_CHAIN_FLAG_ALLOW_TEARING and DXGI_PRESENT_ALLOW_TEARING should
be used only if required, when user wants Vsync off for example.
Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/2376
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4188>
Seungha Yang [Wed, 15 Mar 2023 15:53:31 +0000 (00:53 +0900)]
d3d11converter: Fix conversion backend selection
Intended behavior was selecting video processor only if pixel shader
is disabled, since we prefer shader over video processor
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4189>
Nicolas Dufresne [Tue, 14 Mar 2023 18:27:39 +0000 (14:27 -0400)]
avviddec: Drop decoder stream lock when calling send_packet
This is already done for every other calls to send_packet. The deadlock occures
since FFMPeg 6.0. The decoder tries to get a buffer from a thread during
the draining process, and blocks trying to get the video decoder stream lock
already heald by the drain function.
Fixes #2383
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4187>
Seungha Yang [Tue, 14 Mar 2023 13:08:54 +0000 (22:08 +0900)]
d3d11compositor: Fix composition error on release_pad()
Composition might be still in progress while it's being released
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4186>
Arun Raghavan [Fri, 10 Mar 2023 18:10:16 +0000 (13:10 -0500)]
matroskamux: Set rate/channels in Opus template caps
For some reason these were missed, and if caps didn't have them, we would emit
an invalid Matroska file with a 0 value for Sampling Frequency or channels.
Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/2354
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4172>
Arun Raghavan [Fri, 10 Mar 2023 17:06:08 +0000 (12:06 -0500)]
rtpopusdepay: Assume 48 kHz if sprop-maxcapturerate is missing
This matches 7587, section 6.1:
> sprop-maxcapturerate: a hint about the maximum input sampling rate
> [...]
> bandwidths (Table 1). By default, the sender is assumed to have
> no limitations, i.e., 48000.
Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/2354
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4172>
Antonio Rojas [Sat, 7 Jan 2023 15:18:03 +0000 (16:18 +0100)]
zxing: add support for zxing-c++ 2.0
format is a C++ string in 2.0
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4148>
Matthew Waters [Fri, 10 Mar 2023 05:47:17 +0000 (16:47 +1100)]
vulkanoverlaycompositor: don't do a potential use after free
Removing a meta from a buffer means one doesn't have access to it
anymore. Instead use the already reffed composition directly.
Fixes a use-after-free in the following pipeline:
... ! vulkanupload ! timeoverlay ! vulkanoverlaycompositor ! ...
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4147>
Matthew Waters [Thu, 9 Mar 2023 03:38:13 +0000 (14:38 +1100)]
cea708overlay: fix HCR interpretation
An unsigned counter with a for (i = end; i >= 0; i--), can be optimized to
infinite loop as an unsigned value will always be >= 0.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4141>
Seungha Yang [Tue, 7 Mar 2023 14:46:50 +0000 (23:46 +0900)]
h264parse: Validate VUI framerate
A few streams contain invalid/wrong framerate in VUI. Do validate
it based on the spec and ignore invalid VUI framerate values.
Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1753
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4131>
Víctor Manuel Jáquez Leal [Tue, 28 Feb 2023 17:48:24 +0000 (18:48 +0100)]
jpegparse: demote and promote log messages level
Before those levels where when implementing the plugin. Now these
levels are for reporting issues from users.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4130>
He Junyan [Sun, 12 Feb 2023 14:37:01 +0000 (22:37 +0800)]
jpegparse: reset parse state when the SOI is not the first marker
There may be garbage or some bits before a SOI comes in some problematic
mjpeg streams. For example, some network error may cause the EOI marker
of the previous frame lost, and when the new frame's SOI comes, we still
use the state of the last frame, which will generate errors.
For this kind of frames without EOI, if that frame already has some data
(the SOS segment is detected), we still push it as a frame with CORRUPTED
flag set. But if not, we just discard all the data before the new SOI.
Co-Authored-By: Víctor Jáquez <vjaquez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4130>
Matt Feury [Mon, 6 Mar 2023 19:56:08 +0000 (19:56 +0000)]
rtspsrc: Consider "451: Parameter Not Understood" when handling broken control urls
similar to https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3854
it seems that some implementations return this when
the server does not implement URL handling correctly
this fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/2334
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4129>
Tim-Philipp Müller [Sat, 4 Mar 2023 16:13:04 +0000 (16:13 +0000)]
Back to development
Tim-Philipp Müller [Sat, 4 Mar 2023 13:42:32 +0000 (13:42 +0000)]
Release 1.22.1
Piotr Brzeziński [Thu, 23 Feb 2023 13:14:57 +0000 (14:14 +0100)]
vtdec: Correctly retrieve reorder queue length from SPS
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4110>
Nicolas Beland [Wed, 1 Mar 2023 21:26:20 +0000 (16:26 -0500)]
alsasink: Fix stall when going from PLAYING to NULL (stucked at PAUSED) with uac1 gadget
This happened with a uac1 gadget which for some reason does not behave nicely.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4104>
Edward Hervey [Fri, 3 Mar 2023 07:21:08 +0000 (08:21 +0100)]
adaptivedemux2: Fix buffering treshold initialization
Properly initialize the stream default recommended buffering threshold so that
a default (10s) value is used until the subclass can provide a proper value
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/2064
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4105>
Vivia Nikolaidou [Thu, 2 Mar 2023 13:51:08 +0000 (15:51 +0200)]
inputselector: Avoid deadlock when shutting down
Transition from PLAYING to PAUSED unschedules any pending clock wait,
but there was no guard that prevented another input buffer then waiting
again while in PAUSED before dataflow stops. Use a new `playing` flag to
avoid this, and exit the chain function if instead of playing we're now
flushing. Basically the same as the clocksync element.
Closes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1772
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4099>
Thibault Saunier [Wed, 1 Mar 2023 03:56:51 +0000 (00:56 -0300)]
validate: Protect init function with a recursive mutex
In tests in the rust bindings we end up with 2 thread initializing
concurrently, and it should not be a problem, -validate should be MT
safe.
Using a recursive mutex as we might recursively init for some reason
and we are not on the hot path here in any case.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4097>
Thibault Saunier [Wed, 1 Mar 2023 03:43:01 +0000 (00:43 -0300)]
validate:scenario: sink refs when building
Scenarios are no owned by anyone, even if they are GstObjects
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4097>
Jan Schmidt [Tue, 28 Feb 2023 19:36:15 +0000 (06:36 +1100)]
avfvideosrc: Fix description and trailing whitespace
Minor fix to mention that the element is also useful on MacOS,
and remove some trailing whitespace
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4096>
Jan Schmidt [Tue, 28 Feb 2023 19:32:19 +0000 (06:32 +1100)]
avfvideosrc: Don't wait on main thread for permissions request
Recursively invoking the NSMainLoop can cause crashes in
applications that don't expect it. Instead of waiting for
permission to be granted, move the wait later - until we
actually need device permissions when starting the capture
session. That moves the wait into the streaming thread
instead of the application thread that's setting the pipeline
state to READY.
Instead of a manual state change implementation to open
and close the device, use the basesrc start/stop methods that
are intended for the purpose.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4096>
Frank Dana [Fri, 9 Sep 2022 04:21:12 +0000 (04:21 +0000)]
python: Use arch-specific install dir
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4093>
Carlos Falgueras García [Mon, 27 Feb 2023 07:23:38 +0000 (08:23 +0100)]
gldisplay: Remove unused code
The code related with environment variable `GST_GL_PLATFORM` is unused
since commit
33c60bdbf9ae2fd2e88099ad89ad836b8b78c2f5.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4091>
Piotr Brzeziński [Tue, 28 Feb 2023 14:26:45 +0000 (15:26 +0100)]
vtenc: Fix checking for certain CPU variants when running in VMs
These checks were introduced to prevent exposing ARGB64/RGBA64 in the caps
when running on M1 Pro/Max with macOS <13 because of a bug in VideoToolbox.
Unfortunately, the initial buffer size of 15 is too short when running
in a VM - the CPU brand string there looks like "Apple M1 Pro (Virtual)",
which due to its length causes sysctlbyname to return -1, resulting in
broken formats still showing up in the caps.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4082>
Sebastian Dröge [Tue, 28 Feb 2023 12:00:26 +0000 (14:00 +0200)]
ffmpeg: avauddec/avviddec: Free packet side data after usage
As we don't use proper refcounting with AVPacket we have to manage this
ourselves.
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/2006
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4078>
Seungha Yang [Fri, 27 Jan 2023 17:32:13 +0000 (02:32 +0900)]
tools: Make sure UTF-8 encoded command line arguments on Windows
On Windows, arguments passed in main() are system codepage
encoded and might not be valid UTF-8 string.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4072>
Seungha Yang [Sun, 19 Feb 2023 18:20:46 +0000 (03:20 +0900)]
nvencoder: Fix b-frame encoding on Linux
On Windows, Win32 event handle is used to wait for encoded output,
but it's not available on Linux. We should delay bitstream locking
if encoder returns "need-more-input"
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4008>
Jordan Petridis [Fri, 24 Feb 2023 13:28:48 +0000 (15:28 +0200)]
ci: prepare_cerbero_env: Use predictable git clone path
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4069>
Jordan Petridis [Fri, 24 Feb 2023 12:29:34 +0000 (14:29 +0200)]
meson: Switch dav1d wrap to a tarball
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4069>
Seungha Yang [Tue, 21 Feb 2023 15:47:09 +0000 (00:47 +0900)]
h265parse: Always set profile on src caps
h265parse should provide profile for autoplugging
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4068>
James Hilliard [Wed, 22 Feb 2023 03:13:57 +0000 (20:13 -0700)]
buffer: fix copy meta reference debug log formatting
Fixes the following valgrind error:
==616== Conditional jump or move depends on uninitialised value(s)
==616== at 0x4900E34: gst_debug_print_object (gstinfo.c:1143)
==616== by 0x49010B6: gst_info_printf_pointer_extension_func (gstinfo.c:1215)
==616== by 0x4959FDB: __gst_printf_pointer_extension_serialize (printf-extension.c:47)
==616== by 0x495A487: printf_postprocess_args (vasnprintf.c:258)
==616== by 0x495A52C: __gst_vasnprintf (vasnprintf.c:290)
==616== by 0x4959F8F: __gst_vasprintf (printf.c:154)
==616== by 0x4901C1F: gst_debug_message_get (gstinfo.c:791)
==616== by 0x4901C75: _gst_debug_log_preamble (gstinfo.c:1431)
==616== by 0x4903208: gst_debug_log_default (gstinfo.c:1575)
==616== by 0x49020BA: gst_debug_log_full_valist (gstinfo.c:624)
==616== by 0x490211D: gst_debug_log_valist (gstinfo.c:656)
==616== by 0x49021AD: gst_debug_log (gstinfo.c:533)
==616== by 0x48DDC11: gst_buffer_copy_into (gstbuffer.c:693)
==616== by 0x48DF5F1: gst_buffer_copy_with_flags (gstbuffer.c:727)
==616== by 0x48DF640: gst_buffer_copy_deep (gstbuffer.c:756)
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4038>
He Junyan [Fri, 24 Feb 2023 13:58:00 +0000 (21:58 +0800)]
jpegdecoder: fail early if no input caps have been provided
The jpegdecoder class does not implement the ->parse() virtual function,
and we always need to add the jpegparse element before it. So we should
set_needs_format of the decoder to TRUE, then if no parse before it, it
can fail with a "not-negotiated" error early, rather than go on and
generate unexpected error.
Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1829
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4066>
He Junyan [Fri, 24 Feb 2023 13:49:27 +0000 (21:49 +0800)]
av1decoder: fail early if no input caps have been provided
The av1decoder class does not implement the ->parse() virtual function,
and we always need to add the av1parse element before it. So we should
set_needs_format of the decoder to TRUE, then if no parse before it, it
can fail with a "not-negotiated" error early, rather than go on and
generate unexpected error.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4066>
He Junyan [Fri, 24 Feb 2023 13:38:48 +0000 (21:38 +0800)]
vp9decoder: fail early if no input caps have been provided
The vp9decoder class does not implement the ->parse() virtual function,
and we always need to add the vp9parse element before it. So we should
set_needs_format of the decoder to TRUE, then if no parse before it, it
can fail with a "not-negotiated" error early, rather than go on and
generate unexpected error.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4066>
He Junyan [Fri, 24 Feb 2023 13:27:27 +0000 (21:27 +0800)]
vp8decoder: fail early if no input caps have been provided
The vp8decoder class does not implement the ->parse() virtual function,
it can only accepts frame aligned data. If some element such as filesrc
feed it with unaligned data, the behaviour is undecided. So we should
set_needs_format of the decoder to TRUE, then it can fail with a
"not-negotiated" error early, rather than go on and generate unexpected
error.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4066>
He Junyan [Fri, 24 Feb 2023 13:12:40 +0000 (21:12 +0800)]
mpeg2decoder: fail early if no input caps have been provided
The mpeg2decoder class does not implement the ->parse() virtual function,
and we always need to add the mpegvideoparse element before it. So we should
set_needs_format of the decoder to TRUE, then if no parse before it, it
can fail with a "not-negotiated" error early, rather than go on and
generate unexpected error.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4066>
He Junyan [Fri, 24 Feb 2023 13:09:31 +0000 (21:09 +0800)]
h264decoder: fail early if no input caps have been provided
The h264decoder class does not implement the ->parse() virtual function,
and we always need to add the h264parse element before it. So we should
set_needs_format of the decoder to TRUE, then if no parse before it, it
can fail with a "not-negotiated" error early, rather than go on and
generate unexpected error.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4066>
He Junyan [Fri, 24 Feb 2023 12:15:20 +0000 (20:15 +0800)]
h265decoder: fail early if no input caps have been provided
The h265decoder class does not implement the ->parse() virtual function,
and we always need to add the h265parse element before it. So we should
set_needs_format of the decoder to TRUE, then if no parse before it, it
can fail with a "not-negotiated" error early, rather than go on and
generate unexpected error.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4066>
Robert Rosengren [Fri, 27 Jan 2023 11:45:10 +0000 (12:45 +0100)]
curlhttpsrc: Add curl anyauth option
Add curl anyauth option to support http request to endpoints not using
only basic authentication (as default in curl). Also aligning with
curlhttpsink that already uses this option.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4065>
Patricia Muscalu [Wed, 22 Feb 2023 13:14:15 +0000 (14:14 +0100)]
rtspconnection: Annotate RTSP message parameters correctly
These parameters are not actually `out` parameters but must
be allocated and zero-initialized by the calling function.
Marking them as `out caller-allocates` will cause memory
corruptions when calling these APIs from e.g., Python code.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4061>
Sebastian Dröge [Thu, 23 Feb 2023 09:18:44 +0000 (11:18 +0200)]
rtspsrc: Use the correct vfunc for the `push-backchannel-sample` action signal
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/446
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4056>
Seungha Yang [Wed, 22 Feb 2023 13:18:48 +0000 (22:18 +0900)]
qtmux: Fix assertion on caps update
GstQTMuxPad.configured_caps should be protected since it's
updated from streaming thread and accessed in aggregate thread
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4055>
Tristan van Berkom [Wed, 22 Feb 2023 15:05:56 +0000 (15:05 +0000)]
gstglwindow_x11.c: Fix colormap leak
This fixes an X server side memory leak, this is normally not severe
but in some circumstances where the glwindow is recreated frequently
it can result in a very bad memory leak.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4054>
Célestin Marot [Wed, 22 Feb 2023 14:18:12 +0000 (15:18 +0100)]
d3d11overlaycompositor: fix texture width and height
The dimension of the overlay texture directly corresponds to the size of the overlay **buffer** which is given by its video meta.
The dimension at which the overlay should be displayed directly correspond to the overlay `render_width`and `render_height`.
This match the behavior of glimagesink
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4053>
Tim-Philipp Müller [Wed, 22 Feb 2023 11:52:38 +0000 (11:52 +0000)]
gst-plugins-bad: update translations
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4041>
Tim-Philipp Müller [Wed, 22 Feb 2023 11:52:21 +0000 (11:52 +0000)]
gst-plugins-good: update translations
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4041>
Tim-Philipp Müller [Wed, 22 Feb 2023 11:52:14 +0000 (11:52 +0000)]
gst-plugins-base: update translations
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4041>
Tim-Philipp Müller [Wed, 22 Feb 2023 11:51:58 +0000 (11:51 +0000)]
gstreamer: update translations
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4041>
Mengkejiergeli Ba [Thu, 16 Feb 2023 07:03:25 +0000 (15:03 +0800)]
vaallocator: Check return value from va_sync_surface
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4007>
Mengkejiergeli Ba [Thu, 9 Feb 2023 08:54:16 +0000 (16:54 +0800)]
va: Fix some code defects
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4007>
Tim-Philipp Müller [Tue, 21 Feb 2023 18:42:57 +0000 (18:42 +0000)]
gst-play: update translated string
Make it more consistent with the other option descriptions.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4033>
Sebastian Dröge [Thu, 2 Feb 2023 14:48:05 +0000 (16:48 +0200)]
qtmux: Implement writing of `av1C` version 1 box
Version 0 is ancient and not specified in any documents. Take it
directly from the `codec_data` if presents or otherwise try to construct
a reasonably looking `av1C` box.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4027>
Sebastian Dröge [Thu, 2 Feb 2023 14:28:47 +0000 (16:28 +0200)]
qtdemux: Drop av1C version 0 parsing and implement version 1 parsing
The av1C box is optional so dropping parsing does not break anything
fundamentally, and there seems to be no historical record how version 0
even looks like while the comments and the parsing disagreed with each
other.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4027>
Philippe Normand [Thu, 22 Dec 2022 10:17:42 +0000 (10:17 +0000)]
wpe: Logging fixes for the WebExtension
Using logging macros without a `GST_CAT_DEFAULT` in scope leads to critical
warnings.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4022>
Sebastian Dröge [Thu, 19 Jan 2023 16:49:17 +0000 (18:49 +0200)]
appsrc: Don't chain up `BaseSrc::negotiate()`
If we have caps then we can only set exactly those caps, if we have no
caps yet then negotiating anything is not very meaningful because the
caps are defined by the application and not downstream.
Avoids, among other things, an unnecessary allocation query and spurious
useless caps being set before the first buffer.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4020>
Edward Hervey [Thu, 9 Feb 2023 16:23:55 +0000 (17:23 +0100)]
gst-play: Don't force accurate seeking
This crept in several years ago sadly :(
The usage of accurate seeking should be reserved to use-cases where it is
essential that we seek to that position. This should not be the default.
There is a new option `--acurate-seeks/-a` to be able to force that.
Furthermore, if accurate seeks aren't required, a player should be using the
GST_SEEK_FLAG_KEY_UNIT flag to seek to the closest keyframe and provide the most
reactive experience.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4017>
Thibault Saunier [Tue, 31 Jan 2023 16:21:48 +0000 (13:21 -0300)]
uridecodebin: Set source element to READY before querying it
Generating the source element is done when uridecodebin is doing the
READY to PAUSED state change, so it is reasonable to set the new source
element to that state.
This also allows detecting early failures with backing libraries or
hardware (checks done in NULL->READY).
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4016>
Matthew Waters [Tue, 21 Feb 2023 04:19:35 +0000 (15:19 +1100)]
ccconverter: don't debug a potentially freed filter caps
Fixes a use-after-free
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4013>
Seungha Yang [Mon, 20 Feb 2023 15:27:27 +0000 (00:27 +0900)]
d3d11videosink: Fix rendering on external handle
Partial revert of the commit
068a5c1053ae05b3c7747243948447e764d25aa6.
That introduced size mismatch between internal and external HWND
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4010>
Víctor Manuel Jáquez Leal [Sun, 19 Feb 2023 11:01:59 +0000 (12:01 +0100)]
vah265enc: Use helper to update properties.
This is a continuation of the original patch by
Mengkejiergeli Ba <mengkejiergeli.ba@intel.com>
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4009>
Mengkejiergeli Ba [Tue, 14 Feb 2023 02:29:00 +0000 (10:29 +0800)]
av1parser, h265parser: Fix some code defects
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4003>
Jan Schmidt [Mon, 6 Feb 2023 17:58:04 +0000 (04:58 +1100)]
webrtc: Calculate the jitter for remote-inbound-rtp stats
Populate the clock-rate in the internal stats structure, so
it can be used by the _get_stats_from_remote_rtp_source_stats()
method to calculate remote receivers' jitter.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3994>
Jan Schmidt [Tue, 31 Jan 2023 23:44:26 +0000 (10:44 +1100)]
webrtcbin: Report full codec-stats for source pads
Use the current caps for webrtcbin srcpads, as received_caps
are only stored for sink pads based on incoming caps events.
Makes it so that webrtcbin stats reports contain fuller
codec information.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3994>
Yinhang Liu [Fri, 17 Feb 2023 06:56:20 +0000 (14:56 +0800)]
msdkav1enc: fix the category for msdkav1enc debug
The msdkav1enc debug initialized with gst_msdkav1dec_debug,
fix this.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3991>
Enrique Ocaña González [Wed, 1 Feb 2023 11:09:52 +0000 (12:09 +0100)]
qtdemux: Don't emit GstSegment correcting start time when in MSE mode
When using qtdemux in a pipeline that should only work as a pure demuxer (not
for actual playback), qtdemux shouldn't emit new GstSegments to correct
the start time (jump to the future) to ensure that the user experiences no
playback delay. By doing so, it's generating the wrong segments when an append
of data from the past happens. When that happens, downstream elements such as
parsers (eg: aacparse) may clip those buffers laying before the GstSegment and
create problems on the GStreamer client app (eg: WebKit).
Getting buffers clipped out because of the wrong GstSegments started becoming
a problen when this commit was introduced:
ab6e49e9cc audioparsers: add back segment clipping to parsers that have lost it
This clipping makes test DASH shaka 35 from MVT tests[1] to fail in
WebKitGTK/WPE (at least) and can potentially cause a number of other problems
in the WebKit Media Source Extensions (MSE) code.
Note that this new behaviour of not emitting new GstSegments only makes sense
when qtdemux is being used as a pure demuxer and not as part of a regular
pipeline. This is why the variant field has been added. When equal to
VARIANT_MSE_BYTESTREAM, it will make qtdemux behave differently in push mode,
taking decisions that meet the expectations for an MSE-like processing mode.
This kind of tweaks have been done in the past for MSS streams, for instance.
That code has been refactored to use VARIANT_MSS_FRAGMENTED now, instead of
its own dedicated boolean flag.
Co-authored by: Alicia Boya García <ntrrgc@gmail.com>
...who suggested to use "variant: mse-bytestream" in the caps to identify that
mode, as proposed in her unmerged patch:
https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/467
[1] https://github.com/rdkcentral/mvt
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3990>
Thibault Saunier [Thu, 16 Feb 2023 01:06:39 +0000 (22:06 -0300)]
tests: Move srtp test known issue def to the 'check' testuite
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3986>
Thibault Saunier [Thu, 16 Feb 2023 01:05:53 +0000 (22:05 -0300)]
validate:launcher: try to bne more explicit about where to add known failure
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3986>
Thibault Saunier [Thu, 16 Feb 2023 01:02:56 +0000 (22:02 -0300)]
validate:launcher: Handle known return code issue in none validate based tests
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3986>
Seungha Yang [Wed, 15 Feb 2023 16:36:41 +0000 (01:36 +0900)]
codectimestamper: Fix timestamping on sequence update
... and enhance debug logging.
Keep internal timestamp offsets on drain, no reason to reset them
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3987>
Mengkejiergeli Ba [Wed, 15 Feb 2023 01:45:28 +0000 (09:45 +0800)]
codecparsers: {h264,h265}bitwriter: Remove redundant condition checks
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3978>
Tim-Philipp Müller [Tue, 14 Feb 2023 14:43:34 +0000 (14:43 +0000)]
validate: add elements_srtp.test_play_key_error to flaky test list
See https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1777
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3970>