platform/upstream/gst-plugins-base.git
4 years agopbutils: Do not restrict number of similar profiles in a container
Thibault Saunier [Thu, 9 Jul 2020 15:05:35 +0000 (11:05 -0400)]
pbutils: Do not restrict number of similar profiles in a container

We have the notion of presence, and when the user want to be in control
it is totally legitimate for him to have several occurrences of a
similar profile

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/746>

4 years agovideoconverter: Relax frame size checks
Nicolas Dufresne [Thu, 9 Jul 2020 17:13:14 +0000 (13:13 -0400)]
videoconverter: Relax frame size checks

Since we are using VideoMeta, the converter (similarly to the video_frame_copy
utility) should have no issue dealing with frames that are slightly larger.
This situation occure as some element will use padded width/height for
allocation, which results in a VideoMeta width/height being larger then the
display width/height found in the negotiated caps.

Fixes #790

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/747>

4 years agoaudioaggregator: Fix negotiation with downstream if there is no peer yet
Sebastian Dröge [Thu, 9 Jul 2020 09:45:27 +0000 (12:45 +0300)]
audioaggregator: Fix negotiation with downstream if there is no peer yet

get_allowed_caps() will return NULL, which is not a problem in itself.
Just take the template caps for negotiation in that case instead of
erroring out.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/744>

4 years agomeson: set release date from .doap file for releases
Tim-Philipp Müller [Wed, 8 Jul 2020 15:48:30 +0000 (16:48 +0100)]
meson: set release date from .doap file for releases

And fix up DOAP file XML. Parser would complain about
unknown entity &excl; here.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/743>

4 years agopkgconfig: fix gstreamer-plugins-base-1.0 .pc files for no OpenGL case
Tim-Philipp Müller [Wed, 8 Jul 2020 14:15:34 +0000 (15:15 +0100)]
pkgconfig: fix gstreamer-plugins-base-1.0 .pc files for no OpenGL case

Don't put gl into the libraries list if the gst-gl library isn't
being built, and also don't include it in the list of linker flags
then.

Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/issues/613

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/742>

4 years agoglwindow/win32: Fix possible deadlock around key/mouse event handling
Seungha Yang [Thu, 2 Jul 2020 13:33:44 +0000 (22:33 +0900)]
glwindow/win32: Fix possible deadlock around key/mouse event handling

Calling gst_gl_window_send_{key,mouse}_event() from GstGLContext
thread might cause a deadlock. Instead, use the dedicated event handling
thread in GstGLDisplay.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/721>

4 years agoexamples: win32-videooverlay: Add test for fullscreen mode switch
Seungha Yang [Tue, 23 Jun 2020 07:41:31 +0000 (16:41 +0900)]
examples: win32-videooverlay: Add test for fullscreen mode switch

Add test option "--fullscreen" for testing fullscreen mode switch.
When enabled, user can switch fullscreen mode via SPACE key or
right mouse button click.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/721>

4 years agopkgconfig: fix meson warnings about GL_CFLAGS in gstreamer-gl .pc files
Tim-Philipp Müller [Wed, 8 Jul 2020 08:53:42 +0000 (09:53 +0100)]
pkgconfig: fix meson warnings about GL_CFLAGS in gstreamer-gl .pc files

We added GL_CFLAGS in autotools because we unconditionally included OpenGL
headers. We do not do that anymore for a standard #include <gst/gl/gl.h>.
OpenGL headers are only included for the platform specific files
e.g. #include <gst/gl/x11/gstgldisplay_x11.h> which must always be hidden
behind a #if GST_GL_HAVE_WINDOW_X11, or #include <gst/gl/gstglfuncs.h> to
gain access to the contents of the GstGLFuncs object.

Users of our headers must include the necessary include paths for the
platforms they are intending to support.

We might introduce extra .pc files for what GstGL was built against though.

Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/issues/735

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/741>

4 years agoexamples/gl/qt: Don't include GL/glx.h unconditionally
Seungha Yang [Tue, 7 Jul 2020 19:08:33 +0000 (04:08 +0900)]
examples/gl/qt: Don't include GL/glx.h unconditionally

The header file might not be available on non-*nix platform.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/740>

