Commit graph

20562 commits

Author SHA1 Message Date
Seungha Yang
660b5e4a98 videodecoder: Don't assume GstVideoChromaSite and GstVideoColorimetry
Even if given GstVideoChromaSite and/or GstVideoColorimetry has unknown
value(s), assumption for an unknown value should be done by subclass or
downstream element, not a role of video decoder. And subclass might
want to output unknown value as is.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/910>
2020-11-02 14:11:52 +00:00
Seungha Yang
37255eb7dc videodecoder: Remove trailing whitespace
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/910>
2020-11-02 14:11:52 +00:00
Jan Alexander Steffens (heftig)
c4cdb6590e tcpserversink: Don't assume g_socket_get_remote_address succeeds
When the client disconnects immediately after connecting, the remote
address is no longer available.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/908>
2020-10-30 14:01:51 +01:00
Thibault Saunier
69b5cb8a10 video-aggregator: Fix renegotiation when using convert pads
Since 23189c60f4 we started using the
useless result of `modified_caps` which, was never used since it was
introduced 7 years ago (in videomixer2). The intersection is useless and
we should just avoid doing it at all (which was always the case before)
as it can end up failing renegotiation for bad reasons.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/905>
2020-10-29 23:40:21 +00:00
Seungha Yang
d944c27d96 gst-play: Add support for audio mute control
Assign 'm' keyboard input to control audio mute state

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/674>
2020-10-30 01:32:31 +09:00
Nicolas Dufresne
db4567152d tests: allocator: Fix FDMemory portability issue
This fixes few issues in the test but mainly some portability issue reported
on Ubutun. The test now uses a randomly name tempory file located into system
default tempory location and uses glib wrappers when available.

Fixes !895

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/901>
2020-10-29 09:45:25 +00:00
Dinesh Manajipet
ad697e8f97 gl: optimize glcolorbalance by precomputing shader math
Precompute the rgb -> yuv conversion and color balance adjustment math
so that the shader does minimal work per pixel.

Merging these 15+ steps into 3 steps let us jump from choppy
360p video to smooth 720p video on our underpowered embedded system.

If we can remove the clamp() step inside the shader, or apply it after
rgba
conversion, there are more performance benefits to reap. But I am not
sure
what the side effects will be in that case.

<https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/893>

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/893>
2020-10-29 01:16:49 +00:00
Matthew Waters
1516275413 gl/build: use the brcm GL libraries on the rpi
Upstream RPi has moved to a completely separate GL library names now due
to conflicts.

See https://github.com/RPi-Distro/repo/issues/134

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/898>
2020-10-28 19:18:10 +00:00
Tobias Ronge
e2a1aa44df fdmemory: Allow for change of protection mode
After a memory has been unmapped, protection mode can now be changed
when mapping it again.

See https://bugzilla.gnome.org/show_bug.cgi?id=789952.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/895>
2020-10-28 17:11:05 +00:00
Mathieu Duponchelle
eb216e3865 videoaggregator: document and fix locking in convert pad
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/897>
2020-10-28 15:59:14 +00:00
Tim-Philipp Müller
5ecdb2f268 gldeinterlace: fix doc blurb
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/899>
2020-10-28 13:22:09 +00:00
Xavier Claessens
a28a75652e Meson: Use pkg-config generator 2020-10-23 11:19:11 -04:00
Seungha Yang
5aa831223d urisourcebin: Fix crash caused by use after free
OutputSlotInfo doesn't hold ref of queue, so gst_bin_remove()
will free the queue memory.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/888>
2020-10-22 11:42:37 +00:00
Zebediah Figura
e999318fd7 theoradec: Set telemetry options only if they are nonzero
Setting telemetry options, even to zero, causes libtheora to enable an expensive code path. For large enough videos (e.g. 1920x1080) this can increase the time to decode each frame by 30-40 ms, which can be enough to cause noticeable stutter.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/887>
2020-10-22 08:05:20 +00:00
Michael Tretter
c9d15fec7e glslstage: delete shader on finalize of stage
GLSLstage creates the glShader using glCreateShader, but never calls
glDeleteShader if the glShader is not used anymore. This forces the GL
library to keep the compiled shader around, because it might be used in
the future. Therefore, the glShader is leaked whenever a GLSLStage is
destroyed.

