Commit graph

1918 commits

Author SHA1 Message Date
Sebastian Dröge 6a6188a82f valve: Don't drop non-serialized queries when the valve is dropping
Otherwise we end up dropping e.g. CAPS queries, and then upstream just
negotiates to whatever format it wants to. Once the valve is not-dropping
anymore this can easily result in negotiation failing completely.

https://bugzilla.gnome.org/show_bug.cgi?id=746448
2015-03-20 09:32:34 +01:00
Sebastian Dröge 78bdbadc4e funnel: Add support for buffer lists 2015-03-18 09:37:47 +01:00
Sebastian Dröge 5fc2a3fd66 multiqueue: Don't grow queue infinitely if only one pad is linked
This was introduced by
https://bugzilla.gnome.org/show_bug.cgi?id=719893
https://bugzilla.gnome.org/show_bug.cgi?id=722891
but it doesn't make any sense at all and causes huge memory leaks.

https://bugzilla.gnome.org/show_bug.cgi?id=744253
2015-03-15 14:19:17 +00:00
Sebastian Dröge ad161f7df5 streamiddemux: Reset pad counter after removing all pads 2015-03-12 14:42:18 +00:00
HoonHee Lee fadabe8b78 streamiddemux: Add streamiddemux element
Demultiplex a stream to multiple source pads based on the stream ids from the
stream-start events. This basically reverses the behaviour of funnel.

https://bugzilla.gnome.org/show_bug.cgi?id=707605
2015-03-12 14:42:18 +00:00
Sebastian Dröge 53e8e7da75 typefind: Reset segment when deactivating pull mode or not running in pull mode
We use the segment format to detect if we run the streaming thread or not.
Without resetting we might believe we do so, although we only did in the past
and are now running in e.g. push mode.

https://bugzilla.gnome.org/show_bug.cgi?id=745073
2015-03-12 12:59:57 +00:00
hoonhee.lee 8ce1f4d470 funnel: handle GAP event to forwards sticky events into downstream
If no data is coming and funnel receive GAP event, need to forwards sticky events
into downstream if it needs.

https://bugzilla.gnome.org/show_bug.cgi?id=738202
2015-03-10 16:15:35 -04:00
Sebastian Dröge bc77a3fa0a queue2: Signal the sinkpad thread if a flow error happened
It might still be waiting for a query to be handled, or the queue to become
empty again for the next item. Also if downstream returns FLUSHING, flush the
queue like we do in queue and multiqueue.
2015-03-03 12:53:13 +01:00
Sebastian Dröge a941b4651c queue: Wake up the query function on errors from the loop function
Otherwise we might wait forever for serialized queries to be handled as the
loop function is stopped and as such we will never ever dequeue the query and
handle it.

https://bugzilla.gnome.org/show_bug.cgi?id=745319
2015-03-03 12:49:47 +01:00
Arun Raghavan 49a4951a0c input-selector: Drop custom latency query handling
The default latency query handler now implements this logic
2015-02-27 00:49:06 +05:30
Mark Nauwelaerts c3454a85c5 multiqueue: avoid returning downstream GST_FLOW_EOS from previous segment to current upstream segment 2015-02-23 20:08:20 +01:00
Sebastian Dröge 66e8d3b9a0 inputselector: Use a separate query for upstream pads and let it fail if one upstream query fails 2015-02-19 01:16:52 +02:00
Sebastian Dröge f2b27d3962 queue: Remove unused boolean parameter from internal functions 2015-02-18 11:05:19 +02:00
Sebastian Dröge 6369ba06ff queue: Add support for buffer lists 2015-02-18 11:03:08 +02:00
Sebastian Dröge 927666642e queue2: Count the number of buffers in a buffer list for updating the current levels
instead of just assuming one buffer.
2015-02-18 11:03:08 +02:00
Frédéric Wang d7dd082574 fdsrc: use g_ascii_strtoull() to convert size string in uri
sscanf() doesn't handle G_GUINT64_FORMAT well on mingw64 it
appears, leading to compiler warnings.

