Commit graph

161 commits

Author SHA1 Message Date
Sebastian Dröge
154eefecc9 Don't compare booleans for equality to TRUE and FALSE
TRUE is 1, but every other non-zero value is also considered true. Comparing
for equality with TRUE would only consider 1 but not the others.

Also normalize booleans in a few places.
2014-12-01 09:51:37 +01:00
Evan Nemerson
2759882379 introspection: add missing (nullable) annotations to return values
Support for (nullable) was added to G-I at the same time as nullable
return values.  Previous versions of G-I will not mark return values as
nullable, even when an (allow-none) annotation is present, so it is
not necessary to add (allow-none) annotations for compatibility with
older versions of G-I.

https://bugzilla.gnome.org/show_bug.cgi?id=730957
2014-06-26 18:56:38 +02:00
Evan Nemerson
e10266e3f3 docs: convert NULL, TRUE, and FALSE to %NULL, %TRUE, and %FALSE
This should help improve documentation generated for
languages other than C.

https://bugzilla.gnome.org/show_bug.cgi?id=730961
2014-05-30 00:20:27 +01:00
Tim-Philipp Müller
6eb6d9ec38 docs: remove outdated and pointless 'Last reviewed' lines from docs
They are very confusing for people, and more often than not
also just not very accurate. Seeing 'last reviewed: 2005' in
your docs is not very confidence-inspiring. Let's just remove
those comments.
2014-04-26 21:21:51 +01:00
Stefan Sauer
4a38acaa10 pad: add debug helper for GstPadLinkReturn names
Add a helper like gst_flow_get_name() for GstPadLinkReturn. Use this in core.
API: gst_pad_link_get_name()
2014-03-11 21:50:36 +01:00
George Kiagiadakis
5973f8c2ca ghostpad: use gst_pad_get_peer to acquire a reference to the target pad
This ensures that the lock of the internal pad is held while referencing
it's peer (= the target pad), which ensures that the peer is not
going to be unlinked/destroyed in the meantime.

