Commit graph

18236 commits

Author SHA1 Message Date
Nirbheek Chauhan
c80a1fd64c meson: host_machine.system() is darwin even on iOS
Also use host_system everywhere.
2018-07-25 16:02:06 +05:30
Nirbheek Chauhan
38ec95460f meson: Don't add static printf library to executables
They should only need to link to libgstreamer.
2018-07-25 16:02:06 +05:30
Nirbheek Chauhan
054fa3aa2e meson: Use new define_variable: feature instead of run_command() 2018-07-25 14:25:59 +05:30
Nirbheek Chauhan
6935d3f1db meson: Small cleanup, unused variable 2018-07-25 14:25:59 +05:30
Nirbheek Chauhan
415e0e68af meson: Use copy: true for configure_file()
Fixes a warning.
2018-07-25 14:25:59 +05:30
Sebastian Dröge
7bee79426d typefindhelper: Mark extension in gst_type_find_helper_get_range() as allow-none
It always allowed NULL and even said so in the documentation.
2018-07-25 01:12:49 +03:00
Sebastian Dröge
d196b0b904 typefind: Add _with_extension() variants for typefinding data or a buffer
And make use of that in the typefind element to also be able to make use
of the extension in push mode. It previously only did that in pull mode
and this potentially speeds up typefinding and might also prevent false
positives.

https://bugzilla.gnome.org/show_bug.cgi?id=796865
2018-07-25 01:12:11 +03:00
Sebastian Dröge
b079334c1c gst: Simplify some boolean expressions
(!x || (x && y)) is the same as (!x || y)

https://bugzilla.gnome.org/show_bug.cgi?id=796847
2018-07-24 09:58:31 +03:00
Sebastian Dröge
2aa9ad9c62 Revert "pad: Handle changing sticky events in pad probes"
This reverts commit 11e0f451eb.

When pushing a sticky event out of a pad with a pad probe or pad offset,
those should not be applied to the event that is actually stored in the
event but only in the event sent downstream. The pad probe and pad
offsets are conceptually *after* the pad, added by external code and
should not affect any internal state of pads/elements.

Also storing the modified event has the side-effect that a re-sent event
would arrive with any previous modifications done by the same pad probe
again inside that pad probe, and it would have to check if its
modifications are already applied or not.

For sink pads and generally for events arriving in a pad, some further
changes are still needed and those are tracked in
  https://bugzilla.gnome.org/show_bug.cgi?id=765049

In addition, the commit also had a refcounting problem with events,
causing already destroyed events to be stored inside pads.
2018-07-23 23:17:54 +03:00
Mathieu Duponchelle
9831c9bbdb bus: add missing (out) annotation to get_poll_fd() 2018-07-20 23:52:01 +02:00
Thibault Saunier
1f3ef7aa01 basetransform: Do not check if NULL is an emtpy caps
gst_base_transform_transform_caps can return NULL in various conditions
thus we should not treat its result as valid caps.

In all other places NULL is properly handled.
2018-07-18 21:18:56 -04:00
Olivier Crête
4f3aea316a sink: Only add processing latency if upstream is live
Only add it if upstream is live, otherwise leave the latency at 0.

https://bugzilla.gnome.org/show_bug.cgi?id=640610
2018-07-16 13:04:44 -04:00
Olivier Crête
f79b871a6a pipeline tests: Add test for processing latency 2018-07-16 11:54:15 -04:00
Thibault Saunier
d93076f826 gst-inspect: Sort properties names
Making it simpler to find properties you are looking for when reading.
2018-07-13 08:54:01 -04:00
Thibault Saunier
b4d93abb24 basesink: Minor GI warning fix. 2018-07-13 08:52:55 -04:00
Sebastian Dröge
99a534271a sample: Set buffer/caps/buffer-lists to NULL correctly when replacing them with NULL 2018-07-10 08:48:47 +02:00
Sebastian Dröge
cb51bd6b31 bufferlist: Prevent gst_buffer_list_foreach() from modifying non-writeable lists
Previously gst_buffer_list_foreach() could modify (drop or replace)
buffers in non-writable lists, which could cause all kinds of problems
if other code also has a reference to the list and assumes that it stays
the same.