4 years agotests: validate: fix meson warning
Tim-Philipp Müller [Tue, 7 Jul 2020 19:01:33 +0000 (20:01 +0100)]
tests: validate: fix meson warning

meson.build:4: WARNING: Trying to compare values of different types (ExecutableHolder, bool) using ==.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/739>

4 years agodocs: Update cache for removed properties
Edward Hervey [Tue, 7 Jul 2020 12:55:06 +0000 (14:55 +0200)]
docs: Update cache for removed properties

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/738>

4 years agoplayback: Clarify flag usage for playbin3
Edward Hervey [Tue, 7 Jul 2020 08:57:38 +0000 (10:57 +0200)]
playback: Clarify flag usage for playbin3

Forcing software-decoder has no effect on playbin3 now.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/738>

4 years agoRevert "playbin3: handle GST_PLAY_FLAG_FORCE_SW_DECODERS"
Edward Hervey [Tue, 7 Jul 2020 08:52:40 +0000 (10:52 +0200)]
Revert "playbin3: handle GST_PLAY_FLAG_FORCE_SW_DECODERS"

This reverts commit f4bcf8290b3568690dacf0dac95af7f7036f7110.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/738>

4 years agodecodebin3: Only override the selection if needed
Edward Hervey [Thu, 2 Jul 2020 12:25:27 +0000 (14:25 +0200)]
decodebin3: Only override the selection if needed

Whenever a new collection is calculated, the internal `select_streams_seqnum`
variable is reset. This ensures that we reliably know whether a select-streams
event has been received for that new collection.

Use that to decide whether we should add previously un-selected streams or new
streams in the current selection

Fixes #784

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/733>

4 years agoalsadeviceprovider: Rank down to secondary so PulseAudio can hide it
Olivier Crête [Mon, 29 Jun 2020 22:21:23 +0000 (18:21 -0400)]
alsadeviceprovider: Rank down to secondary so PulseAudio can hide it

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/727>

4 years agoUpdate disted generated orc backup files
Tim-Philipp Müller [Sat, 4 Jul 2020 11:13:14 +0000 (12:13 +0100)]
Update disted generated orc backup files

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/734>

4 years agomeson: add update-orc-dist target
Tim-Philipp Müller [Fri, 3 Jul 2020 23:31:49 +0000 (00:31 +0100)]
meson: add update-orc-dist target

Add target to update backup orc -dist.[ch] files.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/734>

4 years agovideo-color.h: fix comment syntax
Mathieu Duponchelle [Fri, 3 Jul 2020 22:39:18 +0000 (00:39 +0200)]
video-color.h: fix comment syntax

4 years agovideo-converter: Make fast path work for equivalent transfer functions
Vivia Nikolaidou [Fri, 26 Jun 2020 09:22:08 +0000 (12:22 +0300)]
video-converter: Make fast path work for equivalent transfer functions

For example, BT709, BT601, and BT2020_10 all have theoretically
different transfer functions, but the same function in practice. In
these cases, we should use the fast path for negotiating. Also,
BT2020_12 is essentially the same as the other three, just with one more
decimal point, so it gives the same result for fewer bits. This is now
also aliased to the former three.

Also make videoconvert do passthrough if the caps have equivalent
transfer functions but are otherwise matching.

As of the previous commit, we write the correct transfer function for
BT601, instead of the (functionally identical but different ISO code)
transfer function for BT709. Files created using GStreamer prior to that
commit write the wrong transfer function for BT601 and are, strictly
speaking, 2:4:5:4 instead. However, this commit takes care of
negotiation, so that conversions from/to the same transfer function are
done using the fast path.

Fixes #783

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/724>

4 years agovideo-color: Add bt601 transfer function
Vivia Nikolaidou [Thu, 25 Jun 2020 17:56:48 +0000 (20:56 +0300)]
video-color: Add bt601 transfer function

Functionally the same as 709 but technically has a different value, and
external software (e.g. ffmpeg) finds "wrong" values produced by
GStreamer.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/724>

4 years agoBack to development
Tim-Philipp Müller [Fri, 3 Jul 2020 01:03:24 +0000 (02:03 +0100)]
Back to development

4 years agoRelease 1.17.2
Tim-Philipp Müller [Thu, 2 Jul 2020 23:24:57 +0000 (00:24 +0100)]
Release 1.17.2

