Commit graph

64 commits

Author SHA1 Message Date
Thibault Saunier a87b4551a6 Port gtk-doc comments to their equivalent markdown syntax
Modernizing our documentation and preparing a possible move to hotdoc.
This commits also adds missing @title metadatas to all SECTIONs
2017-01-27 16:36:38 -03:00
Tim-Philipp Müller cf0680017e elements: use new gst_element_class_add_static_pad_template()
https://bugzilla.gnome.org/show_bug.cgi?id=762778
2016-02-28 13:10:07 +00:00
Sebastian Dröge 485b15d8a9 output-selector: Make access to the active pad and last buffer thread-safe
Both can be modified from different threads at the same time.
2016-01-16 10:48:02 +01:00
Sebastian Dröge 0e132260a3 output-selector: Notify when the active-pad property is changing 2016-01-16 10:47:36 +01:00
Thiago Santos 25295ee285 output-selector: add drain handling
Release the latest buffer, if any, and then just let
the drain be pushed downstream
2015-03-24 16:21:23 -03:00
Sebastian Dröge 50de594718 output-selector: Constify negotiation mode GEnumValue table 2015-01-21 09:45:36 +01:00
Tim-Philipp Müller 49c6f923de coreelements: mark properties with MUTABLE_PLAYING 2014-09-14 16:08:07 +01:00
Ravi Kiran K N 63a943aa82 output-selector: Send all events to active src pad and EOS to all src pads
Fixes tests/icles/output-selector-test

https://bugzilla.gnome.org/show_bug.cgi?id=729811
2014-09-02 12:33:56 +03:00
Thiago Santos 8ee77efbed outputselector: respect the 'negotiation-mode' property
If the segment event is allowed to be pushed to all pads it
will lead to an assertion of 'sticky event misordering:
segment received before caps' in case the pad-negotiation-mode
is set to 'active' or 'none'.

This patch fixes this by making all sticky events follow the
property like the caps event to prevent misordering warnings.

When a new pad is activated the current sticky events on the
sinkpad are forwarded to it in the proper order.

https://bugzilla.gnome.org/show_bug.cgi?id=723266
2014-01-30 17:06:00 -03: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 Dröge 8ba5fb0b28 outputselector: Don't adjust segment->start to the current time when switching pads
This does not make any sense at all and breaks timestamp->running_time
calculations in unpredictable ways.

https://bugzilla.gnome.org/show_bug.cgi?id=707130
2013-09-02 13:55:08 +02:00
Sebastian Dröge f93c52684a outputselector: Always forward sticky events to all pads 2013-05-09 12:27:12 +02:00
Wim Taymans fac7eb0a50 NEWSEGMENT -> SEGMENT 2012-12-14 15:24:30 +01: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
Edward Hervey d3ffa82639 Remove 0.10-related documentation and "Since" markers 2012-07-10 12:03:27 +02:00
Tim-Philipp Müller a63829b4ff plugins: use new gst_element_class_set_static_metadata() 2012-04-09 13:05:07 +01:00
Tim-Philipp Müller 2836cbee94 Merge remote-tracking branch 'origin/master' into 0.11
Conflicts:
	gst/gsttaglist.c
	plugins/elements/gstoutputselector.c
2012-01-02 02:21:40 +00:00
Thiago Santos 71fe1ad070 output-selector: Do not false warn about unlinked pad
When output-selector didn't receive a newsegment event it would
warn about pad being unlinked when switching pads. Making the logs
wrong and misleading.
2011-12-29 16:59:29 -03:00
Tim-Philipp Müller eaa2d81474 Merge remote-tracking branch 'origin/master' into 0.11
Conflicts:
	gst/gstindexfactory.c
	libs/gst/base/gstbasetransform.c
	plugins/elements/gstfakesink.c
	plugins/elements/gstfakesrc.c
	plugins/elements/gstidentity.c
	plugins/elements/gstinputselector.c
	plugins/elements/gstoutputselector.c