https://bugzilla.gnome.org/show_bug.cgi?id=796692
2018-07-09 09:45:45 +02:00
Sebastian Dröge
111faa58c0 buffer: Add test to ensure that memories in a non-writable buffer are not writable
https://bugzilla.gnome.org/show_bug.cgi?id=796692
2018-07-09 09:45:45 +02:00
Sebastian Dröge
13a45c0a38 bufferlist: Add test to ensure that buffers in an non-writable list are not writable
https://bugzilla.gnome.org/show_bug.cgi?id=796692
2018-07-09 09:45:45 +02:00
Sebastian Dröge
6fa351407a miniobject: Add parent pointers to the miniobject to influence writability
Every container of miniobjects now needs to store itself as parent in
the child object, and remove itself again at a later time.

A miniobject is only writable if there is at most one parent, and that
parent is writable itself, and if the reference count of the miniobject
is 1.

GstBuffer (for memories), GstBufferList (for buffers) and GstSample (for
caps, buffer, bufferlist) was updated accordingly.

Without this it was possible to have e.g. a bufferlist with refcount 2
in two places, modifying the same buffer with refcount 1 at the same
time.

https://bugzilla.gnome.org/show_bug.cgi?id=796692
2018-07-09 09:45:45 +02:00
Thibault Saunier
8f76257ac0 check: Add a fail_unless_equals_clocktime macro for convenience 2018-07-08 20:56:16 -04:00
Nicolas Dufresne
5c2f07d303 base: Add processing deadline API to win32 def
https://bugzilla.gnome.org/show_bug.cgi?id=640610
2018-07-07 09:17:27 -04:00
Olivier Crête
a7f9c80220 basesink: Add processing deadline
The processing deadline is the acceptable amount of time to process the media
in a live pipeline before it reaches the sink. This is on top of the algorithmic
latency that is normally reported by the latency query. This should make
pipelines such as "v4lsrc ! xvimagesink" not claim that all frames are late
in the QoS events. Ideally, this should replace max_lateness for most applications.

https://bugzilla.gnome.org/show_bug.cgi?id=640610
2018-07-07 09:05:26 -04:00
Bastian Köcher
cd3e55c38e gstreamer: fix install dir for configure files
Nixos installs into a non-standard includedir.

https://bugzilla.gnome.org/show_bug.cgi?id=794856
2018-07-07 12:42:17 +02:00
Nicolas Dufresne
9722e89644 structure: Update doc error in ARRAY/LIST helpers 2018-07-04 14:00:35 -04:00
Philippe Normand
cc55b304ef protection: Release decryptors list, even if it's empty
https://bugzilla.gnome.org/show_bug.cgi?id=796651
2018-06-25 16:38:13 +01:00
Tim-Philipp Müller
2db8e3705f Update for g_type_class_add_private() deprecation in recent GLib
https://gitlab.gnome.org/GNOME/glib/merge_requests/7
2018-06-24 12:49:14 +02:00
Edward Hervey
eeb30c2a97 concat: Properly forward the SEGMENT seqnum 2018-06-19 07:27:33 +02:00
Sebastian Dröge
8f496b7392 event: Unset SNAP flags when creating a new seek event without KEY_UNIT flag
The SNAP flags only make sense in combination with the KEY_UNIT flag,
and without they expose all kinds of unexpected behaviour in various
elements that don't expect this from happening.

Also warn if this ever happens.

https://bugzilla.gnome.org/show_bug.cgi?id=796558
2018-06-18 10:31:16 +03:00
Sebastian Dröge
1908daf29c event: Require writable events for setting the running-time-offset and sequence number
Otherwise multiple code paths with the same event could change the
values on each other.

https://bugzilla.gnome.org/show_bug.cgi?id=796615
2018-06-18 10:30:51 +03:00
Guillaume Desmottes
6dba0d91ed gst_structure_to_string: display actual value of pointers
We used to always display "NULL" which was pretty confusing when
debugging.