4 years agovideo-anc: Fix gst_buffer_get_video_(afd|bar)_meta
Jan Alexander Steffens (heftig) [Wed, 1 Jul 2020 18:14:57 +0000 (20:14 +0200)]
video-anc: Fix gst_buffer_get_video_(afd|bar)_meta

The macros were not passing the meta GType to gst_buffer_get_meta,
rendering them unusable.

Also, the doc comments were specifying parameters meant for the
add_video_X_meta functions.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/732>

4 years agobasetextoverlay: mark valign and halign props as DOC_SHOW_DEFAULT
Mathieu Duponchelle [Wed, 24 Jun 2020 13:59:03 +0000 (15:59 +0200)]
basetextoverlay: mark valign and halign props as DOC_SHOW_DEFAULT

To document it, we instantiate a subclass and inspect the properties
on the created object. Subclasses (in that case textrender) may
initialize those properties with a different default, we do not
want to expose that in the base class documentation.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/723>

4 years agoaudio: video: Optimize by using cached quark for meta tag
Havard Graff [Fri, 14 Jun 2019 08:14:23 +0000 (10:14 +0200)]
audio: video: Optimize by using cached quark for meta tag

Avoid taking the global quark lock for every single buffer.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/295>

4 years agortpbasedepayload: improve logging around negative gaps
Havard Graff [Thu, 14 May 2020 13:49:54 +0000 (15:49 +0200)]
rtpbasedepayload: improve logging around negative gaps

When warning, it is important that the log will contain information to
help debug the problem. Sequence-numbers are crucial here.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/725>

4 years agoAdded the path property in encoding-target
Ayush Mittal [Fri, 19 Jun 2020 19:07:09 +0000 (00:37 +0530)]
Added the path property in encoding-target

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/714>

4 years agodocs: add GstVisual to plugins cache
Mathieu Duponchelle [Tue, 23 Jun 2020 15:31:52 +0000 (17:31 +0200)]
docs: add GstVisual to plugins cache

4 years agodocs: mark more plugin API
Mathieu Duponchelle [Tue, 23 Jun 2020 00:49:44 +0000 (02:49 +0200)]
docs: mark more plugin API

4 years agodoc: Fix link in tcp multi*sinks.
Thibault Saunier [Tue, 23 Jun 2020 00:10:10 +0000 (20:10 -0400)]
doc: Fix link in tcp multi*sinks.

4 years agoplugins_cache: add base classes
Mathieu Duponchelle [Mon, 22 Jun 2020 22:01:13 +0000 (00:01 +0200)]
plugins_cache: add base classes

4 years agomeson: mark plugins cache target as always stale
Mathieu Duponchelle [Mon, 22 Jun 2020 22:00:40 +0000 (00:00 +0200)]
meson: mark plugins cache target as always stale

4 years agodocs: mark more types as plugin API
Mathieu Duponchelle [Sat, 20 Jun 2020 23:33:50 +0000 (01:33 +0200)]
docs: mark more types as plugin API

4 years agodoc: Stop documenting properties from parents
Thibault Saunier [Sat, 20 Jun 2020 02:49:44 +0000 (22:49 -0400)]
doc: Stop documenting properties from parents

4 years agovideometa: Fix documentation
Seungha Yang [Tue, 23 Jun 2020 16:57:57 +0000 (01:57 +0900)]
videometa: Fix documentation

Fix gst_video_region_of_interest_meta_add_params to
gst_video_region_of_interest_meta_add_param and add newline to be
more readable.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/722>

4 years agoaudiodecoder: Add max-errors property
Sebastian Dröge [Mon, 22 Jun 2020 18:43:44 +0000 (21:43 +0300)]
audiodecoder: Add max-errors property

The number of consecutive decode errors that should be tolerated before
returning flow error should be up to the application, not the element.

Hence max-error should be exposed as a property.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/720>

4 years agovideodecoder: Add max-errors property
Haakon Sporsheim [Mon, 22 Jun 2020 18:36:02 +0000 (21:36 +0300)]
videodecoder: Add max-errors property

The number of consecutive decode errors that should be tolerated before
returning flow error should be up to the application, not the element.