Fix the leak by deleting the glShader when finishing the GLSLStage.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/886>
2020-10-21 15:28:09 +02:00
Sebastian Dröge
6af87dee17 audio/videodecoder: Initialize max_errors in instance_init()
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/882>
2020-10-20 12:46:07 +03:00
Sebastian Dröge
ed62e78c6e audio/videodecoder: Don't reset max-errors in reset()
Otherwise setting the property on the elements has no effect at all
because it's immediately reset during startup.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/881>
2020-10-20 11:52:07 +03:00
Seungha Yang
91ed298bb0 examples: Add an uridecodebin3 example
Demonstrate a way to select multiple streams

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/880>
2020-10-19 20:45:38 +09:00
Seungha Yang
89c663616a decodebin3: Store stream-start event on output pad before exposing it
It's required for users to be able to figure out associated GstStream
object with a pad on pad-added callback.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/880>
2020-10-19 20:28:06 +09:00
Sebastian Dröge
825eea9545 Add some missing nullable annotations
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/876>
2020-10-17 15:30:02 +00:00
Sebastian Dröge
3036521fb6 typefind/xdgmime: Validate mimetypes to be valid GstStructure names before using them
On macOS, for example, "text/*" can be returned as mimetype for
plaintext files but we don't allow '*' in structure names and this would
cause critical warnings.

It's a valid mimetype but not a valid structure name.

Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/616

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/875>
2020-10-17 10:42:49 +03:00
Stéphane Cerveau
967e650937 meson: update glib minimum version to 2.56
In order to support the symbol g_enum_to_string in various
project using GStreamer ( gst-validate etc.), the glib minimum
version should be 2.56.0.

Remove compat code as glib requirement
is now > 2.56

Version used by Ubuntu 18.04 LTS

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/874>
2020-10-15 18:20:37 +02:00
Seungha Yang
cea2bccfc6 videoconvert: Enhance debug message to be more human readable
Numerical representation of GstVideoFormat is not debugging
friendly

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/822>
2020-10-14 19:12:51 +00:00
Seungha Yang
bcabdfb0f9 uridecodebin3: Forward upstream events to decodebin3 directly
Otherwise default handler will try to forward it to sink element
or srcpad which might not be available at that moment.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/867>
2020-10-14 18:24:11 +00:00
Seungha Yang
615b1ac579 tests: appsrc: Fix unstable test case
Wait all buffers to be consumed before sending flush seek event,
so that checking timestamp and segment as expected.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/816>
2020-10-14 10:57:19 +00:00
Jan Alexander Steffens (heftig)
23189c60f4 videoaggregator: Limit accepted caps by template caps
This seems like an obvious mistake, since `modified_caps` was created
but not used.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/868>
2020-10-13 15:41:38 +02:00
Jan Alexander Steffens (heftig)
77c327f356 videoaggregator: Log the format name instead of index
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/868>
2020-10-13 15:41:37 +02:00
Will Miller
ac72a6adaa gstrtpbuffer: fix header extension length validation
We validate the header extensions length of an RTP buffer by comparing
it against the block size. Since we multiply the length in words by 4 to
get the length in bytes, a suitably large length could cause a wrapround
of the uint16, giving a lower length which erroneously passes the check
and allows the buffer to be mapped.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/864>
2020-10-12 15:01:22 +01:00
Marijn Suijten
57a23786f3 gl: glslstage: Sync new_default_{fragment,vertex} documentation name
Documentation for the parameter and return value don't show up when
this header mismatches the function it tries to describe.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/814>
2020-10-12 07:20:15 +00:00
François Laignel
40fde5fcad decodebin3: only force streams-selected seqnum after a select-streams
The initial streams-selected message might not match any select-streams,
in which case it is currently overriden with GST_SEQNUM_INVALID.

Related to:

- https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/601

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/860>
2020-10-10 18:00:04 +02:00
Jan Alexander Steffens (heftig)
a6ed17c273 examples/gl/gtk: Add missing dependency on gstgl
Occasionally, a clean build would fail like this:

    In file included from ../subprojects/gst-plugins-base/tests/examples/gl/gtk/gstgtk.c:24:
    ../subprojects/gst-plugins-base/gst-libs/gst/gl/gl.h:25:10: fatal error: gst/gl/gl-enumtypes.h: No such file or directory
       25 | #include <gst/gl/gl-enumtypes.h>
          |          ^~~~~~~~~~~~~~~~~~~~~~~

Add the missing dependency so that the headers are generated beforehand.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/855>
2020-10-10 03:46:39 +00:00
Mathieu Duponchelle
11f12e49eb rtsptransport: support single port for client_port and server_port
This is explicitly specified as valid in the RFC, where the
syntax for both parameters is:

";" "client_port" "=" port [ "-" port ]
";" "server_port" "=" port [ "-" port ]

This is useful for applications where RTCP is either not necessary
or not possible.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/846>
2020-10-09 23:43:33 +02:00
Guillaume Desmottes
44b1fb03fc video-info: clarify GST_VIDEO_INTERLACE_MODE_ALTERNATE doc
Fields really should alternate in this mode.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/852>
2020-10-09 12:02:14 +02:00
Guillaume Desmottes
a3a2992bc8 videodecoder: fix output state interlace-mode
When user is passing the actual interlace-mode when calling
gst_video_decoder_set_interlaced_output_state() it should not be
overidden by the input interlace-mode.

