Commit graph

7374 commits

Author SHA1 Message Date
Sebastian Dröge ba7089cf04 pad: Minor code cleanup
!check_sticky()==GST_FLOW_OK is a bit confusing, compared to
check_sticky()!=GST_FLOW_OK.
2014-01-22 11:10:01 +01:00
Sebastian Dröge bac1202cf7 iterator: Properly copy mutexes around when creating a copy of a filter iterator 2014-01-18 14:48:54 +01:00
Stewart Brodie f77d79f2f8 iterator: Preserve the master lock when creating recursive iterator filters with the same lock
This way we make sure that a) the lock is always taken when checking
the cookie and calling the iterator's next functions and b) it is
not taken while calling any of the iterator filter functions.

https://bugzilla.gnome.org/show_bug.cgi?id=711138
2014-01-18 14:48:54 +01:00
Thiago Santos 75fe1004a5 pad: fix sticky event leak after sticky_events_foreach
events_foreach adds an extra ref when giving the event to the
user function. In case it was unrefed by the user, this extra ref
disappeared, but events_foreach still should unref again to
lose its own ref before removing the event from the array.

https://bugzilla.gnome.org/show_bug.cgi?id=722467
2014-01-17 23:11:49 -03:00
Stefan Sauer 0264bbdb46 info: move some env-var checks from gst to gstinfo as well
We were doing some log related initialisation in gst.c after calling
_priv_gst_debug_init(). Just move it there for consistency.
2014-01-16 20:47:53 +01:00
Fabian Kirsch ffe072f694 parse: Some minor fixes
Fix destructor segfaulting
Expect 0 grammar-ambiguities
Fix order of bin-properties assignment

https://bugzilla.gnome.org/show_bug.cgi?id=710034
2014-01-16 15:38:51 +01:00
Sebastian Dröge 1d6136b930 segment: gst_segment_offset_running_time() will be available in 1.2.3 2014-01-15 11:13:00 +01:00
Nicolas Dufresne abddae152d util: Add GST_ROUND_UP_N and GST_ROUND_DOWN_N
These are generic rounding macro that works for any power of two.
2014-01-14 16:22:31 -05:00
Sebastian Dröge f15f4ec8aa parse: Make sure to create and link chains in the order as written
Make this work again:
audiotestsrc ! tee name=t  t.src_0 ! queue ! fakesink  t.src_1 ! queue ! fakesink
and this fail again:
audiotestsrc ! tee name=t  t.src_1 ! queue ! fakesink  t.src_0 ! queue ! fakesink

as tee just counts itself and does not care about the pad names we request
from it.
2014-01-14 15:52:26 +01:00
Sebastian Dröge 156d925cff parse: Remove some C99-style comments 2014-01-14 13:46:24 +01:00
Sebastian Dröge dd086a4e6e parse: Use GSlice for allocating and freeing links and chains 2014-01-14 13:46:24 +01:00
Sebastian Dröge 748690aba1 parse: Add comment about why we disable the "tracing"
It did not print anything useful before anyway, everything
was commented out.

Also remove some unneeded struct members.
2014-01-14 13:46:24 +01:00
Fabian Kirsch 2b33d33185 parse: Refactor grammar, make it more consistent and fix conflicts
https://bugzilla.gnome.org/show_bug.cgi?id=710034
2014-01-14 13:46:22 +01:00
Stefan Sauer 46b18f7a8b gstobject: add FIXME and docs for the disabled notify on parent
We haven't found a way to re-enable emitting notify and deep-notify for parent
changes. Add a FIXME-2.0 and a doc blob on the property. See #693281.
2014-01-09 08:49:40 +01:00
Wim Taymans f664fbd198 segment: take offset into account in _to_position()
Take the offset into account when converting between running-time and
segment positions.
2014-01-08 15:23:00 +01:00
Wim Taymans 6d3fc584d5 pad: use new segment offset method to apply the offset
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=721422
2014-01-08 15:04:00 +01:00
Wim Taymans dc0176e4a0 segment: add method to offset the segment running-time
Add a method that can apply an offset to the calculated running-time of
a segment.
2014-01-08 15:04:00 +01:00
Wim Taymans 42d36b9495 info: debug segment offset field as well 2014-01-08 15:04:00 +01:00
Sebastian Dröge 93ce90f833 pad: Check if new probes need to be called when adding/removing some
This allows blocking a pad, add a new blocking probe, removing
the first probe and then having the second probe called. Which
could then decide that data-flow should actually continue
instead of blocking now.

