Vivia Nikolaidou [Thu, 11 Jun 2020 10:50:38 +0000 (13:50 +0300)]
interlace: Fix crash with empty caps in setcaps
If the src_peer_caps are EMPTY (e.g. negotiation failed somewhere), the
assertion inside gst_video_info_from_caps would fail and the whole
pipeline would crash. Check for gst_caps_is_empty before
gst_video_info_from_caps and gracefully fail if it's empty.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1333>
Seungha Yang [Tue, 9 Jun 2020 13:38:28 +0000 (22:38 +0900)]
wasapi: Fix possible deadlock while downwards state change
IAudioClient::Stop() doesn't seem to wake up the event handle,
then read() or write() could be blocked forever by WaitForSingleObject.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1329>
Thibault Saunier [Tue, 9 Jun 2020 19:31:56 +0000 (15:31 -0400)]
docs: Update plugins cache
Haihua Hu [Tue, 9 Jun 2020 02:53:17 +0000 (10:53 +0800)]
waylandsink: add wl_registry.global_remove listener
when hotplug display, wayland client will call this listener
to notify client do clean up. Temporarily set a dummy function
here to avoid app abort
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1327>
Thibault Saunier [Mon, 8 Jun 2020 18:56:31 +0000 (14:56 -0400)]
srt: doc: Add missing gst_type_mark_as_plugin_api
Thibault Saunier [Mon, 8 Jun 2020 17:03:09 +0000 (13:03 -0400)]
docs: Mark lv2 runtime generated enums as plugins API types
Thibault Saunier [Mon, 8 Jun 2020 16:30:59 +0000 (12:30 -0400)]
docs: Add some more plugin API types
And allow creating vulkan device object without specifying an instance
so it can be introspected.
Thibault Saunier [Mon, 8 Jun 2020 13:52:30 +0000 (09:52 -0400)]
docs: Update plugins cache
Nicolas Dufresne [Tue, 9 Jun 2020 14:48:06 +0000 (10:48 -0400)]
v4l2slh264dec: Fix reading mode and start code type
These two controls are not pointer based, so we don't need to pass any size or
pointer and need to copy the values afterward. This fixes H264 decoding
regression with Hantro and RKVDEC drivers.
Fixes
037730a787c6cdeeee5779c1834315c1ca764505
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1330>
Seungha Yang [Mon, 8 Jun 2020 14:46:43 +0000 (23:46 +0900)]
mftransform: Fix deadlock when MFT requests processing output twice
This sequence of event/data flow might happen
1) Initially we have one pending output event
1-1) Then, process the pending output data
2) No pending input event, then we should wait new pending input event
2-1) Wakeup by new pending event (but it's pending output event)
In above case, MFT will not report new pending input event
if pending output is not processed.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1325>
Seungha Yang [Mon, 8 Jun 2020 10:22:07 +0000 (19:22 +0900)]
mftransform: Add some debug log
Add some trace level log for debugging
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1325>
Edward Hervey [Tue, 19 May 2020 08:27:18 +0000 (10:27 +0200)]
adaptivedemux: Handle live duration queries
Handle it the same way live sources would, that it by handling the query and
return an unknown duration.
Fixes #566
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1279>
Seungha Yang [Sun, 10 May 2020 16:53:11 +0000 (01:53 +0900)]
tests: wasapi2: Add unit test for reusing wasapisrc
Test state change between playing and null and playing again
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1264>
Seungha Yang [Wed, 27 May 2020 20:09:47 +0000 (05:09 +0900)]
wasapi2: Add device provider implementation
Similar to device provider implementation of wasapi plugin,
this implementation supports only static probing.
But we can implement runtime device add/remove/update
monitoring using DeviceWatcher interface later.
See https://docs.microsoft.com/en-us/uwp/api/windows.devices.enumeration.devicewatcher
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1264>
Seungha Yang [Mon, 25 May 2020 20:17:41 +0000 (05:17 +0900)]
wasapi2: Introduce new WASAPI plugin
Add a new wasapi implementation mainly to support UWP application.
Basically the core logic of this plugin is almost identical to
existing wasapi plugin, but main target is Windows 10 (+ UWP).
Since this plugin uses WinRT APIs, this plugin most likely might not
work Windows 8 or lower.
Compared with existing wasapi plugin, additional features of this plugin are
* Fully compatible with both Windows 10 desktop and UWP application
* Supports automatic stream routing (auto fallback when device was removed)
* Support device level mute/volume control
But some features of existing wasapi plugin are not implemented
in this plugin yet
* Exclusive streaming mode is not supported
* Loopback feature is not implemented
* Cross-compile is not possible with current mingw toolchain
(meaning that MSVC and Windows 10 SDK are required to build this plugin)
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1264>
Seungha Yang [Sat, 6 Jun 2020 12:15:34 +0000 (21:15 +0900)]
mfvideoenc: Set PAR to output IMFMediaType
We've set it to input IMFMediaType but not for output.
So, if PAR is not 1:1, the input IMFMediaType will be accepted
by MFT (default is 1:1).
The PAR of input/output IMFMediaType must be identical
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1322>
Seungha Yang [Sat, 6 Jun 2020 12:01:24 +0000 (21:01 +0900)]
mftransform: Don't try to drain if MFT is not running
Otherwise MFT will be blocked forever as no event can be generated by
IMFMediaEventGenerator.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1322>
Mathieu Duponchelle [Fri, 5 Jun 2020 22:40:42 +0000 (00:40 +0200)]
plugins: uddate gst_type_mark_as_plugin_api() calls
Seungha Yang [Fri, 5 Jun 2020 13:39:54 +0000 (22:39 +0900)]
d3d11overlaycompositor: Fix wrong Y position calculation
The Y coordinate of vertex and screen/image are opposite
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1319>
cketti [Thu, 4 Jun 2020 11:33:59 +0000 (13:33 +0200)]
curlsmtpsink: Use correct email date format
See https://www.rfc-editor.org/rfc/rfc5322.html#section-3.3
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1317>
Matthew Waters [Tue, 2 Jun 2020 08:07:10 +0000 (18:07 +1000)]
ccconverter: signal cea608 padding as invalid
Outputting a valid but null cea608 byte pair may cause some issues with
some checksum packets.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1318>
Matthew Waters [Tue, 2 Jun 2020 07:35:00 +0000 (17:35 +1000)]
ccconverter: also copy buffer metadata when draining
Fixes buffers without PTS/DTS/meta/etc when receiving an EOS with data
still stored in the internal scratch buffer.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1318>
Matthew Waters [Tue, 2 Jun 2020 07:33:07 +0000 (17:33 +1000)]
ccconverter: Output the limit hit in debug lines
Fix two case of the input triplet limit not applying in cea608 -> cdp
conversion.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1318>
Thibault Saunier [Wed, 3 Jun 2020 22:38:58 +0000 (18:38 -0400)]
doc: Require hotdoc >= 0.11.0
Thibault Saunier [Tue, 2 Jun 2020 19:06:38 +0000 (15:06 -0400)]
doc: Fix spelling of GstWebRTCICE
Sebastian Dröge [Wed, 27 May 2020 13:01:42 +0000 (16:01 +0300)]
docs: Update gst_plugins_cache.json
Sebastian Dröge [Tue, 2 Jun 2020 09:51:35 +0000 (12:51 +0300)]
clockselect: Don't register GstClockSelectClockId multiple times
Sebastian Dröge [Sun, 31 May 2020 07:18:00 +0000 (10:18 +0300)]
plugins: Use gst_type_mark_as_plugin_api() for all non-element plugin types
Peter Workman [Tue, 2 Jun 2020 21:29:16 +0000 (18:29 -0300)]
srtobject: continue polling or report error on failed receive
fixes #1277
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1260>
Seungha Yang [Wed, 3 Jun 2020 08:49:41 +0000 (17:49 +0900)]
d3dvideosink: Use secondary rank
d3dvideosink will be replaced by d3d11videosink
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1311>
Seungha Yang [Fri, 29 May 2020 19:56:58 +0000 (04:56 +0900)]
d3d11videosink: Assign primary rank
d3d11videosink has an advantage over d3dvideosink, such as
* Zero-copy playback with d3d11 decoders
* HDR rendering with 10-bit format/swapchain support
* UWP support
* Any system memory alignment/padding can be supported
* User can select target GPU device
And old d3dvideosink's functionality (e.g., navigation event, overlaycomposition)
can be covered by d3d11videosink
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1311>
Sebastian Dröge [Wed, 3 Jun 2020 07:32:00 +0000 (10:32 +0300)]
webrtc: Add `Since: 1.18` markers to the new datachannel library API
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1315>
Jan Alexander Steffens (heftig) [Fri, 15 May 2020 14:51:46 +0000 (16:51 +0200)]
srt: Make logging regarding callers more useful
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1273>
Sebastian Dröge [Mon, 1 Jun 2020 11:46:03 +0000 (14:46 +0300)]
webrtc: Add GstWebRTCDataChannel to the library API
This makes it more discoverable for bindings and allows bindings to
generate static API for the signals and functions.
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/issues/1168
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1313>
Matthew Waters [Fri, 29 May 2020 12:21:10 +0000 (22:21 +1000)]
vulkanimagememory: fix use-after-free releasing a view
If the view has the last reference to the image, then
gst_clear_mini_object will destroy the image and the lock used in the
next line.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1314>
Matthew Waters [Fri, 29 May 2020 12:17:24 +0000 (22:17 +1000)]
vkimagememory: actually check the length of a ptr array
Not it's value is > 0 which should always be true.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1314>
Ederson de Souza [Thu, 28 May 2020 18:51:28 +0000 (11:51 -0700)]
avtp: Ensure that the avtp plugin is only built on Linux
It uses some Linux only features. This also prevents gst-build trying to
get libavtp on non-Linux environments.
Ederson de Souza [Fri, 29 May 2020 18:36:06 +0000 (11:36 -0700)]
tests/avtp: Plug some (more) leaks
Some leaks were introduced in new tests - this patch fix them.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1312>
Haihao Xiang [Wed, 8 Apr 2020 06:40:56 +0000 (14:40 +0800)]
msdkh265enc: add support 12-bit 420 encoding
P016 is used for 12-bit encoding in MediaSDK, so the Shift flag is set
in the mfx parameters
Sample pipeline:
gst-launch-1.0 videotestsrc ! video/x-raw,format=P012_LE ! msdkh265enc ! \
fakesink
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1174>
Xu Guangxin [Tue, 19 May 2020 06:59:25 +0000 (14:59 +0800)]
msdkvpp: fix "failed to create new MSDK memory"
all msdk output surfaces come from out_alloc_resp, so the buffer count is not resizable.
we need set min_buffers, max_buffers to same size.
steps to reproduce
1. ffmpeg -f lavfi -i testsrc=duration=10:size=320x240:rate=30:decimals=3 -pix_fmt yuv420p -c:v libx265 ~/bits/hevc/test.265
2. GST_GL_PLATFORM=egl gst-launch-1.0 -v filesrc location=~/bits/hevc/test.265 ! h265parse ! msdkh265dec ! msdkvpp ! queue ! glimagesink
you will see error like this:
ERROR default gstmsdkvideomemory.c:77:gst_msdk_video_allocator_get_surface: failed to get surface available
ERROR msdkbufferpool gstmsdkbufferpool.c:270:gst_msdk_buffer_pool_alloc_buffer:<msdkbufferpool2> failed to create new MSDK memory
ERROR msdkvpp gstmsdkvpp.c:297:create_output_buffer:<msdkvpp0> failed to create output video buffer
ERROR msdkdec gstmsdkdec.c:699:gst_msdkdec_finish_task:<msdkh265dec0> Failed to finish frame
ERROR msdkdec gstmsdkdec.c:1085:gst_msdkdec_handle_frame:<msdkh265dec0> Failed to finish a task
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1278>
Xu Guangxin [Tue, 19 May 2020 07:14:34 +0000 (15:14 +0800)]
msdkvpp: hold GstBuffer ref count for locked surfaces
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1278>
Seungha Yang [Fri, 29 May 2020 13:55:56 +0000 (22:55 +0900)]
mediafoundation: Use core dispatcher of current view instead of main view
Main view might be hidden depending on application's view tree.
In that case, ICoreApplication object doesn't return get_MainView() method
Note that nothing about this behavior was documented by Microsoft
https://docs.microsoft.com/en-us/uwp/api/windows.applicationmodel.core.coreapplication.mainview
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1310>
Tim-Philipp Müller [Thu, 28 May 2020 21:48:15 +0000 (22:48 +0100)]
vulkan: fix use of assert() with older meson versions
Follow-up to !1307
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1308>
Tim-Philipp Müller [Thu, 28 May 2020 18:07:32 +0000 (19:07 +0100)]
vulkan: don't run tests or build lib if plugin isn't actually built
The unit tests only checked for vulkan_dep.found(), which can
be true if the libs are there but glslc was not found, in which
case the plugin wouldn't be built and the unit tests would fail
because of missing vulkan plugins.
Doesn't really make much sense to build the vulkan integration lib
either if we're not going to build the vulkan plugin, so just disable
both for now if glslc is not available.
Fixes #1301
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1307>
Jan Alexander Steffens (heftig) [Wed, 27 May 2020 12:44:01 +0000 (14:44 +0200)]
mpegtsdemux: tests: Test that tsparse doesn't drop padding
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1300>
Jan Alexander Steffens (heftig) [Tue, 26 May 2020 20:40:04 +0000 (22:40 +0200)]
mpegtsdemux: Deliver all packets to tsparse
34af8ed66a7c63048ce0bdf59bbe61011d7c6292 changed the code to use the
packetizer's packets instead of the incoming buffers, but mpegtsbase
didn't actually push all packets to the subclass. As a result, padding
(PID 0x1FFF) packets got lost.
Add a new boolean to toggle pushing unknown packets to mpegtsbase and
have mpegtsparse make use of it.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1300>
Seungha Yang [Thu, 28 May 2020 11:46:02 +0000 (20:46 +0900)]
mediafoundation: Fix undeclared identifier error on UWP build
Some symbols are not available in case of UWP
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1306>
Jan Schmidt [Thu, 28 May 2020 08:18:58 +0000 (18:18 +1000)]
avtp: Initialise strack structures to 0 in tests
Avoid valgrind warnings about accessing uninitialised memory
in the tests by initialisting structures to 0
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1305>
Jan Schmidt [Thu, 28 May 2020 07:33:43 +0000 (17:33 +1000)]
avtp: Fix some leaks in the tests
Fix valgrind errors that area showing on the CI now
that AVTP elements are built.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1305>
Matthew Waters [Mon, 25 May 2020 03:10:20 +0000 (13:10 +1000)]
webrtc: handle an ice-lite remote offer
When the remote peer offers an ice-lite SDP, we need to configure our
ICE negotiation to be in controlling mode as the peer will not be.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1304>
Stéphane Cerveau [Fri, 8 May 2020 15:30:21 +0000 (17:30 +0200)]
codecparsers: fix typo in GstH265RegisteredUserData doc
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1303>
Tim-Philipp Müller [Wed, 27 May 2020 14:17:12 +0000 (15:17 +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-bad/-/merge_requests/1302>
Seungha Yang [Thu, 21 May 2020 20:55:03 +0000 (05:55 +0900)]
mediafoundation: Add support MP3 audio encoding
Add MediaFoundation MP3 encoder
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1280>
Seungha Yang [Mon, 18 May 2020 09:12:38 +0000 (18:12 +0900)]
mediafoundation: Add support for AAC encoding
Add MediaFoundation AAC encoder element.
Before Windows 10, mono and stereo channels were supported audio channels
configuration by AAC encoder MFT. However, on Windows 10,
5.1 channels support was introduced.
To expose correct range of support format by this element
whatever the OS version is, this element will enumerate
all the supported format by the AAC encoder MFT
and then will configure sink/src templates while plugin init.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1280>
Seungha Yang [Sat, 23 May 2020 15:46:38 +0000 (00:46 +0900)]
mfutils: Move IMediaType release function to common utility
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1280>
Seungha Yang [Sun, 17 May 2020 15:41:14 +0000 (00:41 +0900)]
mediafoundation: Add util function to dump IMFAttributes values
It would be useful for debugging.
Reference: https://docs.microsoft.com/en-us/windows/win32/medfound/media-type-debugging-code
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1280>
Seungha Yang [Tue, 26 May 2020 18:50:57 +0000 (03:50 +0900)]
d3d11window_win32: Create internal window on parent window's thread
If parent and child windows are running on different thread,
there is always a chance to cause deadlock as DefWindowProc() call
from child window thread might be blocked until the message
is handled by parent's window procedure.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1299>
Seungha Yang [Tue, 26 May 2020 16:52:59 +0000 (01:52 +0900)]
d3d11window: Add unprepare method to clear internal resource
GObject::dispose method can be called multiple times. As win32 d3d11window
has an internal thread and because GObject::dispose method could be called from the
thread, it might cause problems such as trying to join self-thread
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1299>
Seungha Yang [Mon, 25 May 2020 12:18:16 +0000 (21:18 +0900)]
mfsourceobject: Remove useless null check for string
We can pass null for the value of string type property.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1241>
Seungha Yang [Mon, 25 May 2020 11:59:50 +0000 (20:59 +0900)]
mediafoundation: Use G_BEGIN_DECLS/G_END_DECLS pair everywhere
... instead of extern "c" {} block.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1241>
Seungha Yang [Wed, 20 May 2020 14:23:08 +0000 (23:23 +0900)]
mediafoundation: Add support video capture on UWP app
New video capture implementation using WinRT Media APIs for UWP app.
Due to the strict permission policy of UWP, device enumeration and
open should be done via new WinRT APIs and to get permission from users,
it will invoke permission dialog on UI.
Strictly saying, this implementation is not a part of MediaFoundation
but structurally it's very similar to MediaFoundation API.
So we can avoid some code duplication by adding this implementation
into MediaFoundation plugin.
This implementation requires UniversalApiContract version >= 6.0
which is part of Windows 10 version 1803 (Redstone 4)
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1241>
Seungha Yang [Wed, 20 May 2020 14:56:38 +0000 (23:56 +0900)]
mfsourceobject: Move device name, path, and index to public struct
... so that subclass can access each value and update them.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1241>
Seungha Yang [Wed, 20 May 2020 13:59:19 +0000 (22:59 +0900)]
mediafoundation: Fix typo in source object impl.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1241>
Sebastian Dröge [Mon, 25 May 2020 12:36:38 +0000 (15:36 +0300)]
audiobuffersplit: Unset DISCONT flag if not discontinuous
And also set/unset the RESYNC flag accordingly.
It can happen that the flag is preserved by GstAdapter from the input
buffer. For example if a big input buffer is split into many small ones,
each of the small ones would have the flag set.
All other buffer flags seem safe to keep here if they were set,
including the GAP flag.
Also ensure that the buffer is actually writable before changing any
flags or metadata on it.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1298>
Seungha Yang [Mon, 25 May 2020 10:22:50 +0000 (19:22 +0900)]
mftransform: Clear unused output IMediaSample
If MFT doesn't produce encoded output, need to free allocated
output sample and buffer.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1297>
Jan Schmidt [Sun, 24 May 2020 15:49:00 +0000 (01:49 +1000)]
tsdemux: Handle old streams claiming to be HDMV with Opus
GStreamer 1.16 and earlier produced streams with HDMV registration id
but with Opus audio streams on the stream ID that AC-4 now uses. Make
sure those still play back by special casing the check for AC-4 in HDMV
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/issues/1295
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1296>
Jan Schmidt [Sat, 23 May 2020 20:22:07 +0000 (06:22 +1000)]
srt: Don't leak the connection_poll_id on close()
Attempting to reach an inactive SRT peer in caller mode
was leaking an fd every few seconds in the gst_srt_object_close()/open()
loop.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1293>
Seungha Yang [Sun, 24 May 2020 10:12:28 +0000 (19:12 +0900)]
mfvideoenc: Fix huge memory leak
Subclass must unref passed GstVideoCodecFrame on GstVideoEncoder::handle_frame()
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1294>
Thibault Saunier [Tue, 19 May 2020 14:47:25 +0000 (10:47 -0400)]
pitch: Remove useless restriction on number of channel
It handles any number of channels just fine
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1292>
Seungha Yang [Fri, 22 May 2020 17:33:24 +0000 (02:33 +0900)]
h264decoder: Disallow multiple slice group as we don't support FMO
Even though it might be supported by accelerator, baseclass is not
ready to support it.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1291>
Seungha Yang [Fri, 22 May 2020 15:57:23 +0000 (00:57 +0900)]
nvh264sldec: Fix wrong scaling list matrix scan order
Quatization matrix of NVDEC should be raster scan order but
h264parser stores it in zig-zag scan order. We need to convert
the matrix.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1290>
Andrey Sazonov [Thu, 21 May 2020 11:20:39 +0000 (11:20 +0000)]
asfmux: consistent sscanf args usage
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1286>
Nicolas Dufresne [Wed, 20 May 2020 11:35:28 +0000 (07:35 -0400)]
v4l2codecs: h264: Add missing break
There was a missing break for the 4:4:4 case which would break the sizeimage
calculation. We don't currently have hardware that supports 4:4:4, so this
code wasn't tested. This was detected by Coverity.
CID 1463592 1463591
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1283>
Andrey Sazonov [Thu, 21 May 2020 14:28:38 +0000 (14:28 +0000)]
planaraudioadapter: fix possible NULL ptr dereference
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1288>
Andrey Sazonov [Thu, 21 May 2020 11:24:51 +0000 (11:24 +0000)]
sdpdemux: fix klocwork issues
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1287>
Matthew Waters [Tue, 19 May 2020 04:58:35 +0000 (14:58 +1000)]
amc/videodec: only retrieve the stride/slice-height for raw output
When outputting to a surface, these values may not exist.
As found on a Google Pixel 3.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1284>
Stéphane Cerveau [Thu, 14 May 2020 15:13:00 +0000 (17:13 +0200)]
meson: add libopenjp2 fallback for openjpeg
As a wrap is now available in gst-build, the fallback
can be used.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1270>
Ederson de Souza [Wed, 13 May 2020 22:02:41 +0000 (15:02 -0700)]
avtp: Add libavtp fallback dependence
So that libavtp can be found if added as subproject on gst-build.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1271>
Seungha Yang [Fri, 1 May 2020 06:58:09 +0000 (15:58 +0900)]
mediafoundation: Add device provider implementation
Only static device probing is supported for now
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1236>
Seungha Yang [Fri, 1 May 2020 06:12:43 +0000 (15:12 +0900)]
mfsourceobject: Store selected device path, name and index
Update path, name and index with selected device so that checked by
get_property() after constructed.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1236>
Edward Hervey [Wed, 20 May 2020 08:54:21 +0000 (10:54 +0200)]
rtmp2src: Answer scheduling query
Just like for rtmpsrc, we must inform downstream that we are a
sequential (i.e. don't do random access efficiently) and
bandwith-limited (i.e. might need buffering downstream) element
Fixes buffering issues with playbin3
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1282>
Nicolas Dufresne [Wed, 6 May 2020 16:27:56 +0000 (12:27 -0400)]
v4l2slh264dec: Request large enough bitstream buffer
The Cedrus driver would otherwise choose 1KB buffer, which is too small.
This follows what some drivers do, which is simply to use the size a
packed raw image would have. Specifications do not really guaranty any minimum
compression ratio.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1268>
Nicolas Dufresne [Tue, 5 May 2020 21:55:19 +0000 (17:55 -0400)]
v4l2slh264dec: Add slice based decoder support
This adds support for slice based decoder like the Allwinner/Cedrus driver. In
order to keep things efficient, we hold the sink buffer until we reach the end
of the picture. Note that as we don't know which one is last, we lazy queue the
slices. This effectively introduces one slice latency.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1268>
Nicolas Dufresne [Thu, 30 Apr 2020 19:17:05 +0000 (15:17 -0400)]
v4l2codecdec: Fix error handling
If none of the format the HW produce is supported, the fiter will be NULL,
which would lead to assertion when trying to release it.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1268>
Nicolas Dufresne [Thu, 30 Apr 2020 18:18:47 +0000 (14:18 -0400)]
v4l2decoder: Add legacy non-multiplanar support
The Cedrus driver uses the lagacy buffer type (non-mplane). This automatically
detect and use the right v4l2_buf_type. This also affect code using
v4l2_buffer and v4l2_format structures.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1268>
Nicolas Dufresne [Tue, 5 May 2020 21:50:22 +0000 (17:50 -0400)]
v4l2codecs: Update kernel headers
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1268>
Seungha Yang [Sat, 16 May 2020 12:52:59 +0000 (21:52 +0900)]
d3d11convert: Fix fallback texture setup when resolution is not even number
When texture format is semi-planar, resolution should be even number,
and add missing P016 format handling
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1275>
Seungha Yang [Sat, 16 May 2020 12:45:02 +0000 (21:45 +0900)]
d3d11convert: Fix fallback texture copy
Fix texture copy when input texture has non-zero subresource index
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1275>
Seungha Yang [Sat, 16 May 2020 11:45:23 +0000 (20:45 +0900)]
d3d11: Add support for video rescale and rename element to d3d11convert
GstD3D11ColorConverter implementation is able to rescale video as well.
By doing colorspace conversion and rescale at once, we can save
one cycle of shader pipeline which will can save GPU resource.
Since this element can support color space conversion and rescale,
it's renamed as d3d11convert
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1275>
Seungha Yang [Sat, 16 May 2020 11:12:33 +0000 (20:12 +0900)]
d3d11: Move scoring util method for colorspace conversion to colorconvert element
It's used only by colorconvert element.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1275>
Víctor Manuel Jáquez Leal [Sat, 16 May 2020 09:14:58 +0000 (11:14 +0200)]
codecs: h264decoder: chain finalize vmethod
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1238>
Nicolas Dufresne [Wed, 13 May 2020 21:23:12 +0000 (17:23 -0400)]
codecparsers: h264: Only set relevant default weight values
This is minor optimization to avoid setting values we don't need. It also
makes debugging easier since only relevant values a non-zero now.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1238>
Nicolas Dufresne [Wed, 13 May 2020 19:32:44 +0000 (15:32 -0400)]
codecparsers: h264: Fix default ref list size
The default in PPS was not applied properly. The default does not apply for
I-Slice and l1 default only applies for B-Slice. This fixes the slice values
for num_ref_idx_l0_active_minus1 and num_ref_idx_l1_active_minus1.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1238>
Nicolas Dufresne [Tue, 12 May 2020 16:23:15 +0000 (12:23 -0400)]
codecs: h264decoder: Use calculated values for max_pic_num/frame_num
The parser pre-calculate these already, just use them.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1238>
Víctor Manuel Jáquez Leal [Sun, 3 May 2020 15:30:34 +0000 (17:30 +0200)]
codecs: h264decoder: ref pic lists as decode_slice parameters
Pass reference picture lists to decode_slice() vmethods
Change gstv4l2codech264dec and gstnvh264dec accordingly.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1238>
Víctor Manuel Jáquez Leal [Mon, 27 Apr 2020 14:53:45 +0000 (16:53 +0200)]
codecs: h264decoder: handle reference picture lists
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1238>
Nicolas Dufresne [Fri, 15 May 2020 18:56:27 +0000 (14:56 -0400)]
codecs: h264decoder: Port from GList to GArray
Using glist requires a lot of small allocation at runtime and also
it comes with a slow sort algorithm. As we play with that for very
frame and slices, use GArray instead. Note that we cache some arrays
in the instance as there is no support for stack allocated arrays
in GArray.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1238>
Nicolas Dufresne [Fri, 8 May 2020 21:56:48 +0000 (17:56 -0400)]
codecs: h264decoder: Make get_long_ref_by_pic_num() transfer none
We don't use the extra reference, so let's just avoid the extra
ref/unref.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1238>
Nicolas Dufresne [Wed, 6 May 2020 16:23:34 +0000 (12:23 -0400)]
codecs: h264decoder: Make get_short_ref_by_pic_num() transfer none
We don't use the extra reference, so let's just avoid the extra
ref/unref.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1238>
Stéphane Cerveau [Tue, 19 May 2020 13:39:50 +0000 (15:39 +0200)]
tests: fix nalutils file name
The filename was too long causing issues with ccache
Fix https://gitlab.freedesktop.org/gstreamer/gst-build/-/issues/97
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1281>