Note: did not merge any of the basetransform changes from 0.10.
2011-12-08 00:39:10 +00:00
Sebastian Dröge 7952a54299 outputselector: Don't send last segment/buffer when no segment was configured yet 2011-12-07 11:01:31 +01:00
Wim Taymans 407f45dc7f event: add STICKY_MULTY events
Add a new event flag for sticky events so that multiple events of that type can
be stored on a pad at the same time. Change the _get_sticky_event() function to
loop over the multiple events of a type.
Change the foreach function to make it possible to removed and modify the sticky
events on a pad.
Use an variable size array now to store the events. This could later be
optimized some more.
2011-11-23 18:05:00 +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 09a8294d36 pad: add parent to the query function 2011-11-16 17:22:56 +01:00
Wim Taymans 06d4828df3 plugins: remove obsolete parent checks 2011-11-16 12:11:12 +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 d169fa8728 fix request pad
Make all request pads take _%u in the template.
Fix up unit tests.
2011-11-03 17:49:45 +01:00
Wim Taymans d8212d941c pad: forward events by default
Always forward all events in the default handler. Previously it used to not
forward caps events by default. It makes more sense to forward the caps events,
if the element is interested in the caps, it will implement an event handler to
retrieve the caps and then it can decide to forward or not. If the element has
no event handler, it probably just doesn't care about caps and it probably is
also not going to modify the data in a way that needs a caps change.
2011-06-09 11:49:20 +02:00
Wim Taymans fa6615dd70 outputselector: fix refcounting of events
_pad_event_forward() takes ownership of the caps.
2011-06-07 10:51:23 +02:00
Wim Taymans acc5e6be2f plugins: use the caps event
Use the caps event and avoid using the setcaps function. Use some of the new pad
forward functions to implement desired behaviour.
2011-06-07 10:04:52 +02:00
Edward Hervey cbac716f98 outputselector: Remove dead assignment 2011-05-31 13:43:47 +02:00
Sebastian Dröge 70e276e920 outputselector: Forward sticky events to newly created srcpads 2011-05-24 16:18:38 +02:00
Sebastian Dröge a46c9c2a62 event: Make SEGMENT event parsing API more consistent with the others 2011-05-18 16:56:43 +02:00
Sebastian Dröge 43e165c93c elements: Update for negotiation related API changes
The filter caps are only forwarded and returned instead
of ANY caps in the core elements because they don't do
anything caps specific.
2011-05-16 15:33:11 +02:00
Wim Taymans bdbc069348 Rework GstSegment handling
Improve GstSegment, rename some fields. The idea is to have the GstSegment
structure represent the timing structure of the buffers as they are generated by
the source or demuxer element.
gst_segment_set_seek() -> gst_segment_do_seek()
Rename the NEWSEGMENT event to SEGMENT.
Make parsing of the SEGMENT event into a GstSegment structure.
Pass a GstSegment structure when making a new SEGMENT event. This allows us to
pass the timing info directly to the next element. No accumulation is needed in
the receiving element, all the info is inside the element.
Remove gst_segment_set_newsegment(): This function as used to accumulate
segments received from upstream, which is now not needed anymore because the
segment event contains the complete timing information.
2011-05-16 11:37:52 +02:00
Wim Taymans 84a1f4ba7f element: use request_new_pad_full as the default
Add GstCaps to request_new_pad so that request_new_pad_full can be removed.
Fix elements.
2011-05-10 16:41:36 +02:00
Wim Taymans c07b57fc05 segment: remove _full version
Rename the _full versions of the functions to the normal function names.
2011-05-09 17:51:07 +02:00
Wim Taymans cac9e8fee2 outputselector: handle NULL pads in some cases 2011-05-06 17:39:08 +02:00
Wim Taymans 6ab7e6c15d Remove pad_alloc, this can now be done better
Remove pad_alloc and all references. This can now be done more efficiently and
more flexible with the ALLOCATION query and the bufferpool objects. There is no
reverse negotiation yet but that will be done with an event later.
2011-04-29 13:26:19 +02:00
Sebastian Dröge 5020738a6d elements: Use G_DEFINE_TYPE instead of GST_BOILERPLATE 2011-04-19 11:45:36 +02:00
Ole André Vadla Ravnås 037efe8738 elements: Fix pad callbacks so they handle when parent goes away
1) We need to lock and get a strong ref to the parent, if still there.
2) If it has gone away, we need to handle that gracefully.

This is necessary in order to safely modify a running pipeline. Has been
observed when a streaming thread is doing a buffer_alloc() while an
application thread sends an event on a pad further downstream, and from
within a pad probe (holding STREAM_LOCK) carries out the pipeline plumbing
while the streaming thread has its buffer_alloc() in progress.
2011-04-13 17:41:17 +02:00
Thiago Santos f552659504 outputselector: Improve get and set caps functions
Improve sink pad getcaps and setcaps by handling the case where
no src pads exist yet
2011-01-10 14:52:05 -03:00
Thiago Santos 757dc90faa output-selector: Add pad-negotiation-mode property
Adds getcaps/setcaps to output-selector and adds a property
to select which type of negotiation should be done.

The available modes are:
 * none:   no negotiation (current behavior), getcaps return ANY and
           setcaps aren't set on any of the peers
 * all:    use all pads (default), getcaps returns the intersection of
           peer pads and setcaps is set on all peers
 * active: getcaps and setcaps are proxied to the active pad

https://bugzilla.gnome.org/show_bug.cgi?id=638381
2011-01-06 18:42:29 +00:00
Tim-Philipp Müller fdd65e382d input-selector, output-selector: minor clean-ups 2010-12-31 00:56:11 +00:00
Thiago Santos 0cb6c9230d outputselector: Avoid losing the last_buffer when switching
This patch makes outputselector take an extra ref when pushing
the last_buffer to avoid it losing it during the switch function.

This makes resend-latest properly work if the active-pad is changed
during the switch function buffer pushing (on a pad probe, for example).

https://bugzilla.gnome.org/show_bug.cgi?id=629917
2010-12-31 00:54:05 +00:00
Thiago Santos 974ca7713a outputselector: Recheck pending switch after pushing buffer
This patch makes output-selector always recheck if there's a
pending pad switch after pushing a buffer, preventing that
it pushes a buffer on the 'wrong' pad.

https://bugzilla.gnome.org/show_bug.cgi?id=629917
2010-12-31 00:54:05 +00:00
Stefan Kost d86c6f1956 various (gst): add missing G_PARAM_STATIC_STRINGS flags
Canonicalize property names as needed.
2010-12-31 00:54:05 +00:00
Stefan Kost d18e7d25f8 outputselector: move the debug init to the boilerplate macro 2010-12-31 00:54:05 +00:00
Benjamin Otte 0b37d8bf36 gst_element_class_set_details => gst_element_class_set_details_simple 2010-12-31 00:54:04 +00:00
Havard Graff 8669fe97bf outputselector: make GST_FORMAT_TIME the default segment format 2010-12-31 00:53:50 +00:00
Tommi Myöhänen b79648c180 outputselector: check for pending srcpad in _get_property()
If there is a pending srcpad, return it instead of active srcpad
in gst_output_selector_get_property() function.
2010-12-31 00:53:50 +00:00