Hence max-error should be exposed as a property.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/720>

4 years agoglwindow/win32: Chain up mouse event to parent window
Seungha Yang [Mon, 22 Jun 2020 10:35:57 +0000 (19:35 +0900)]
glwindow/win32: Chain up mouse event to parent window

Fix a regression of the commit 940c9998e5cfffd90fade8a7f39f29a426e20460

Unlike key event, mouse event will not be chained up to parent window
by DefWindowProc

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/718>

4 years agoDon't call gst_ghost_pad_construct() anymore
Sebastian Dröge [Mon, 22 Jun 2020 09:32:03 +0000 (12:32 +0300)]
Don't call gst_ghost_pad_construct() anymore

It's deprecated, unneeded and doesn't do anything anymore.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/717>

4 years agotools:discoverer: Remove short name for use-cache
Jimmy Ohn [Mon, 22 Jun 2020 03:19:28 +0000 (12:19 +0900)]
tools:discoverer: Remove short name for use-cache

There is no need to add short name for 'use-cache'.
The 'async' option already has 'a' short name.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/716>

4 years agosubparse: lower text buffer threshold
Hosang Lee [Wed, 17 Jun 2020 00:03:51 +0000 (09:03 +0900)]
subparse: lower text buffer threshold

It is possible for subtitle files to have a string length less than 30.
WebVTT for example may contain only the 'WEBVTT' string in the file
without any cues.
As an example in hls streams, since WEBVTT files can be segmented
like video/audio, some subtitle segments may only contain just the
header string.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/708>

4 years agoBack to development
Tim-Philipp Müller [Fri, 19 Jun 2020 23:28:04 +0000 (00:28 +0100)]
Back to development

4 years agoRelease 1.17.1
Tim-Philipp Müller [Fri, 19 Jun 2020 18:16:01 +0000 (19:16 +0100)]
Release 1.17.1

4 years agoFix up and add various "Since" markers and other related docs fixes
Sebastian Dröge [Fri, 19 Jun 2020 09:17:55 +0000 (12:17 +0300)]
Fix up and add various "Since" markers and other related docs fixes

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/713>

4 years agosdp: fix gst_sdp_message_new_from_text() doc
Guillaume Desmottes [Thu, 18 Jun 2020 10:15:57 +0000 (12:15 +0200)]
sdp: fix gst_sdp_message_new_from_text() doc

Arguments were in the wrong order in the doc.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/711>

4 years agotests: validate: Add workaround for older meson versions
Tim-Philipp Müller [Thu, 18 Jun 2020 09:40:14 +0000 (10:40 +0100)]
tests: validate: Add workaround for older meson versions

subproject.get_variable() only has fallback since 0.51

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/710>

4 years agotests: subparse: add test for webvtt without hour component
Hosang Lee [Thu, 18 Jun 2020 00:01:34 +0000 (09:01 +0900)]
tests: subparse: add test for webvtt without hour component

Test for webvtt without hour component.
mm:ss.000

4 years agovideotestsrc: Do not try to answer the duration query before negotiation
Thibault Saunier [Mon, 15 Jun 2020 17:22:38 +0000 (13:22 -0400)]
videotestsrc: Do not try to answer the duration query before negotiation

We have no idea at that moment and this code was trying to divide by 0!

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/705>

4 years agovideo: allow frame copy where destination dimensions are smaller than source
Aaron Boxer [Mon, 15 Jun 2020 13:46:17 +0000 (09:46 -0400)]
video: allow frame copy where destination dimensions are smaller than source

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/695>

4 years agogl/examples/qt: hook up to meson build
Matthew Waters [Fri, 12 Jun 2020 03:04:23 +0000 (13:04 +1000)]
gl/examples/qt: hook up to meson build

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/702>

4 years agovideo-converter: Add checks for configuration sanity.
Jan Schmidt [Fri, 5 Jun 2020 15:22:21 +0000 (01:22 +1000)]
video-converter: Add checks for configuration sanity.

If the cropping or scaling input or output rects put us completely
outside the input/output frame respectively, we can't draw anything
except black safely. Check for those conditions and don't set up a
configuration that attempts to access out of bounds memory outside
the input/output framebuffers.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/696>