https://bugzilla.gnome.org/show_bug.cgi?id=744034
2015-02-12 14:50:15 +00:00
Sebastian Dröge 4a5ce862a2 Improve and fix LATENCY query handling
This now follows the design docs everywhere.

https://bugzilla.gnome.org/show_bug.cgi?id=744106
2015-02-11 17:53:04 +02:00
Sebastian Dröge 50de594718 output-selector: Constify negotiation mode GEnumValue table 2015-01-21 09:45:36 +01:00
Vincent Penquerc'h 0bd45dc401 identity: send gap events when dropping buffers 2015-01-14 10:52:40 +00:00
Sebastian Dröge 29d8b9df8b inputselector: Don't dereference NULL pointer
CID 1262286
2015-01-12 16:03:31 +01:00
Tim-Philipp Müller 3390b70d78 inputselector: fix silly GQueue iteration code
Not active by default though.
2015-01-05 00:22:11 +00:00
Sebastian Dröge bc1ec4ec5f inputselector: Use the same waiting function for EOS and non-EOS waiting 2014-12-24 13:46:28 +01:00
Sebastian Dröge a1c183417f inputselector: Wake up all waitings pads directly if we forward the EOS event
Otherwise they might wait a bit longer unnecessarily.

Also do some minor cleanup.
2014-12-24 13:44:09 +01:00
Song Bing 11e4b744f5 inputselector: Block when receiving an EOS event on a deactivated pad
... and only unblock when either a) the pad becomes active and the event
should be forwarded or b) the active pad went EOS itself.

Otherwise it can happen that we switch from a longer track that is not EOS yet
to a shorter track that already is EOS, but the shorter track won't have any
possibility to send its EOS event downstream anymore.

https://bugzilla.gnome.org/show_bug.cgi?id=740949
2014-12-24 13:33:12 +01:00
Sebastian Dröge 12a905929f inputselector: Keep a ref of the currently active sinkpad around
Otherwise we can't be sure that the pointer points to a still existing
pad instance after releasing the lock.
2014-12-23 12:54:50 +01:00
Song Bing 3137043c3a inputselector: Get the active sinkpad again after taking the lock when handling events
It might have changed in the meantime.

https://bugzilla.gnome.org/show_bug.cgi?id=741893
2014-12-23 12:53:58 +01:00
Tim-Philipp Müller ed15125086 typefind: minor cosmetic change
No nee to abbrev variab nam here, nicer to read if full.
2014-12-10 11:17:25 +00:00
Tim-Philipp Müller 691bd8bd87 typefind: use GST_BUFFER_OFFSET_NONE for buffer offset 2014-12-10 11:16:09 +00:00
Edward Hervey f1c2cd60c3 typefind: Propagate input buffer offset
The initial buffers might have non-default offsets, make sure they get
propagated if present.
2014-12-01 10:47:01 +01:00
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
Tim-Philipp Müller f2e4c25588 plugins: fix build on windows
gstelements_private.c: In function 'gst_writev_buffers':
gstelements_private.c:236:51: error: 'EWOULDBLOCK' undeclared
2014-11-30 23:56:06 +00:00
Tim-Philipp Müller 5b50f39015 filesink: use writev() in ::render() to write out memories without merging them 2014-11-30 14:40:46 +00:00
Tim-Philipp Müller 5a4fb5c314 filesink: implement ::render_list() function that uses writev() 2014-11-30 14:40:46 +00:00
Tim-Philipp Müller ad3e12b006 fdsink: use writev() in ::render() to write out memories without merging them 2014-11-30 14:40:46 +00:00
Tim-Philipp Müller dc73245edd fdsink: implement ::render_list() using writev()
Write out multiple buffers possibly containing multiple
memories with one writev() call, without merging the
buffer memories first, like ::render() does currently.
2014-11-30 14:40:46 +00:00
Tim-Philipp Müller 66bdae5f33 plugins: add helper function for writing buffers out with writev() 2014-11-30 14:40:46 +00:00
Thiago Santos 8d835ec400 queue2: percentage is relative to high-percent
When comparing percentage values, compare with 0-100 scale as it
has already been made relative to 0-high_percent, otherwise we mark
the queue as not buffering and report a 50% to the user. This leads to
a buffering stall as the user assumes the queue is still buffering but
it thinks it isn't.