https://bugzilla.gnome.org/show_bug.cgi?id=725809
2014-03-06 20:46:28 +01:00
George Kiagiadakis
4fc671e801 ghostpad: hold a reference to the target pad while unlinking it
https://bugzilla.gnome.org/show_bug.cgi?id=725809
2014-03-06 20:46:28 +01: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
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
Nicolas Dufresne
4656d18fd5 Add few missing allow-none annotation 2013-07-03 14:25:07 -04:00
Tim-Philipp Müller
666c8c11c6 Fix FSF address
https://bugzilla.gnome.org/show_bug.cgi?id=687520
2012-11-03 20:44:48 +00:00
Wim Taymans
2cf4689503 ghostpad: also ref the internal pad for activate functions
Also take a ref to the internal pad in the activate functions
2012-09-27 11:06:06 +02:00
Olivier Crête
e60ee132ce proxypad: Hold a reference to the internal pad while pushing through it
https://bugzilla.gnome.org/show_bug.cgi?id=684809
2012-09-27 10:53:45 +02:00
Jan Schmidt
8d8608c23b ghostpad: Make some debugging more verbose
Also, remove an unnecessary #include in input-selector
2012-08-31 06:25:37 -07:00
Wim Taymans
961151e569 ghostpad: remove custom function
Remove custom pad functions, the default ones are better.
2012-07-18 17:49:32 +02:00
Edward Hervey
75066960e3 gstghostpad: Forward queries in both direction
Use the peer of the internal pad to forward them, instead of the
target which only exists for the ghostpad (and not the internal
proxy pad).
2012-07-18 12:07:26 +02:00
Edward Hervey
d3ffa82639 Remove 0.10-related documentation and "Since" markers 2012-07-10 12:03:27 +02:00
Wim Taymans
2cab15c9f6 docs: improve API docs 2012-06-15 12:57:24 +02:00
Matej Knopp
5c50c6612a ghostpad: set result on accept caps query when there is no peer 2012-05-01 13:32:41 +02:00
Olivier Crête
fd675fa385 gstpad: Fix typo in docstring 2012-03-27 15:25:58 -04:00
Peteris Krisjanis
02f721f7ea gst: Changed introspection transfer flag to (transfer floating)
for gst_pad_new, gst_ghost_pad_new and gst_bin_new constuctors. Fixes
segfaults due of transfer full and floating ref problem.
2012-01-25 15:05:21 +01:00
Wim Taymans
fda5685a15 ghostpad: fix print format 2011-11-21 17:43:04 +01:00
Wim Taymans
2f1ed65339 pad: Merge pad mode activation functions
Add the pad mode to the activate function so that we can reuse the same function
for all activation modes. This makes the core logic smaller and allows for some
elements to make their activation code easier. It would allow us to add more
scheduling modes later without having to add more activate functions.
2011-11-21 13:29:05 +01:00
Wim Taymans
39a5e26ea9 pad: add parent to activate functions 2011-11-18 13:54:29 +01:00
Wim Taymans
612b1fbb14 pad: add parent to other functions
Add parent to chain, chain_list, getrange and event functions.
2011-11-17 12:40:45 +01:00
Wim Taymans
361a7ae44d add parent to internal links 2011-11-16 17:49:46 +01:00
Wim Taymans
09a8294d36 pad: add parent to the query function 2011-11-16 17:22:56 +01:00
Wim Taymans
b5c3e254b1 pad: remove getcaps and use caps query
Remove the getcaps function on the pad and use the CAPS query for
the same effect.
Add PROXY_CAPS to the pad flags. This instructs the default caps event and query
handlers to pass on the CAPS related queries and events. This simplifies a lot
of elements that passtrough caps negotiation.
Make two utility functions to proxy caps queries and aggregate the result. Needs
to use the pad forward function instead later.
Make the _query_peer_ utility functions use the gst_pad_peer_query() function to
make sure the probes are emited properly.
2011-11-15 11:20:48 +01:00
Wim Taymans
37318a8cd2 pad: remove GstPadFixateCapsFunction
The fixate caps function was not used externally and we have vmethods in the
base classes where it is needed.
Update some docs.
simplify some fixate functions in the base classes. Also pass the untruncated
caps to the vmethod.
2011-11-10 10:58:42 +01:00
Wim Taymans
b7966c0c7d pad: make an ACCEPT_CAPS query
Replace the acceptcaps function with a query.
2011-11-09 17:36:00 +01:00
Wim Taymans
6cc7254166 remove query types
It was not really useful
2011-11-09 11:47:10 +01:00
Wim Taymans
ac9e5533b5 pad: add more queries
Add more query functions to prepare for doing more with queries
2011-11-09 11:22:36 +01:00
Wim Taymans
9c0d8ca718 Merge branch 'master' into 0.11
Conflicts:
	gst/gstelement.h
	gst/gstghostpad.c
	gst/gstminiobject.c
2011-11-08 12:54:15 +01:00
Tim-Philipp Müller
16dcd5e958 docs: fix Since: markers for API added after 0.10.35 2011-11-08 00:32:36 +00:00
Wim Taymans
a1d82bec39 Merge branch 'master' into 0.11
Conflicts:
	gst/gstghostpad.c
2011-11-03 11:30:52 +01:00
Nicolas Dufresne
391568efde ghostpad: Don't cache internal proxy pad target
The internal proxy pad target is simply a cache of the internal proxy pad
peer. This patch uses the well implement GstPad peer handling to obtain the
target. This fixes issues with target not being set in both direction when
two ghostpads are linked together (empty bin).