4 years agovideo-converter: Guard against invalid frame input
Jan Schmidt [Fri, 5 Jun 2020 13:34:44 +0000 (23:34 +1000)]
video-converter: Guard against invalid frame input

If the frames passed in to gst_video_converter_frame()
have a different layout than was configured for, the
conversion code might go out of bounds and crash.

Do a sanity check on each frame passed in, and in the
absence of a return value in the API, just
refuse the conversion in invalid cases and leave the
destination frame untouched so it's obvious to
users that it was broken.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/696>

4 years agogstglwindow_x11: fix resize
David Bender [Thu, 11 Jun 2020 22:21:56 +0000 (00:21 +0200)]
gstglwindow_x11: fix resize

This patch was taken from #629#note_178766, the comment made
at the time was:

The root issue is a mismatch between the initialization of render_rect
in GstGLWindowX11Private and what's expected in the draw_cb function.
Because render_rect is not explicitly initialized to a width and height
of -1 (unlike gstglwindow_wayland_egl.c which does initialize to -1),
the less-than check for explicitly-set render_rect at gstglwindow_x11.c:453-454
always fails, even when the parent_win has been set and the render rectangle
has never been set.

Maybe this came from copying the similar check in the wayland code? Regardless,
I think the correct inequality should be '<= 0' (on both lines).

Alternatively initialization could be changed, but other sinks, e.g.
xvimagesink don't appear to use -1 to mean "unset" render_rect this way.

The issue can be reproduced by running the example in
tests/examples/gl/qt/videooverlay/ on X11, and resizing the output
window

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/701>

4 years agovideooverlay: chevrons don't need to be escaped in code examples
Mathieu Duponchelle [Thu, 11 Jun 2020 22:17:24 +0000 (00:17 +0200)]
videooverlay: chevrons don't need to be escaped in code examples

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/700>

4 years agodecodebin3: Lower error message to debug
Thibault Saunier [Thu, 11 Jun 2020 20:39:23 +0000 (16:39 -0400)]
decodebin3: Lower error message to debug

Debugging leftover

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/699>

4 years agolibvisual: use gst_element_class_set_metadata when passing dynamic strings
Jordan Petridis [Thu, 11 Jun 2020 17:57:58 +0000 (20:57 +0300)]
libvisual: use gst_element_class_set_metadata when passing dynamic strings

gst_element_class_set_metadata is meant to only be used with
static or inlined strings, which isn't the case for this element
resulting in use-after-free later on.

https://gstreamer.freedesktop.org/documentation/gstreamer/gstelement.html?gi-language=c#gst_element_class_set_static_metadata

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/698>

4 years agomeson: Use the tests option for validate
Nirbheek Chauhan [Thu, 11 Jun 2020 07:46:40 +0000 (13:16 +0530)]
meson: Use the tests option for validate

This is what gstreamer core does too, and avoids a configure error
when tests are disabled globally. Also print a useful error when
gst_tester is not found from the gstreamer subproject.

This broke in https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/667

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/697>

4 years agodocs: Update plugins cache
Thibault Saunier [Tue, 9 Jun 2020 19:18:43 +0000 (15:18 -0400)]
docs: Update plugins cache

4 years agoaudio: add missing space in GST_AUDIO_FORMATS_ALL
Guillaume Desmottes [Wed, 10 Jun 2020 08:43:42 +0000 (10:43 +0200)]
audio: add missing space in GST_AUDIO_FORMATS_ALL

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/694>

4 years agodocs: Update plugins cache
Thibault Saunier [Mon, 8 Jun 2020 14:40:15 +0000 (10:40 -0400)]
docs: Update plugins cache

4 years agovideo: sort formats by quality
Guillaume Desmottes [Thu, 4 Jun 2020 14:40:44 +0000 (16:40 +0200)]
video: sort formats by quality

Will ensure that we pick the "best" format when negotiating caps.

Fix #649

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/689>

4 years agoaudio: sort formats by quality
Guillaume Desmottes [Thu, 4 Jun 2020 14:40:44 +0000 (16:40 +0200)]
audio: sort formats by quality

Will ensure that we pick the "best" format when negotiating caps.

Fix #649

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/689>