https://bugzilla.gnome.org/show_bug.cgi?id=794355
2018-06-15 11:37:24 +02:00
Thibault Saunier
8833ca942e stream: Add some missing API safe guards 2018-06-13 16:27:24 -04:00
Tim-Philipp Müller
b0777476ff poll: minor docs clarification
'Not implemented' could be misinterpreted to mean that
the API doesn't even exist there.
2018-06-08 17:58:43 +01:00
Tim-Philipp Müller
c441f75595 win32: update for new API 2018-06-08 17:57:01 +01:00
Guillaume Desmottes
b2593133b5 poll: add API to watch for POLLPRI
Windows doesn't seem to have an equivalent of POLLPRI so disabled those
functions on this platform.

This API can be used, for example, to wait for video4linux events which
are using POLLPRI.

https://bugzilla.gnome.org/show_bug.cgi?id=794977
2018-06-08 11:53:55 -04:00
Guillaume Desmottes
1e321eb51f poll: stop treating on POLLPRI as 'read'
Current code was considering "can read" as having either POLLIN or POLLPRI being
set.
This may lead to client being awaken because of POLLPRI, starting a blocking
read and getting stuck because there is actually nothing to read.

This patch removes POLLPRI handling in read code and I'll add specific
API to wait for POLLPRI.

https://bugzilla.gnome.org/show_bug.cgi?id=794977
2018-06-08 11:53:55 -04:00
Edward Hervey
d34f046029 baseparse: Ensure seqnum consistency
We need all relevant events of a segment to have consistent seqnum:
* GST_EVENT_SEGMENT
* GST_EVENT_EOS

If we are push-based and create a new segment, use the same seqnum
as the upstream event.

If we are pull-based, use the seqnum of that newly created segment
event everywhere
2018-06-05 17:02:18 +02:00
Edward Hervey
52d4ae7680 message: Only allow setting valid seqnum on messages
If we want to make sure we never end up with invalid seqnum on
messages let's forbid setting them.
2018-06-05 17:01:05 +02:00
Edward Hervey
14e849927d event: Only allow setting valid seqnum on events
If we want to make sure we never end up with invalid seqnum on
events let's forbid setting them.
2018-06-05 16:59:50 +02:00
Edward Hervey
5b0fe8d174 bin: Make sure we don't use invalid seqnums on messages
There is a possibility that the accumlation functions don't set
a seqnum. Make sure we only set/override the seqnum of the new
messages if we *have* a valid upstream seqnum to use
2018-06-05 16:58:21 +02:00
Dimitrios Katsaros
ac7f8b6337 queue2: use GstQueueArray
When using queue2 as a queue it was using GQueue with
individually allocated queue items, so two allocs for
each item. With GstQueueArray we can avoid those.

https://bugzilla.gnome.org/show_bug.cgi?id=796483
2018-06-04 11:10:05 +01:00
Mike Wey
51b97d7403 dataqueue: add some missing introspection annotations
https://bugzilla.gnome.org/show_bug.cgi?id=796488
2018-06-03 19:42:17 +01:00
Edward Hervey
dfe5467209 baseparse: Documentation improvements
* Remove references to old functions and methods
* Use proper #ClassName.vmethod() decorator for vmethod
2018-05-30 14:06:06 +02:00
Thibault Saunier
cc869065a5 meson: Add an option to activate extra checks
And activate them by default as with autotools
2018-05-22 16:31:21 +02:00
Tim-Philipp Müller
724cc53b28 meson: rename gtkdoc option to gtk_doc 2018-05-21 23:10:21 +01:00
Edward Hervey
dea69f4c1e datetime: Update/fix documentation 2018-05-21 11:37:00 +02:00
Edward Hervey
438c1c116d sample: Update documentation 2018-05-21 11:36:42 +02:00
Edward Hervey
580f94ee97 gst: Add an example to GST_STATIC_PAD_TEMPLATE macro 2018-05-21 11:17:30 +02:00
Mark Nauwelaerts
a7456eec0d gst: add some GIR array annotations 2018-05-21 09:15:09 +02:00
Tim-Philipp Müller
661490d60d meson: add 'nls' option to disable translations
And enable by default. Was implicitly disabled because
ENABLE_NLS was not defined.
2018-05-20 14:07:39 +01:00