| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
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/1610>
|
|
|
|
| |
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1606>
|
|
|
|
|
|
|
|
| |
Fixup for
9b9e39be248389370e80b429da5a528418733483: amc: Fix crash when a sync_meta survives its sink
https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/603
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1604>
|
|
|
|
|
|
|
|
| |
The most common audio sample rate in AV streams is 48kHz, and the most
common device output sample rate is 48kHz. This allows handing of 48kHz
input streams without resampling.
Remove comments about avoiding the use of 48kHz.
|
| |
|
|
|
|
| |
Follow GObject's memory management model
|
|
|
|
| |
Like msdkenc, do not use video memory by default on Windows.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Our context is non-persistent, and we propagate it throughout the
pipeline. This means that if we try to reuse any gstmsdk element by
removing it from the pipeline and then re-adding it, we'll clone the
mfxSession and create a new gstmsdk context as a child of the old one
inside `gst_msdk_context_new_with_parent()`.
Normally this only allocates a few KB inside the driver, but on
Windows it seems to allocate tens of MBs which leads to linearly
increasing memory usage for each PLAYING->NULL->PLAYING state cycle
for the process. The contexts will only be freed when the pipeline
itself goes to `NULL`, which would defeat the purpose of dynamic
pipelines.
Essentially, we need to optimize the case in which the element is
removed from the pipeline and re-added and the same context is re-set
on it. To detect that case, we set the context on `old_context`, and
compare it to the new one when preparing the context. If they're the
same, we don't need to do anything.
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/946
|
|
|
|
|
|
| |
Split it out into a separate function with early exits to make the
flow clearer, and document what the function is doing clearly.
No functional changes.
|
| |
|
|
|
|
|
| |
`gst_object_replace()` is not supposed to be used for unreffing and
NULLing objects.
|
| |
|
|
|
|
|
|
|
|
|
| |
`pipe()` isn't used since 15927b6511bc8304ae144a45c9fbfca88e5dd641,
and `socketpair()` from `#include <sys/socket.h>` is used only in the
examples. In practice, you can use probably also use anything that
allows you to create fd pairs, such as named pipes or anonymous pipes.
We use the cross-platform GstPollFD API in the plugin.
|
|
|
|
|
|
|
|
|
|
| |
property is true
https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/1137
macOS has different dialogs for camera capture and screen capture.
No need to request screen capture permissions, the system detect
screen capture automatically and create request dialog.
|
|
|
|
|
|
|
| |
Since macOS Mojave (10.14), video permissions have to be explicitly
granted by a user in order to open a video device such as a camera.
This commit adds a check for the current permission status, and tries
to request for permission if applicable.
|
|
|
|
|
|
|
| |
We need to ignore the data we get from WASAPI in this case and write
out silence (zeroes).
Initially reported at https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/808
|
|
|
|
|
|
|
|
|
|
|
|
| |
The whole `src_read()` function is a hot loop since the ringbuffer
thread is waiting on us, and printing to the console from inside it
can easily cause us to miss our deadline.
F.ex., if you had GST_DEBUG=3 and we accidentally missed a device
period, we'd trigger the "reported glitch" warning, which would cause
us to miss another device period, and so on. Let's reduce the log
level so that GST_DEBUG=3 is more usable, and only print buffer flag
info when it's actually relevant.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Some audio drivers return varying amounts of data per ::GetBuffer
call, instead of following the device period that they've told us
about in `src_prepare()`.
Previously, we would just drop those extra buffers hoping that the
extra buffers were temporary (f.ex., a startup 'burst' of audio data).
However, it seems that some audio drivers, particularly on older
Windows versions (such as Windows 10 1703 and older) consistently
return varying amounts of data.
Use GstAdapter to smooth that out, and hope that the audio driver is
locally varying but globally periodic.
Initially reported in https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/808
|
|
|
|
| |
bpf = bytes per frame.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We were miscalculating the device period, i.e. the number of frames
we'll get from WASAPI in each IAudioClient::GetBuffer call, due to
a calculation mistake (truncate instead of round).
For example, on my machine when the aux input is set to 44.1KHz, the
reported device period is 101587, which comes out to 447.998 frames
per ::GetBuffer call. In reality we will, of course, get 448 frames
per call, but we were truncating, so we expected 447 and were
discarding one frame every time. This led to glitching, and skew over
time.
Interestingly, I can only see this with 44.1Khz. 48Khz/96Khz are fine,
because the device period is a more 'even' number.
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/806
|
|
|
|
|
| |
CoInitialize is not allowed when targeting UWP and causes a Windows
Application Certification Kit (WACK) error.
|
|
|
|
|
|
|
|
|
|
|
| |
Can be reproduced with:
videotestsrc ! x264enc key-int-max=$N ! \
h264parse ! msdkh264dec ! fakesink sync=1
It happens with any gop size but the smaller is the distance N
between key frames, the quicker it is leaking.
Fixes #1023
|
|
|
|
|
| |
gstwasapiutil.c(173) : warning C4715: 'gst_wasapi_device_role_to_erole': not all control paths return a value
gstwasapiutil.c(188) : warning C4715: 'gst_wasapi_erole_to_device_role': not all control paths return a value
|
|
|
|
|
|
|
| |
The GstDeviceProvider isn't subclass of GstElement.
(gst-device-monitor-1.0:49356): GLib-GObject-WARNING **: 20:21:18.651:
invalid cast from 'GstWasapiDeviceProvider' to 'GstElement'
|
|
|
|
|
|
|
| |
Asking decklink to render audio data seems to be based entirely on
the sample counts which completely disregards the timestamps
we pass to decklink. As a result, we need to explicitly check
for late buffers and drop them ourselves.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Instead of using the information we stored ourselves for the video frame
itself. Which was also the wrong one: it was the mode from the property,
not the autodetected one.
This fixes vanc extraction with mode=auto
|
|
|
|
| |
Do not take device_name if a device has been specified. Do not take device_index into account if a device or a device name has been specified.
|
|
|
|
|
| |
... caused by null pointer dereference. The d3dvideosink object might
not available yet on the handler.
|
|
|
|
|
| |
_amc_gl_free() could be called after the GstAmcVideoDec has been
finalized, in the case downstream still has a ref to a buffer.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
always set caps in ::create()
We don't support negotiation with downstream but simply set caps based
on the buffers we receive. This prevents renegotiation to other formats,
and negotiation to NTSC in mode=auto in the beginning until the first
buffer is received.
As side-effect of this, also remove various other caps handling code
that was working around the behaviour of the default
BaseSrc::negotiate().
|
| |
|
|
|
|
|
| |
The 'MAX' expression used to set segtotal always returned 2 because
the unused and uninitialized variable buffer_frame_count was always 0
|
|
|
|
|
|
|
|
|
|
|
|
| |
ffs() and strcmp() require string.h
gstkmssink.c:255:28: error: implicit declaration of function ‘ffs’ [-Werror=implicit-function-declaration]
crtc_id = res->crtcs[ffs (crtcs_for_connector) - 1];
^~~
gstkmssink.c:590:10: error: implicit declaration of function ‘strcmp’ [-Werror=implicit-function-declaration]
if (!strcmp (property->name, prop_name)) {
^~~~~~
|
|
|
|
| |
On eos, baseclass videoencoder call finish() vfunc instead of drain()
|
|
|
|
|
| |
This plugin is for linux bluetooth stack. So the early termination can save
configure time on Windows (i.e., we can avoid glib subproject fallback)
|
|
|
|
|
|
|
| |
We'll ensure at least 64 byte alignment for AVX2 but 16 byte alignment
is what is required by the decklink SDK.
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/986
|
|
|
|
|
|
| |
We were not setting self->segment and we are using it
when notifying downstream that we handled a REQUEST_KEY_UNIT
event, leading to all sort of criticals.
|
| |
|
|
|
|
|
|
| |
That's what we've supported via autotools build
Fixes: https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/966
|
|
|
|
|
| |
The tarballs that were being spun for 1.16 don't contain these headers
due to this small oversight, so let's add them.
|
|
|
|
| |
This fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/949
|
|
|
|
|
|
|
| |
Check the return value of gst_msdk_context_ensure_context and
abort in case of failure.
https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/945
|
|
|
|
|
|
|
| |
Check the return value of gst_msdk_context_ensure_context and
abort in case of failure.
https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/945
|
|
|
|
|
|
| |
Fix double gst_object_unref for GstMsdkContext.
https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/945
|
|
|
|
|
|
| |
example pipeline:
gst-launch-1.0 videotestsrc ! video/x-raw,format=P010_10LE ! msdkvpp ! \
video/x-raw,format=BGR10A2_LE ! fakesink
|
| |
|
| |
|
| |
|