4 years agotests: enforce I420 format
Guillaume Desmottes [Fri, 5 Jun 2020 13:26:58 +0000 (15:26 +0200)]
tests: enforce I420 format

Tests are assuming video is I420 but are not actually enforcing it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/689>

4 years agouridecodebin3: Let decodebin do its stream selection if no one answers
Thibault Saunier [Fri, 22 May 2020 04:35:03 +0000 (00:35 -0400)]
uridecodebin3: Let decodebin do its stream selection if no one answers

If no one answers our `select-stream` signal, uridecodebin3 should
behave the same way as `decodebin3` and let decodebin do its own stream
selection.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/666>

4 years agodecodebin3: Avoid overriding explicit user selection
Thibault Saunier [Fri, 22 May 2020 04:32:15 +0000 (00:32 -0400)]
decodebin3: Avoid overriding explicit user selection

In case the user set a list of streams to select or answer explicitly
to all 'select-stream' event, we should respect his choice and not
try to add a stream per type.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/666>

4 years agotests: Avoid hang with decodebin test
Edward Hervey [Mon, 8 Jun 2020 06:11:00 +0000 (08:11 +0200)]
tests: Avoid hang with decodebin test

When adding elements dynamically to a pipeline one should never guess what the
curren/target state is, and instead use `gst_element_sync_state_with_parent()`.

Fixes racy hang when running within valgrind

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/692>

4 years agoplaybin: Fix wrong AV element pair selection when rank is very large value
Seungha Yang [Sat, 6 Jun 2020 11:22:28 +0000 (20:22 +0900)]
playbin: Fix wrong AV element pair selection when rank is very large value

If user set very high rank to an element (e.g., integer max),
integer overflow can happen while multiplication operation

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/690>

4 years agoplugins: uddate gst_type_mark_as_plugin_api() calls
Mathieu Duponchelle [Fri, 5 Jun 2020 22:41:17 +0000 (00:41 +0200)]
plugins: uddate gst_type_mark_as_plugin_api() calls

4 years agovideoencoder: Add test for min-force-key-unit-interval property
Sebastian Dröge [Thu, 4 Jun 2020 13:25:12 +0000 (16:25 +0300)]
videoencoder: Add test for min-force-key-unit-interval property

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/684>

4 years agovideoencoder: Also don't request a new key-unit if we already got one after the reque...
Sebastian Dröge [Thu, 4 Jun 2020 12:19:18 +0000 (15:19 +0300)]
videoencoder: Also don't request a new key-unit if we already got one after the requested running time

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/684>

4 years agovideoencoder: Don't request another keyunit if another one is pending or we requested...
Sebastian Dröge [Thu, 4 Jun 2020 12:10:12 +0000 (15:10 +0300)]
videoencoder: Don't request another keyunit if another one is pending or we requested one for a future time already

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/684>

4 years agovideoencoder: Add min-force-key-unit-interval property
Sebastian Dröge [Wed, 3 Jun 2020 18:46:38 +0000 (21:46 +0300)]
videoencoder: Add min-force-key-unit-interval property

This allows configuring the minimum interval between subsequent
force-key-unit requests and prevents a big bitrate increase if a lot of
key-units are requested.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/684>

4 years agovideoencoder: Add test for correct force-keyunit event handling
Sebastian Dröge [Wed, 3 Jun 2020 17:49:12 +0000 (20:49 +0300)]
videoencoder: Add test for correct force-keyunit event handling

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/684>

4 years agovideoencoder: Fix force-keyunit handling in test
Sebastian Dröge [Wed, 3 Jun 2020 17:26:33 +0000 (20:26 +0300)]
videoencoder: Fix force-keyunit handling in test

This now behaves according to the videoencoder API instead of some other
signalling.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/684>

4 years agovideoencoder: When pushing headers as part of a keyframe mark the first header as...
Sebastian Dröge [Wed, 3 Jun 2020 19:38:07 +0000 (22:38 +0300)]
videoencoder: When pushing headers as part of a keyframe mark the first header as keyframe

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/684>

4 years agovideoencoder: Handle all matching force-keyunit events at once
Sebastian Dröge [Wed, 3 Jun 2020 17:17:06 +0000 (20:17 +0300)]
videoencoder: Handle all matching force-keyunit events at once