https://bugzilla.gnome.org/show_bug.cgi?id=736969
2014-11-23 05:51:12 -03:00
Thiago Santos 5a759011a0 multiqueue: percentage is an absolute value
multiqueue's queues stored percent value is the percentage from 0
to 100 (max-size-*) and should be compared with the requested limit
(high_percentage) set by the user and not with 100% to check if
buffering should stop. Otherwise we are only stopping buffering when the
queue gets completely full.
2014-11-23 05:51:12 -03:00
Sebastian Dröge 9606e04895 capsfilter: Add an optional delayed caps change mode
In this mode we accept previously set filter caps until
upstream renegotiates to something that is compatible
to the current filter caps.

This allows dynamic caps changes in the pipeline even
if there is a queue between any conversion element
and the capsfilter. Without this we would get not-negotiated
errors if timing is bad.

https://bugzilla.gnome.org/show_bug.cgi?id=739002
2014-11-03 08:09:21 +01:00
Stefan Sauer 9a66e3169f identity: include the actual delta in the message
Including the actual delta in the message makes it easy to see, if the new
buffer is behind or ahead and how much.
2014-10-20 16:39:38 +02:00
Andrei Sarakeev ee93c807e1 multiqueue: Wake up any waiting streams if the current one goes EOS
Otherwise we might have unlinked streams waiting.

https://bugzilla.gnome.org/show_bug.cgi?id=738198
2014-10-20 12:31:42 +02:00
Aleix Conchillo Flaqué 41fa9ad9f2 multiqueue: don't lock multiqueue when pushing serialized queries
If we are pushing a serialized query into a queue and the queue is
filled, we will end in a deadlock. We need to release the lock before
pushing and acquire it again afterward.

https://bugzilla.gnome.org/show_bug.cgi?id=737794
2014-10-09 11:49:49 +03:00
Tim-Philipp Müller 64a0abb0f4 inputselector: fix compilation 2014-10-03 14:04:58 +01:00
Stefan Sauer e3dc7366bd input-selector: extract some common code into helpers 2014-10-03 14:44:48 +02:00
Stefan Sauer 8285002693 input-selector: small code cleanups
Rename TIMESTAMP -> PTS. Move a var down to the scope where it is used. Use
g_queue_free_full().
2014-10-03 14:22:01 +02:00
Stefan Sauer d8bee3c769 inputselector: fix printf format
The padcount is uint. Also add comments to the instance vars.
2014-10-03 13:47:42 +02:00
Luis de Bethencourt ecaac57bbf fakesrc: mark the pattern property as unused
Revert the previous commit which removes the pattern property of fakesrc because
doing so will break ABI. Bringing the property back but marking it as unused
in the property string.

https://bugzilla.gnome.org/show_bug.cgi?id=737683
2014-10-03 10:36:40 +01:00
Luis de Bethencourt 9b34972ba1 fakesrc: removing unused pattern option
Eventhough the "pattern" property of fakesrc can be set, it is never used. The
only pattern supported is the default 0x00 -> 0xff, and if a pattern is set by
the user it is ignored. Removing the unused property and variable.

https://bugzilla.gnome.org/show_bug.cgi?id=737683
2014-10-02 13:45:34 +01:00
Sebastian Dröge 917e4cd985 queue: Add missing break in switch 2014-10-02 14:55:22 +03:00
Sebastian Dröge 594e2f0668 queue: update segment position on GAP events to calculate levels properly
https://bugzilla.gnome.org/show_bug.cgi?id=737498
2014-10-02 11:00:32 +03:00