https://bugzilla.gnome.org/show_bug.cgi?id=658517
2011-11-03 09:27:00 +01:00
Thiago Santos
a171e684ac ghostpad: Do not unref the internal pad twice
g_value_unset should already unref the internal proxypad, no
need to do it again
2011-10-12 18:14:46 -03:00
Edward Hervey
009bc19528 ghostpad: If we don't control a pad/template, return proper caps
If there's a filter, we can return that in _get_caps()
2011-10-10 17:04:39 +02:00
Sebastian Dröge
43538e2e75 Merge branch 'master' into 0.11
Conflicts:
	docs/design/draft-buffer2.txt
	docs/design/part-TODO.txt
	docs/design/part-block.txt
	docs/design/part-bufferlist.txt
	docs/design/part-caps.txt
	docs/design/part-element-transform.txt
	docs/design/part-events.txt
	docs/design/part-negotiation.txt
	gst/gstcaps.c
	gst/gstevent.h
	gst/gstghostpad.c
	gst/gstinterface.c
	gst/gstpad.c
	gst/gstpad.h
	gst/gstutils.c
	libs/gst/base/gstbasesink.c
	libs/gst/base/gstbasesrc.c
	libs/gst/base/gstbasetransform.c
	libs/gst/base/gsttypefindhelper.c
	plugins/elements/gstcapsfilter.c
	plugins/elements/gsttee.c
	tests/check/generic/sinks.c
	tools/gst-launch.1.in
2011-09-08 14:28:23 +02:00
Piotr Fusik
14f5518f3d docs, gst: typo fixes
https://bugzilla.gnome.org/show_bug.cgi?id=658449
2011-09-07 18:03:17 +01:00
Stas Sergeev
fcadf09779 ghostpad: Use gst_pad_set_caps() instead of manually changing caps
gst_pad_set_caps() does essentially the same but additionally calls
the pad's setcaps function.

Fixes bug #658076.
2011-09-07 13:38:47 +02:00
Wim Taymans
9177367984 ghostpad: improve debug
Log a debug line when there is no target pad and when this makes the default
implementation fail.
Take the internal pads directly when we can.
2011-06-20 16:53:03 +02:00
Wim Taymans
5426527b70 ghostpad: remove setcaps functions
Remove the setcaps functions, it is now handled with the caps event.
2011-06-02 19:23:47 +02:00
Wim Taymans
7e6d579301 scheduling: port to new scheduling query 2011-05-24 17:39:56 +02:00
Wim Taymans
25989f3c8d ghostpad: avoid calling setcaps too many times
Don't call setcaps, the caps event will take care of propagating the caps on all
pads.
2011-05-18 18:52:22 +02:00
Wim Taymans
5642f9db8c ghostpad: remove unused code
The code to make sure that caps are properly set on both pads, it now happens
automatically with the caps event.
2011-05-17 18:21:38 +02:00
Sebastian Dröge
3d2127f865 Revert "query: allow _make_writable on query handlers"
This reverts commit cf4fbc005c.

This change did not improve the situation for bindings because
queries are usually created, then directly passed to a function
and not stored elsewhere, and the writability problem with
miniobjects usually happens with buffers or caps instead.
2011-05-17 11:21:41 +02:00
Sebastian Dröge
c096199fb9 Revert "ghostpad: fix g_return_* with new query"
This reverts commit 877c1c28ff.
2011-05-17 11:21:36 +02:00
Wim Taymans
877c1c28ff ghostpad: fix g_return_* with new query 2011-05-16 17:53:48 +02:00
Sebastian Dröge
b935a814d9 Merge branch 'master' into 0.11
Conflicts:
	configure.ac
	docs/gst/gstreamer-sections.txt
	gst/gstbin.c
	gst/gstelement.c
	gst/gstelement.h
	gst/gstghostpad.c
	gst/gstminiobject.c
	gst/gstminiobject.h
	libs/gst/base/gstbasesrc.c
	libs/gst/base/gstbasetransform.c
	plugins/elements/gstinputselector.c
	tests/check/gst/gstminiobject.c
2011-05-16 16:53:04 +02:00