Previously we only handled one event at a time, which could lead to the
following two suboptimal situations:
- frame 0 at 20ms, frame 1 at 40ms and two force-keyunit events at 10ms
  and 15ms. We would create a new keyframe for both of the frames.
- 100 force-keyunit events with running-time NONE would cause all
  following 100 frames to be made into a keyframe.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/684>

4 years agovideoencoder: Sort force-keyunit-events by their running time
Sebastian Dröge [Wed, 3 Jun 2020 16:59:03 +0000 (19:59 +0300)]
videoencoder: Sort force-keyunit-events by their running time

That way we can more easily work with the whole list without iterating
over all of the elements.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/684>

4 years agouridecodebin: Dont link random pads
Edward Hervey [Wed, 3 Jun 2020 09:29:09 +0000 (11:29 +0200)]
uridecodebin: Dont link random pads

When linking source pads to decodebin, make sure we use the *specified* new
source pad and not some random one.

This avoids ending up with source pads being unlinked.

Main cause of random timeouts with rtsp change_state_intensive validate tests

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/687>

4 years agovideo-hdr: fix memset warning
Stéphane Cerveau [Thu, 4 Jun 2020 08:41:13 +0000 (10:41 +0200)]
video-hdr: fix memset warning

Fix warning on fedora arm64 target

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/685>

4 years agovideo: Fix NV12_64Z32 number of component
Nicolas Dufresne [Thu, 4 Jun 2020 15:22:00 +0000 (11:22 -0400)]
video: Fix NV12_64Z32 number of component

This format has 3 components, just like NV12.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/686>

4 years agodoc: Add a minimal GstVideoMultiviewFlagsSet documentation
Thibault Saunier [Thu, 4 Jun 2020 00:50:05 +0000 (20:50 -0400)]
doc: Add a minimal GstVideoMultiviewFlagsSet documentation

4 years agodoc: Require hotdoc >= 0.11.0
Thibault Saunier [Wed, 3 Jun 2020 22:38:38 +0000 (18:38 -0400)]
doc: Require hotdoc >= 0.11.0

4 years agodocs: Update gst_plugins_cache.json
Sebastian Dröge [Wed, 27 May 2020 13:00:48 +0000 (16:00 +0300)]
docs: Update gst_plugins_cache.json

4 years agoplugins: Use gst_type_mark_as_plugin_api() for all non-element plugin types
Mathieu Duponchelle [Fri, 29 May 2020 00:43:59 +0000 (02:43 +0200)]
plugins: Use gst_type_mark_as_plugin_api() for all non-element plugin types

4 years agovideoencoder: Simplify header buffer metadata updating
Sebastian Dröge [Wed, 3 Jun 2020 12:06:08 +0000 (15:06 +0300)]
videoencoder: Simplify header buffer metadata updating

Instead of doing a shallow copy of the list just to call make_writable()
on each buffer, do that inline in the same loop and modify the list
contents.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/683>

4 years agovideo: Use GQueue instead of plain GList in a few places
Sebastian Dröge [Wed, 3 Jun 2020 11:37:00 +0000 (14:37 +0300)]
video: Use GQueue instead of plain GList in a few places

Also not optimal but at least simplifies the code a bit and doesn't
require g_list_length() and g_list_append() in a few places.

For 2.0 there are some more candidates to change but unfortunately
they're currently part of the API.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/683>

4 years agovideo-format: RGB16/15 are not 16 bit per component but only 5.333 and 5
Sebastian Dröge [Tue, 2 Jun 2020 13:56:44 +0000 (16:56 +0300)]
video-format: RGB16/15 are not 16 bit per component but only 5.333 and 5

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/682>

4 years agoaudio: add gst_audio_make_raw_caps()
Guillaume Desmottes [Wed, 27 May 2020 13:41:43 +0000 (15:41 +0200)]
audio: add gst_audio_make_raw_caps()

More binding friendly version of GST_AUDIO_CAPS_MAKE().

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/676>

4 years agoaudio-format: remove empty space prefix from GST_AUDIO_FORMATS_ALL
Guillaume Desmottes [Mon, 1 Jun 2020 13:24:32 +0000 (15:24 +0200)]
audio-format: remove empty space prefix from GST_AUDIO_FORMATS_ALL