Needed to fix #825 as we want to keep interlace-mode=interleaved from
parsers and have the OMX decoder producing interlace-mode=alternate.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/852>
2020-10-09 11:04:30 +02:00
Guillaume Desmottes
a19a27a4ca videodecoder: add interlace-mode to debug output when setting output state
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/852>
2020-10-09 11:04:30 +02:00
Matthew Waters
52793dbfca tests: add gl structs to abi check
Tested on x86, x86_64, armv7l, aarch64.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/854>
2020-10-09 06:12:30 +00:00
Matthew Waters
ed8f90c930 build: use cpu_family for arch checks
e.g. on 32-bit arm, we may have armv6, armv7l, armv7hf, etc which all
generally have the same layouts.  cpu_family() groups all of these into
just 'arm' that the ABI check table is expecting.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/854>
2020-10-09 06:12:30 +00:00
Jan Alexander Steffens (heftig)
c272a5e1a5 multihandlesink: Don't pass NULL caps to gst_caps_is_equal
Apparently the sinkpad caps can get cleared when shutting down the
pipeline while the sink is working, provoking a critical warning.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/842>
2020-10-08 21:55:38 +00:00
Sebastian Dröge
28ff6b377d timeoverlay: Add elapsed-running-time mode
This takes the first running time and the first after each flush-stop as
an offset for the running time that is rendered.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/737>
2020-10-08 23:51:02 +03:00
Jan Alexander Steffens (heftig)
aa89ae8beb audio: video: Fix in/outbuf confusion of transform_meta
There are three instances where in- and outbuf have been swapped. This
didn't affect the correctness of the libs *filter code, but the
videoscale implementation swapped the arguments of meta->transform_func.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/853>
2020-10-08 18:30:39 +02:00
Xavier Claessens
c66e276550 pango: Add fallback dependency
When we'll depend on Meson >=0.55 this can be replaced by [provide]
section in gst-build's pango.wrap file. The dependency variable name can
also be dropped when pango is updated to use override_dependency:
https://gitlab.gnome.org/GNOME/pango/-/merge_requests/250

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/844>
2020-10-06 05:44:25 +00:00
Seungha Yang
ebeded7339 meson: Always wrap "prefix" option with join_paths() to make Windows happy
Both "\" and "/" separators are allowed on Windows but the problem
is that "\" is not converted to "\\" in this case.
It will result to unknown/unrecognized character escape sequence.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/818>
2020-10-01 19:19:39 +00:00
Xavier Claessens
d867cacf86 meson: Add GL summary
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/836>
2020-09-27 16:54:44 +00:00
Matthew Waters
0236fa8b9e compositor: fix YUY2/UYVY/VYUY blending
Don't overead memory.

Fixup for https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/755

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/823>
2020-09-21 23:51:31 +10:00
Nicolas Dufresne
6643e941be meson: Add a qt5 feature
This allow opting out items of the builds the depends on QT5 library.
Auto-detection of QT5 in cross-build requires host tools to match with the
sysroot, and detection of mis-match is not fully reliable.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/817>
2020-09-15 14:15:36 -04:00
sohwan.park
3cb7540c5c meson: add abi configuration for meson build
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/815>
2020-09-14 14:06:41 +00:00
Matthew Waters
d7abf832af compositor: blend with multiple threads
Increases the throughput of compositing by using more CPU cycles across
multiple threads.  Simple cases (the output contains one pixel from at
most one input) can have up to a 70% increase in throughput.  Not so
simple cases are limited by the region with the most number of
composite operations.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/755>
2020-09-14 14:00:58 +10:00
Marijn Suijten
d0f36c7e13 video: Rename video_color_transfer to video_transfer_function
Rename remaining `gst_video_color_transfer_{encode,decode}` functions on
the `GstVideoTransferFunction` enumeration to
`gst_video_transfer_function_{encode,decode}` permitting
gobject-introspection to turn these into associated functions and place
them under the respective `<enumeration>` block in gir XML files.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/805>
2020-09-12 09:46:44 +03:00
Matthew Waters
b4ea8332f5 videoaggregator: ensure peek_next_sample() uses the correct caps
gst_pad_get_current_caps() may be wrong when there is a renegotiation in
progress for the pad and we have not yet received or selected the buffer
with different caps yet.

Fix by storing the caps through in a similar way to the existing code
for buffer/video-info selection machinery.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/813>
2020-09-11 22:08:30 +10:00
Stian Selnes
eaedb5c2de videodecoder: Bump log level of marking a sync point
Sync points are often important when debugging and deserves DEBUG
level.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/730>
2020-09-10 20:31:10 +02:00