Havard Graff [Thu, 6 Jun 2019 07:41:13 +0000 (09:41 +0200)]
rtpsession: make tests more stable
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/410>
Tim-Philipp Müller [Sat, 20 Jun 2020 19:42:37 +0000 (20:42 +0100)]
docs: update plugin cache for new version
Some default values include our version string, like
user agent strings.
Tim-Philipp Müller [Fri, 19 Jun 2020 23:28:11 +0000 (00:28 +0100)]
Back to development
Tim-Philipp Müller [Fri, 19 Jun 2020 18:18:59 +0000 (19:18 +0100)]
Release 1.17.1
Seungha Yang [Fri, 19 Jun 2020 11:24:12 +0000 (20:24 +0900)]
meson: deinterlace: Check host cpu type for asm build
Add host cpu type check as we would enable asm only for x86_64
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/636>
Seungha Yang [Fri, 19 Jun 2020 10:54:08 +0000 (19:54 +0900)]
meson: Fix build error with MSVC caused by ARCH_X86_64 define
ARCH_X86_64 define will enable GCC specific code path in dv_types.h
while building dv plugin.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/636>
Tim-Philipp Müller [Fri, 19 Jun 2020 09:32:45 +0000 (10:32 +0100)]
shout2: advertise documentation caps properly
shout2send caps depend on what the libshout2
version in question supports, but the
documentation caps should always be the same.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/635>
Jan Schmidt [Sun, 26 May 2019 10:20:03 +0000 (20:20 +1000)]
qtdemux: Split tag reading functions out
Move some code out of the enormous qtdemux.c into a separate
qtdemux_tags helper, and make some structs available via qtdemux.h
to accommodate that.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/634>
Jan Schmidt [Sat, 25 May 2019 19:05:06 +0000 (05:05 +1000)]
qtdemux: Move some tree parsing files out to a separate file.
Reduce a tiny bit of the bulk of qtdemux.c by moving some
agnostic helper functions out.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/634>
Jan Schmidt [Sat, 25 May 2019 15:24:54 +0000 (01:24 +1000)]
qtdemux: Factor out svmi parsing. Fix bounds checking.
Move the SVMI stereoscopic atom parsing out to a helper
function to shrink qtdemux_parse_trak a bit.
Add a bounds check that the received atom is large enough
before parsing it.
Add a note to the atom parser that svmi comes from the
MPEG-A spec 23000-11.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/634>
Guillaume Desmottes [Mon, 15 Jun 2020 11:05:49 +0000 (13:05 +0200)]
pulse: fix discovery of newly added devices
Fix regression introduced in
7bc5e28d85992b03e5852879b8d4d96043496caf
preventing the device provider to send the device-added message for new
devices.
By early returning the patch was discarding add/remove events.
Fix #735
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/626>
Tim-Philipp Müller [Thu, 18 Jun 2020 09:47:28 +0000 (10:47 +0100)]
examples: qmlsink: rename qrc file to avoid naming conflicts with older meson versions
Would get "Tried to create target "qt5-qmlsink_qrc", but a
target of that name already exists." with older meson versions.
Work around that by renaming the qrc file.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/633>
Nirbheek Chauhan [Wed, 17 Jun 2020 11:12:16 +0000 (16:42 +0530)]
meson: Check the nasm version with run_command
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/751
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/631>
Seungha Yang [Tue, 16 Jun 2020 10:34:01 +0000 (19:34 +0900)]
rtspsrc: Don't return TRUE for unhandled query
Expected return value for unhandled query is FALSE
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/629>
Vivia Nikolaidou [Tue, 16 Jun 2020 08:52:38 +0000 (11:52 +0300)]
deinterlace: Add yadif ASM optimisations
Measured to be about 3.4x faster than C
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/621>
Vivia Nikolaidou [Fri, 12 Jun 2020 10:21:02 +0000 (13:21 +0300)]
deinterlace: Fix invalid read in yadif
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/621>
Matthew Waters [Fri, 12 Jun 2020 02:18:11 +0000 (12:18 +1000)]
qt/gloverlay: reset OpenGL state after Qt drawing
Reset to the original OpenGL state as required by the GStreamer OpenGL
API contract. Fixes output with a glimagesink element downstream.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/623>
Matthew Waters [Fri, 12 Jun 2020 02:16:49 +0000 (12:16 +1000)]
qt/gloverlay: reset current OpenGL context after Qt
Qt may replace the drawable with its own which breaks output if Qt is
not displaying the resulting video as used with e.g. glimagesink.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/623>
Sebastian Dröge [Fri, 12 Jun 2020 06:52:56 +0000 (09:52 +0300)]
flvdemux: Change a GST_ERROR_OBJECT() back to GST_DEBUG_OBJECT()
It was accidentally changed in https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/436
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/624>
Jordan Petridis [Thu, 11 Jun 2020 17:39:33 +0000 (20:39 +0300)]
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 the 2 elements
here 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-good/-/merge_requests/622>
Sebastian Dröge [Wed, 10 Jun 2020 13:56:22 +0000 (13:56 +0000)]
Revert "rtpjitterbuffer: Avoid deadlock on flush"
This reverts commit
54810bf44f27d9c180730f58f16f6e172c7b0bc8
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/620>
Thibault Saunier [Tue, 9 Jun 2020 19:12:13 +0000 (15:12 -0400)]
docs: Update plugins cache
U. Artie Eoff [Tue, 9 Jun 2020 20:09:20 +0000 (13:09 -0700)]
rtpjitterbuffer: g_queue_clear_full introduced in glib 2.60
Define g_queue_clear_full if glib < 2.60.
Fixes #747
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/619>
Thibault Saunier [Mon, 8 Jun 2020 15:33:16 +0000 (11:33 -0400)]
rtpsession: Make internal-ssrc as show default for doc
Thibault Saunier [Mon, 8 Jun 2020 14:56:02 +0000 (10:56 -0400)]
docs: Update plugins cache
Tim-Philipp Müller [Tue, 9 Jun 2020 14:21:25 +0000 (15:21 +0100)]
tests: don't pull in all -bad plugin, only allow the one we need
Set up our plugin include list for tests in such a way that
we don't pull in *all* plugins from -bad but only the one
used in the splitmuxsink unit test, i.e. the timecode plugin,
so we don't accidentally use other encoders/decoders such as
nvenc/dec for example.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/617>
Nicolas Dufresne [Mon, 8 Jun 2020 21:41:13 +0000 (17:41 -0400)]
rtptimerqueue: Fix leak on timer collision
While the caller should make sure this does not happen, make sure timer
collision are not silently ignored and leaked.
Fixes #726
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/616>
Nicolas Dufresne [Fri, 27 Mar 2020 19:48:32 +0000 (15:48 -0400)]
rtpjitterbuffer: Keep JBUF lock while processing timers
Until now, do_expected_timeout() was shortly dropping the JBUF_LOCK in order
to push RTX event event without causing deadlock. As a side effect, some
CPU hung would happen as the timerqueue would get filled while looping over
the due timers. To mitigate this, we were processing the lost timer first and
placing into a queue the remainign to be processed later.
In the gap caused by an unlock, we could endup receiving one of the seqnum
present in the pending timers. In that case, the timer would not be found and
a new one was created. When we then update the expected timer, the seqnum
would already exist and the updated timer would be lost.
In this patch we remove the unlock from do_expected_timeout() and place all
pending RTX event into a queue (instead of pending timer). Then, as soon as
we have selected a timer to wait (or if there is no timer to wait for) we send
all the upstream RTX events. As we no longer unlock, we no longer need to pop
more then one timer from the queue, and we do so with the lock held, which
blocks any new colliding timers from being created.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/616>
Guillaume Desmottes [Mon, 8 Jun 2020 07:33:10 +0000 (09:33 +0200)]
tests: vp9enc: enforce I420 format
Test was not enforcing a video format on videotestsrc. I420 was picked
as it was the first format in GST_VIDEO_FORMATS_ALL which will no longer
be true (gst-plugins-base!689).
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/615>
Edward Hervey [Sat, 30 May 2020 06:55:19 +0000 (08:55 +0200)]
rtpjitterbuffer: Avoid deadlock on flush
When a GST_EVENT_FLUSH_START reaches the jitterbuffer, there is a chance that
our task is currently blocking waiting for a timer.
There was two problems:
* That wait wasn't checking for flushing situations
* The flushing handling wasn't waking up that conditional (to check whether it
should abort)
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/608>
Mathieu Duponchelle [Fri, 5 Jun 2020 22:42:25 +0000 (00:42 +0200)]
plugins: uddate gst_type_mark_as_plugin_api() calls
Sebastian Dröge [Fri, 5 Jun 2020 08:49:17 +0000 (11:49 +0300)]
rtpbin: Initialize uninitialized variable correctly
`last_out` would be used uninitialized if the element has no `set-active`
signal. Initialize it to -1 as that's what the "default" value is
further below.
CID 1455443
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/727
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/613>
Mikhail Fludkov [Thu, 26 Nov 2015 16:52:29 +0000 (17:52 +0100)]
vpxenc: Add new bit-per-pixel property to select a better "default" bitrate
As part of this also change the default bitrate value to 0. The default
value was 256000 previously. In reality, if the property was not set the
bitrate value would be scaled according to the resolution which is not
very intuitive behavior. It is better to use 0 for this purpose. Now
together with newly introduced property "bits-per-pixel" 0 means to
assign the bitrate according to resolution/framerate.
The default bitrates are now
- 1.2Mbps for VP8 720p@30fps
- 0.8Mbps for VP9 720p@30fps
and scaled accordingly for different resolutions/framerates.
Previously the default bitrate was also not scaled according to the
framerate but only took the resolution into account.
This also fixes the side effect of setting bitrate to 0. Previously
encoder would not produce any data at all.
Addition from Sebastian Dröge <sebastian@centricular.com> to assume
30fps if no framerate is given in the caps instead of not calculating
any bitrate at all.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/611>
Thibault Saunier [Wed, 3 Jun 2020 22:35:58 +0000 (18:35 -0400)]
doc: Require hotdoc >= 0.11.0
Thibault Saunier [Tue, 2 Jun 2020 18:58:47 +0000 (14:58 -0400)]
doc: Fix wrong link to GString in rtpjitterbuffer
Sebastian Dröge [Wed, 27 May 2020 13:01:22 +0000 (16:01 +0300)]
docs: Update gst_plugins_cache.json
Mathieu Duponchelle [Fri, 29 May 2020 23:29:03 +0000 (01:29 +0200)]
plugins: Use gst_type_mark_as_plugin_api() for all non-element plugin types
Stian Selnes [Wed, 28 Feb 2018 14:46:51 +0000 (15:46 +0100)]
vpxdec: Check that output width and height != 0
For VP8 it's possible to signal width or height to be 0, but it does
not make sense to do so. For VP9 it's impossible. Hence, we most
likely have a corrupt stream. Trying to negotiate caps downstream with
either width or height as 0 will fail with something like
gst_video_decoder_negotiate_default: assertion 'GST_VIDEO_INFO_WIDTH (&state->info) != 0' failed
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/610>
Seungha Yang [Thu, 28 May 2020 15:45:03 +0000 (00:45 +0900)]
speex: Fix crash on Windows caused by cross-CRT issue
Use speex_header_free() to free memory which was allocated by
library. Cross-CRT issue should not happen on 1.17 Cerbero build
but might happen custom build or so.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/606>
Sebastian Dröge [Wed, 27 May 2020 19:33:31 +0000 (22:33 +0300)]
rtspsrc: Use the correct type for storing the max-rtcp-rtp-time-diff property
It's an integer property and rtpbin also expects an integer. Passing it
as a GstClockTime (guint64) to g_object_set() will cause problems, and
on big endian MIPS apparently causes crashes.
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/737
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/605>
Tim-Philipp Müller [Wed, 27 May 2020 11:42:38 +0000 (12:42 +0100)]
tests: fix meson test env setup to make sure we use the right gst-plugin-scanner
If core is built as a subproject (e.g. as in gst-build), make sure to use
the gst-plugin-scanner from the built subproject. Without this, gstreamer
might accidentally use the gst-plugin-scanner from the install prefix if
that exists, which in turn might drag in gst library versions we didn't
mean to drag in. Those gst library versions might then be older than
what our current build needs, and might cause our newly-built plugins
to get blacklisted in the test registry because they rely on a symbol
that the wrongly-pulled in gst lib doesn't have.
This should fix running of unit tests in gst-build when invoking
meson test or ninja test from outside the devenv for the case where
there is an older or different-version gst-plugin-scanner installed
in the install prefix.
In case no gst-plugin-scanner is installed in the install prefix, this
will fix "GStreamer-WARNING: External plugin loader failed. This most
likely means that the plugin loader helper binary was not found or
could not be run. You might need to set the GST_PLUGIN_SCANNER
environment variable if your setup is unusual." warnings when running
the unit tests.
In the case where we find GStreamer core via pkg-config we use
a newly-added pkg-config var "pluginscannerdir" to get the right
directory. This has the benefit of working transparently for both
installed and uninstalled pkg-config files/setups.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/603>
Thibault Saunier [Tue, 26 May 2020 00:11:31 +0000 (20:11 -0400)]
rtspsrc: Error out when failling to receive message response
And let it rety twice.
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/717
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/601>
Nicolas Dufresne [Thu, 21 May 2020 21:12:55 +0000 (17:12 -0400)]
v4l2: videodec: Fix broken template caps
The profiles and levels were applied to the common caps instead of the copy.
That had the side effect of setting profiles/level from one CODEC onto
another. Leaving to encoder not being registered or not-negotiated errors.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/599>
Nicolas Dufresne [Thu, 21 May 2020 21:09:39 +0000 (17:09 -0400)]
v4l2: codec: Fix GValue leak
The levels and profiles probe function returned a dynamically allocated GValue
that was leaked. Simplify this by using a stack allocated GValue and a boolean
return value.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/599>
Nicolas Dufresne [Thu, 21 May 2020 20:39:53 +0000 (16:39 -0400)]
v4l2codec: Remove uneeded factorisation
There is only one user of that function and the split only increase
complexicity.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/599>
Nicolas Dufresne [Wed, 20 May 2020 21:30:59 +0000 (17:30 -0400)]
v4l2src: Ignore non-increasing sequence number
With older kernel, older driver or just broken drivers, the sequence number
may not be increasing. This simply ignore the sequence in this case. This
would otherwise miss-leading large amount of lost frame being reported.
Fixes #729
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/598>
Matthew Waters [Mon, 18 May 2020 03:17:14 +0000 (13:17 +1000)]
qtoverlay: add the root item as a property
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/595>
Sebastian Dröge [Wed, 20 May 2020 10:17:13 +0000 (13:17 +0300)]
flvdemux: Send gap events if one of the streams falls behind the other by more than 3s
Same mechanism and threshold as in other demuxers.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/597>
Sebastian Dröge [Wed, 20 May 2020 09:53:56 +0000 (12:53 +0300)]
flvdemux: Remove unused audio_linked/video_linked booleans
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/597>
Edward Hervey [Wed, 20 May 2020 08:46:45 +0000 (10:46 +0200)]
flvdemux: Answer bitrate queries from upstream
If upstream (such as queue2 in urisourcebin) asks for our bitrate, check if we
have stored audio/video bitrates, and use them.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/596>
Edward Hervey [Wed, 20 May 2020 08:45:16 +0000 (10:45 +0200)]
flvdemux: Handle empty metadata strings
g_utf8_validate() errors out on empty string. But empty strings are valid,
so only check if they're not
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/596>
Edward Hervey [Wed, 20 May 2020 08:44:19 +0000 (10:44 +0200)]
flvdemux: Set ACCEPT_TEMPLATE flag on sinkpad
A demuxer can accept any caps matching its sinkpad template caps
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/596>
Raul Tambre [Fri, 15 May 2020 16:20:45 +0000 (19:20 +0300)]
qtglrenderer.cc: Fix compiling
46bfb7d247aef880c15300dad63eb2bbf6dc4928 fixed a format warning without checking if it actually compiled.
toUtf8() returns QByteArray so we need to assign it to a temporary variable to be able to get the raw string data from it.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/593>
Raul Tambre [Fri, 15 May 2020 06:07:25 +0000 (06:07 +0000)]
qtglrenderer.cc: Fix -Wformat-security warning
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/592>
Nirbheek Chauhan [Mon, 11 May 2020 23:05:37 +0000 (04:35 +0530)]
meson: Pass native: false to add_languages()
This is needed for cross-compiling without a build machine compiler
available. The option was added in 0.54, but we only need this in
Cerbero and it doesn't break older versions so it should be ok.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/589>
Nirbheek Chauhan [Mon, 11 May 2020 23:03:43 +0000 (04:33 +0530)]
meson: Make C++ compiler detection not be automagic
It is now controlled by the qt5 and/or taglib options. We won't
silently fail to build taglib now.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/587>
Nirbheek Chauhan [Mon, 11 May 2020 23:02:01 +0000 (04:32 +0530)]
meson: Fix gstgl checks for qt and gtk
Also rename from build_ to have_, which is more accurate.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/587>
Nirbheek Chauhan [Mon, 11 May 2020 23:00:13 +0000 (04:30 +0530)]
meson: Revamp qt5qml plugin and example build code
Stricter and simpler. For example, now we properly error out when
gstreamer-gl-1.0 was not found when the qt5 plugin is enabled or when
a C++ compiler is not enabled.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/587>
Jan Schmidt [Fri, 8 May 2020 17:09:03 +0000 (03:09 +1000)]
deinterlace: Split out NULL checks in yadif
Separate out explicit NULL checks for fields we depend on so
that coverity can hopefully verify dependencies better.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/585>
Jan Schmidt [Fri, 8 May 2020 17:07:33 +0000 (03:07 +1000)]
deinterlace: Handle NV12/NV21 for the greedyl mode.
Don't fall back on the default interpolate_scanline function, which
blindly tries to copy from the next field, which can be NULL in
mixed progressive/interlaced streams
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/585>
Vivia Nikolaidou [Tue, 5 May 2020 13:59:56 +0000 (16:59 +0300)]
deinterlace: Support packed formats for YADIF
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/444>
Vivia Nikolaidou [Wed, 6 May 2020 08:04:18 +0000 (11:04 +0300)]
deinterlace: Call the planar functions for the Y plane of nv12/nv21
In some algorithms (like yadif), the Y plane has to be handled different
than the UV plane. Therefore, the planar_y functions are now called for
the Y plane, and the nv12/nv21 functions are handling only the UV/VU
planes respectively.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/444>
Jan Schmidt [Thu, 2 Jan 2020 15:34:59 +0000 (02:34 +1100)]
deinterlace: Add C implementation of YADIF
Import the YADIF deinterlacer from ffmpeg and modify
it to match the simple deinterlace scanlines structure.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/444>
Jan Schmidt [Thu, 2 Jan 2020 15:33:25 +0000 (02:33 +1100)]
deinterlace: Allow for 5 fields for interpolation
Add an extra field to the simple deinterlace implementation,
so that methods can potentially use 5 fields - the current
field, and 2 before and 2 after.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/444>
Jan Schmidt [Wed, 6 May 2020 15:17:25 +0000 (01:17 +1000)]
deinterlace: Force renegotiation when changing mode
Switching the deinterlacing mode on-the-fly from disabled to
auto used to work, but was broken by commit #
1f21747c some
years ago.
Force re-negotiation with downstream when the mode or
fields properties are changed, otherwise deinterlace
never switches out of the passthrough mode.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/584>
nian.yan [Thu, 23 Apr 2020 07:32:58 +0000 (15:32 +0800)]
jpegenc: remove meta copy in jpegenc
GstVideoEncoder takes care of the Meta copy, so there is no need in
jpegenc
Fixes http://gstreamer-devel.966125.n4.nabble.com/jpegenc-copy-GstMeta-twice-tt4693981.html
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/576>
Sebastian Dröge [Tue, 5 May 2020 14:47:28 +0000 (17:47 +0300)]
imagefreeze: Handle flushing correctly
First of all get rid of the atomic seeking boolean, which was only ever
set and never read. Replace it with a flushing boolean that is used in
the loop function to distinguish no buffer because of flushing and no
buffer because of an error as otherwise we could end up in a
GST_FLOW_ERROR case during flushing.
Also only reset the state of imagefreeze in flush-stop when all
processing is stopped instead of doing it as part of flush-start.
And last, get a reference to the imagefreeze buffer in the loop function
in the very beginning and work from that as otherwise it could in theory
be replaced or set to NULL in the meantime as we release and re-take the
mutex a couple of times during the loop function.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/580>
Edward Hervey [Wed, 6 May 2020 04:48:24 +0000 (06:48 +0200)]
videbox: Use MIN instead of CLAMP for uint
an unsigned int is always positive.
CID #206207
CID #206208
CID #206209
CID #206210
CID #206211
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/583>
Edward Hervey [Wed, 6 May 2020 04:35:27 +0000 (06:35 +0200)]
avidemux: Avoid potential double-free
stream->name was being freed (without being NULL-ed) before we were certain it
would be set again.
CID #1456071
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/582>
Edward Hervey [Tue, 5 May 2020 15:30:48 +0000 (17:30 +0200)]
deinterlace: Don't leak frame in error case
CID #1455494
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/581>
Edward Hervey [Tue, 5 May 2020 13:19:49 +0000 (15:19 +0200)]
slitmuxsrc: Properly stop the loop if not part reader is present
Previously this would end up in a refcounting loop of hell.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/578>
Vivia Nikolaidou [Tue, 31 Mar 2020 11:32:19 +0000 (14:32 +0300)]
flvmux: Add skip-backwards-streams property
Backwards timestamps confuse librtmp, even if they're only backwards
relative to the other stream. If the timestamp of a stream is going
backwards related to the other stream, this property allows the muxer to
skip a few buffers until it reaches the timestamp of the other stream.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/572>
Vivia Nikolaidou [Tue, 31 Mar 2020 11:10:35 +0000 (14:10 +0300)]
flvmux: Allow requesting streamable pads after header is written
Allows us to request pads after writing header for streamable flv's.
For non-streamable it doesn't make sense to request a new pad after
writing the header, because the headers have been written already and we
can't add the new stream. But for streamable, any clients that connect
after the new pad has been added will be able to see both streams.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/572>
Matthew Waters [Mon, 27 Apr 2020 08:11:32 +0000 (18:11 +1000)]
qt/x11: also pass the window for gstgl -> qt context
Removes this warning from Qt:
QGLXContext: Multiple configs for FBConfig ID -1
QSGContext::initialize: depth buffer support missing, expect rendering errors
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/575>
Matthew Waters [Mon, 27 Apr 2020 05:34:15 +0000 (15:34 +1000)]
qt: perform surface creation in the main thread
As is required when creating a QWindow instance set out in the Qt
documentation.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/575>
Olivier Crête [Wed, 22 Apr 2020 19:32:31 +0000 (15:32 -0400)]
qtdemux: Add 'mp3 ' fourcc that VLC seems to produce now
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/574>
Sebastian Dröge [Wed, 22 Apr 2020 11:09:37 +0000 (14:09 +0300)]
rtpjitterbuffer: Properly free internal packets queue in finalize()
As we override the GLib item with our own structure, we cannot use any
function from GList or GQueue that would try to free the RTPJitterBufferItem.
In this patch, we move away from g_queue_new() which forces using
g_queue_free(). This this function could use g_slice_free() if there is any items
left in the queue. Passing the wrong size to GSLice may cause data corruption
and crash.
A better approach would be to use a proper intrusive linked list
implementation but that's left as an exercise for the next person
running into crashes caused by this.
Be ware that this regression was introduced 6 years ago in the following
commit [0], the call to flush() looked useless, as there was a g_queue_free()
afterward.
Signed-off-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>
[0] https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/commit/
479c7642fd953edf1291a0ed4a3d53618418019c
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/573>
Seungha Yang [Mon, 20 Apr 2020 10:43:57 +0000 (19:43 +0900)]
tests: splitmuxsink: Add more timecode based split test
... and split test cases to run tests in parallel
Seungha Yang [Fri, 10 Apr 2020 14:52:45 +0000 (23:52 +0900)]
splitmuxsink: Enhancement for timecode based split
The calculated threshold for timecode might be varying depending on
"max-size-timecode" and framerate.
For instance, with framerate 29.97 (30000/1001) and
"max-size-timecode=00:02:00;02", every fragment will have identical
number of frames 3598. However, when "max-size-timecode=00:02:00;00",
calculated next keyframe via gst_video_time_code_add_interval()
can be different per fragment, but this is the nature of timecode.
To compensate such timecode drift, we should keep track of expected
timecode of next fragment based on observed timecode.
Seungha Yang [Fri, 10 Apr 2020 15:35:16 +0000 (00:35 +0900)]
splitmuxsink: Post error when requested timecode interval is invalid
In case we cannot rely on max-size-timecode for split decision,
post error instead of crashing
Havard Graff [Thu, 16 Apr 2020 14:47:50 +0000 (16:47 +0200)]
rtpjitterbuffer: don't use RTX packets in rate-calc and reset-logic
The problem was this:
Due to the highly irregular arrival of RTX-packet the max-misorder variable
could be pushed very low. (-10).
If you then at some point get a big in the sequence-numbers (62 in the
test) you end up sending RTX-requests for some of those packets, and then
if the sender answers those requests, you are going to get a bunch of
RTX-packets arriving. (-13 and then 5 more packets in the test)
Now, if max-misorder is pushed very low at this point, these RTX-packets
will trigger the handle_big_gap_buffer() logic, and because they arriving
so neatly in order, (as they would, since they have been requested like
that), the gst_rtp_jitter_buffer_reset() will be called, and two things
will happen:
1. priv->next_seqnum will be set to the first RTX packet
2. the 5 RTX-packet will be pushed into the chain() function
However, at this point, these RTX-packets are no longer valid, the
jitterbuffer has already pushed lost-events for these, so they will now
be dropped on the floor, and never make it to the waiting loop-function.
And, since we now have a priv->next_seqnum that will never arrive
in the loop-function, the jitterbuffer is now stalled forever, and will
not push out another buffer.
The proposed fixes:
1. Don't use RTX in calculation of the packet-rate.
2. Don't use RTX in large-gap logic, as they are likely to be dropped.
Nicolas Dufresne [Wed, 15 Apr 2020 16:36:29 +0000 (12:36 -0400)]
v4l2videodec: Increase internal bitstream pool size
This patch will now set the maximum of buffers to 32, allowing to grow the
pool for drivers that supports that and will respect the minimum buffers
reported by the driver. This was made to fix a stall with the virtio CODEC
driver.
Fixes #672
Sebastian Dröge [Wed, 15 Apr 2020 14:50:31 +0000 (17:50 +0300)]
splitmuxsink: Do split-at-running-time splitting based on the time of the start of the GOP
If the start of the GOP is >= the requested running time, put it into a
new fragment. That is, split-at-running-time would always ensure that a
split happens as early as possible after the given running time.
Previously it was comparing against the current incoming timestamp,
which does not tell us what we actually want to know as it has no direct
relation to the GOP start/end.
Sebastian Dröge [Wed, 15 Apr 2020 10:21:05 +0000 (13:21 +0300)]
splitmuxsink: Fix off-by-one in running time comparison for split-at-running-time
If we get a keyframe exactly at the requested running time we would only
split on the next keyframe afterwards due to wrong usage of > vs. >=.
Thibault Saunier [Thu, 9 Apr 2020 16:23:44 +0000 (12:23 -0400)]
rtspsrc: Properly set segments seqnums after seeks
Vivia Nikolaidou [Wed, 8 Apr 2020 16:49:00 +0000 (19:49 +0300)]
flvdemux: Don't write an empty string as a tag
To stop warnings like:
GStreamer-WARNING **: 19:47:48.186: Trying to set empty string on
taglist field 'encoder'. Please file a bug.
Nicolas Dufresne [Wed, 8 Apr 2020 16:34:40 +0000 (12:34 -0400)]
v4l2bufferpool: request the maximum number of buffers for USERPTR
This is to match what we now do for DMABuf importation.
Michael Olbrich [Wed, 20 Nov 2019 14:32:29 +0000 (15:32 +0100)]
v4l2bufferpool: request the maximum number of buffers for DMABUF
There are often only two buffers queued in the kernel so no new buffers are
requested.
With every qbuf, the kernel receives a new DMABUF for the specified index.
This most likely differs from the last DMABUF and the old cached entry is
released. This results in a lot of map/unmap overhead if the kernel driver
needs a mapping for the buffer.
With a larger queue, it's quite likely, that both old and new DMABUFs are
also mapped for another index. So the map/unmap is skipped, because the
mapping is reference counted.
The corresponding allocated buffers don't contain any actual memory, so
allocating them is quite cheep. So the log message is updated to clarify
this.
Thibault Saunier [Wed, 8 Apr 2020 13:45:17 +0000 (09:45 -0400)]
rtspsrc: Avoid stack overflow recursing waiting for response
Instead of recursing, simply implement a loop with gotos, the same
way it was done before
812175288769d647ed6388755aed386378d9210c
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/710
Sebastian Dröge [Mon, 6 Apr 2020 13:25:59 +0000 (16:25 +0300)]
qtmux: Add property for enforcing the creation of chunks in single-stream files
This is disabled by default as it unnecessarily creates bigger headers
but it is something that is required by some applications and most
notably the Apple ProRes spec.
Jan Schmidt [Thu, 2 Apr 2020 13:16:10 +0000 (00:16 +1100)]
flvmux: Fix invalid padlist accesses.
Request pads can released at any time, so make sure to hold
the object lock when iterating the element sinkpads list where
that's safe, or to use other safe pad iteration patterns in
other places.
When choosing a best pad, return a reference to the pad to make sure it
stays alive for output in the aggregator srcpad task.
Should fix a spurious valgrind error in the CI flvmux tests and some
other potential problems if the request sink pads are released while
the element is running..
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/issues/714
Vivia Nikolaidou [Mon, 22 Oct 2018 12:41:56 +0000 (15:41 +0300)]
qtmux: Add option to create a timecode trak in non-mov flavors
Even if timecode trak is officially unsupported in non-mov flavors,
some software still supports it, e.g. Final Cut Pro X:
https://developer.apple.com/library/archive/technotes/tn2174/_index.html
The user might still expect to see the timecode information in the
non-mov file despite it being officially unsupported , because other
software e.g. QuickTime will create a timecode trak even in mp4 files.
Furthermore, software that supports timecode trak in non-mov flavors
will also display the file duration in "timecode units" instead of real
clock time, which is not necessarily the same for 29.97 fps and friends.
This might confuse users, who see a different duration for the same
framerate and amount of frames depending on whether the container is mp4
or mov.
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/issues/512
Sebastian Dröge [Thu, 16 Jan 2020 07:30:39 +0000 (09:30 +0200)]
rtpLXXdepay: Set the UNPOSITIONED flag on the audio-info when configuring an unpositioned layout
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/issues/688
Kristofer Björkström [Wed, 1 Apr 2020 11:19:46 +0000 (13:19 +0200)]
rtpjpeg: Use gst_memory_map() instead of gst_buffer_map()
gst_buffer_map () results in memcopying when a GstBuffer contains
more than one GstMemory.
This has quite an impact on performance on systems with limited amount
of resources. With this patch the whole GstBuffer will not be mapped at
once, instead each individual GstMemory will be iterated and mapped
separately.
Kristofer Björkström [Wed, 1 Apr 2020 11:17:03 +0000 (13:17 +0200)]
buffermemory: keep track of buffer size and current offset
Added the possibility to get current offset and the total size of the
buffer.
Havard Graff [Fri, 3 Apr 2020 08:29:18 +0000 (10:29 +0200)]
rtpopuspay: make depay ! pay work
There is a use-case for a server to re-payload opus going through it.
Problem was that the payloader requires channels in the caps, but
this is not something the depayloader can parse out of the stream, meaning
caps-negotiation would fail.
Removing the requirement of channels in the template-caps fixes this.
Seungha Yang [Fri, 3 Apr 2020 07:49:25 +0000 (16:49 +0900)]
tests: Split splitmux test case
Since we are adding more and more tests into splitmux,
we need to split it to avoid CI timeout.
Seungha Yang [Fri, 3 Apr 2020 04:45:56 +0000 (13:45 +0900)]
splitmuxsink: Don't send too many force key unit event
splitmuxsink should requst keyframe depending on configured
threshold and previously requested time in order to avoid too many
keyframe request.
Jan Schmidt [Fri, 20 Mar 2020 10:32:36 +0000 (21:32 +1100)]
matroska: Check the return value of gst_segment_do_seek()
gst_segment_do_seek() can fail.
Sebastian Dröge [Fri, 8 Jun 2018 10:12:01 +0000 (13:12 +0300)]
qtdemux: Send instant-rate-change event if requested in the SEEK event
Handle an instant rate change seek immediately by reflecting
it downstream as an instant-rate-change event, and do no
further seek handling.