This space prevent deserialization using gst_value_deserialize().

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/676>

4 years agoaudio-format: add gst_audio_formats_raw()
Guillaume Desmottes [Wed, 27 May 2020 13:05:37 +0000 (15:05 +0200)]
audio-format: add gst_audio_formats_raw()

The existing GST_AUDIO_FORMATS_ALL macro is not binding friendly.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/676>

4 years agovideo: add gst_video_make_raw_caps()
Guillaume Desmottes [Wed, 27 May 2020 13:41:43 +0000 (15:41 +0200)]
video: add gst_video_make_raw_caps()

More binding friendly version of GST_VIDEO_CAPS_MAKE().

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/676>

4 years agovideo-format: add gst_video_formats_raw()
Guillaume Desmottes [Wed, 27 May 2020 13:05:37 +0000 (15:05 +0200)]
video-format: add gst_video_formats_raw()

The existing GST_VIDEO_FORMATS_ALL macro is not binding friendly.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/676>

4 years agoglcontext/eagl: handle sending one message during shutdown
Matthew Waters [Fri, 29 May 2020 09:08:51 +0000 (19:08 +1000)]
glcontext/eagl: handle sending one message during shutdown

gst_gl_window_quit() will attempt to send a message but will be called
from GstGLContext's finalize handler and so the weak ref that backs
gst_gl_window_get_context will return NULL as it has already been
cleared.  We need that context in send_message_async to decide whether
to run the provided callback immediately or queue in GCD

This is the equivalent commit for iOS as:
7f59cefafb1cd733cf527fb935b2cd32418fcbe2
https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/618

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/681>

4 years agogl/eagl: don't access UIkit objects on the main thread
Matthew Waters [Fri, 29 May 2020 05:44:55 +0000 (15:44 +1000)]
gl/eagl: don't access UIkit objects on the main thread

This means we cannot access [view layer] or view.bounds from the OpenGL
thread.  This also means that we need to call the main thread when
setting the window handle.  However, we cannot perform that
synchronously as that may deadlock with the application performing the
set_window_handle() call.

We need to defer the actual update and run it asynchronously and wait
for the window handle update internally at each point it is needed.

Fixes: https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/issues/372
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/681>

4 years agogl/ios: fix typo GS_GL -> GST_GL
Matthew Waters [Fri, 29 May 2020 04:12:38 +0000 (14:12 +1000)]
gl/ios: fix typo GS_GL -> GST_GL

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/681>

4 years agovideorate: Update QoS events taking into account our rate
Thibault Saunier [Fri, 29 May 2020 20:21:11 +0000 (16:21 -0400)]
videorate: Update QoS events taking into account our rate

Otherwise there is a mismatch between the QoS values and what upstream
would expect, leading to too much buffer dropping in video decoders in
case rate < 1.0 or not enough buffer dropping in case rate > 1.0

Adding validate tests with and without decoders.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/679>

4 years agovideorate: Fix changing `rate` property during playback
Thibault Saunier [Sun, 31 May 2020 04:27:14 +0000 (00:27 -0400)]
videorate: Fix changing `rate` property during playback

We need to take into account the base_ts to compute next_ts and it needs
to be updated on rate change.

This introduces `pending_rate` so that change rate is properly handled
in the streaming thread in a safe way.

Added tests

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/679>

4 years agotests:validate: Run all test using a simple fakesink
Thibault Saunier [Thu, 28 May 2020 17:42:22 +0000 (13:42 -0400)]
tests:validate: Run all test using a simple fakesink

`fakevideosink` is in -bad and thus not available here.

Update the expectation files as video metas are not negotiated anymore.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/677>

4 years agolibs: gl: silence gir compiler
Víctor Manuel Jáquez Leal [Fri, 29 May 2020 09:39:57 +0000 (11:39 +0200)]
libs: gl: silence gir compiler

There were a couple complains of the gir compiler on these gstgl
files.

* Added namespace to public macros, even if they are helpers.
* Removed a misused private tag

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/678>

4 years agovideoscale: reorder code to avoid indent missmatches
Michael Gruner [Thu, 23 Jan 2020 18:38:44 +0000 (12:38 -0600)]
videoscale: reorder code to avoid indent missmatches

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/548>