https://bugzilla.gnome.org/show_bug.cgi?id=721289
2014-01-02 13:33:20 +01:00
Sebastian Dröge d04c8b6d2e pad: Keep an extra ref of the pad when calling an IDLE probe immediately
The callback might destroy the pad.
2013-12-30 19:03:22 +01:00
Sebastian Dröge 0324358ebc pad: Only call IDLE probes if we are actually idle
Also only check the data types for non-IDLE probes. When we
are idle, we have no data type obviously.

Previously we were calling IDLE probes during data flow whenever
a non-blocking probe would be called. The pad was usually not idle
at that time.
2013-12-30 18:53:36 +01:00
Stefan Sauer b571f3ad7d taglist: fix since marker again (1.3 -> 1.4)
Since markers should point to the appropriate stable version.
2013-12-30 14:47:19 +01:00
Stefan Sauer e8023bf470 taglist: fix since-marker in docs (we're in 1.3.X) 2013-12-30 14:40:40 +01:00
Stefan Sauer cb218f2827 taglist: add a tag for midi base note numbers
Audio files containing sampled instruments can have metadata describing the note
that was played on the instrument.
2013-12-30 14:22:37 +01:00
Sebastian Dröge 901cd5560c pad: Don't ignore probe callback return value when immediately calling IDLE probe
https://bugzilla.gnome.org/show_bug.cgi?id=721096
2013-12-30 10:53:09 +01:00
Sebastian Dröge c3181fa5df parse: Use GLib malloc/free/realloc functions
https://bugzilla.gnome.org/show_bug.cgi?id=720100
2013-12-27 12:55:40 +01:00
Wim Taymans 62932b17d7 utils: Add round down 128 macro for completeness 2013-12-20 14:43:57 +01:00
Nicolas Dufresne 59bb1f58bb utils: Add round up 128 macro 2013-12-20 14:43:57 +01:00
Sebastian Dröge a400dd2f47 parse: Don't define yyscan_t twice
https://bugzilla.gnome.org/show_bug.cgi?id=720316
2013-12-14 19:09:05 +01:00
Edward Hervey 3ea6b04c10 gstvalue: Fix comparision of double range
Checking twice the lower bound is great (you never know, it might change
between the two calls by someone using emacs butterfly-mode), but it's a bit
more useful to check the higher bound are also identical.

Detected by Coverity
2013-12-10 18:01:52 -05:00
Víctor Manuel Jáquez Leal 24a766a13b info: return existing category if a debug category is registered twice
If a category with the same name is found when creating a new
one, the found category is returned instead of an invalid pointer.
Fixes issue with gst-vaapi (which uses an internal copy of the
codec parsers) caused by commit ccba9130.

https://bugzilla.gnome.org/show_bug.cgi?id=720036
2013-12-07 19:03:23 +00:00
Sebastian Rasmussen 53ae1b2c9c docs: Fix typos in function/object descriptions
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=720029
2013-12-07 17:11:12 +00:00
Sebastian Rasmussen e8ecf3c407 Fix some typos in code comments and debug messages
https://bugzilla.gnome.org/show_bug.cgi?id=720029
2013-12-07 17:09:39 +00:00
Stewart Brodie e7f514efbc docs: clarify encoding of strings in GstStructures and taglists
https://bugzilla.gnome.org/show_bug.cgi?id=709262
2013-12-06 20:50:19 +00:00
Olivier Crête ccba91308d info: Make sure the same category is not added twice 2013-12-04 17:35:18 -05:00
Olivier Crête e0317288ba info: Protect __categories list in get_category with lock too 2013-12-04 17:35:02 -05:00
Wim Taymans 34db352879 pad: add ACCEPT_INTERCEPT flag
Make a new flag on the pad that tweaks the default behaviour of the
accept-caps function. By default it will check for a subset of the
query-caps result but this is not always desirable. The query-caps
result contains all the constraints to make a good caps decision
upstream but sometimes, like for parsers, not all the constrained caps
fields are known upstream and then a subset check would fail. Switching
to an intersection makes this work again.

See https://bugzilla.gnome.org/show_bug.cgi?id=705024
    https://bugzilla.gnome.org/show_bug.cgi?id=677401
2013-12-03 22:28:09 +01:00
Sebastian Rasmussen 49950e57ad docs: add missing docs, fixing doc errors
* add many missing declarations to sections
 * GstController has been removed, update docs
 * skip GstIndex when generating documentation
 * rephrase so gtkdoc doesn't imagine return value
 * add missing argument description for gst_context_new()
 * document GstOutputSelectorPadNegotiationMode and move to header-file

https://bugzilla.gnome.org/show_bug.cgi?id=719614
2013-12-03 00:11:59 +00:00
Sebastian Rasmussen b40fa2b8c3 docs: cosmetic changes in references/decriptions
* fix typo GstBufferFlag -> GstBufferFlags
 * fix typo GstFeatures -> GstCapsFeatures
 * fix typo GstAllocatorParams -> GstAllocationParams
 * fix typo GstContrlSources -> GstControlSource
 * do not refer to gstcheck as an object
 * make references gtk_init() and tcase_set_timeout() not be references
 * gst_element_get_pad() renamed gst_element_get_static_pad()
 * gst_clock_id_wait_async_full() renamed gst_clock_id_wait_async()
 * _drop_element() is really gst_queue_array_drop_element()
 * gst_pad_accept_caps() was removed, do not refer to it
 * separate GST_META_TAG_MEMORY_STR declaration from description
 * do not describe removed gst_collect_pads_collect()
 * correctly link to GstElementClass' virtual set_context()

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=719614
2013-12-02 21:01:08 +00:00
Olivier Crête 3c4d54fd88 parse: Manually insert priv_gst_parse_yyget/set_column prototypes for older flex
Older versions of flex (before 2.5.36) don't add the prototype, so it must
be added manually. We can't check by the version number, because Debian/Ubuntu
patched it into their 2.5.35 at some point.
2013-11-29 14:02:24 -05:00
Thiago Santos 06737aa972 gstpad: drop assertion on gst_pad_peer_query_position
It is a 'both' query, so it can be sent both ways
2013-11-29 15:03:44 -03:00
Wim Taymans fe36be1c03 Revert "ghostpad: copy sticky events to SRC ghostpads"
This reverts commit 8162a583a4.

Automatically copying the sticky events makes it impossible for apps
and elements to filter the events with event probes. This causes
regressions (See #719437). The best option is to let the app/element
copy and filter the events themselves after the ghostpad target is
set.
2013-11-29 17:02:41 +01:00
Fabian Kirsch 56d74ddb64 parse: fix segfaulting prototype-mismatch
Now YYDEBUG is always set, so check it's value

https://bugzilla.gnome.org/show_bug.cgi?id=712679
2013-11-28 19:05:23 -05:00
Olivier Crête 2a720d2e55 query: Fix gi annotations of gst_structure_new_custom() 2013-11-25 19:07:15 -05:00
Sebastian Rasmussen 7a073cdcda gstutils: Escape stream id format in comments
These must be escaped for gtk-doc to parse the comments without warnings.

https://bugzilla.gnome.org/show_bug.cgi?id=714989
2013-11-22 19:04:32 +00:00
Tim-Philipp Müller 4afa63a8ba gst: g_memmove() is deprecated
Just use plain memmove(), g_memmove() is deprecated in
recent GLib versions.

https://bugzilla.gnome.org/show_bug.cgi?id=712811
2013-11-21 15:04:04 +00:00
Wim Taymans 8162a583a4 ghostpad: copy sticky events to SRC ghostpads
Update the sticky events on SRC ghostpads when retargeting. This ensures
that the ghostpad has the exect same sticky events as the target pad. We
don't want to do this for SINK ghostpads, they got the events from
downstream and we don't want to overwrite them with the target pad
events.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=707621
2013-11-21 14:13:16 +01:00
Wim Taymans e5c5d3de7e pad: move debug function closer to the enum it debugs 2013-11-21 12:28:00 +01:00
Wim Taymans f8dd5550c2 pluginloader: check read/write before closed
first try to read or write on the socket before checking the closed state. This
makes sure we handle all data on the socket before erroring out.
2013-11-18 21:46:11 +01:00
Wim Taymans 388f0ec069 poll: improve debug
So that we can see the return values of functions in the log.
2013-11-18 21:46:10 +01:00