Commit graph

15191 commits

Author SHA1 Message Date
Sebastian Rasmussen 861ca3d678 parse: Unref reference to enclosing bins
Previously all reference to enclosing bins of an element were leaked
when doing delaying setting a property.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=733697
2014-07-28 09:23:01 -03:00
George Kiagiadakis b8b6dbd36d caps: unset the parent refcount of the old features before freeing them in gst_caps_set_features()
Otherwise gst_caps_features_free() asserts and the features structure is leaked
2014-06-27 20:07:28 +01:00
Tim-Philipp Müller 8257fdcb5d caps: gst_caps_is_any() should return TRUE or FALSE
Not some flag value instead of TRUE. Fixes code like
gst_caps_is_any() == TRUE.

https://bugzilla.gnome.org//show_bug.cgi?id=731704
2014-06-27 20:07:04 +01:00
Tim-Philipp Müller 608fb56707 bufferlist: fix buffer leak in _remove() 2014-06-27 20:05:57 +01:00
Thiago Santos 8528026c3b baseparse: avoid returning _OK for _NOT_LINKED
When the parser receives non-aligned packets it can push a buffer
and get a not-linked return while still leaving some data still to
be parsed. This remaining data will not form a complete frame and
the subclass likely returns _OK and baseparse would take that
as the return, while it the element is actually not-linked.

This patch fixes this by storing the last flow-return from a push
and using that if a parsing operation doesn't result in data being
flushed or skipped.

https://bugzilla.gnome.org/show_bug.cgi?id=731474
2014-06-25 12:32:43 -03:00
Wim Taymans 8b9a8e4fb0 info: first handle all miniobjects, then GObjects
First handle all miniobjects before we attempt to dereference the first
field pointer and look at the GType. With the recent glib change to
speed up G_IS_OBJECT, this causes crashes on miniobjects otherwise.
2014-06-08 13:37:39 +01:00
Wim Taymans 8da13087f1 info: GstDateTime does not have a GType as first field
GstDateTime does not have the GType as the first field so we can't use
it to detect its type.
2014-06-08 13:37:35 +01:00
Thiago Santos 0302d3924f multiqueue: post buffering message when queues flush
The buffering status goes back to 0, so inform the application about it

https://bugzilla.gnome.org/show_bug.cgi?id=726423
2014-06-07 10:05:52 +01:00
Evan Nemerson 7603cf5218 queuearray: fix expanding size of queue from 1
Without we would not actually expand and access
memory beyond the allocated region for the array.

https://bugzilla.gnome.org/show_bug.cgi?id=731349
2014-06-07 10:02:14 +01:00
zhouming 56af0c511b baseparse: Pass rate of input segment to output segment
https://bugzilla.gnome.org/show_bug.cgi?id=729701
2014-06-07 10:02:07 +01:00
Edward Hervey d8bdba3102 nettimeprovider: Use non-freed variable
address is only used temporarily. Use the proper variable instead.

CID #1212189
2014-06-07 09:55:57 +01:00
Tim-Philipp Müller 7e0b990429 plugin: fix case where gst_plugin_load_file() didn't set the error on failure 2014-06-07 09:55:20 +01:00
Stian Selnes 6fdec47687 bufferpool: fix log message of buffer pointer 2014-05-01 11:11:03 +02:00
Thiago Santos f8c6552e5a multiqueue: avoid signaling overrun on the first segment
When the first segment has position != 0 and position > max-size-time
it will immediatelly cause the multiqueue to signal overrun.

This can happen easily with adaptive streams when switching bitrates
and starting a new group. The segment for this new group will have
a position that is much greater than 0 and will lead to this issue.
This is particularly harmful when the adaptive stream uses mpegts
that doesn't emit no-more-pads and it might happen that only one
of the stream pads was added when the multiqueue overruns and gets
the group ready for exposing. So the user will only get audio or
video.

The solution is to fallback to the sink segment while the source pad
has no segment.

https://bugzilla.gnome.org/show_bug.cgi?id=729124
2014-04-28 18:12:44 -03:00
Sebastian Dröge d75068d6cf basesrc: Make sure to always hold the LIVE_LOCK when going to the flushing label
https://bugzilla.gnome.org/show_bug.cgi?id=728596
2014-04-20 12:01:45 +02:00
Sebastian Dröge e71d192e6d Release 1.2.4 2014-04-18 11:24:09 +02:00
Sebastian Dröge 7b4becefa5 Update .po files 2014-04-18 11:23:58 +02:00
Vincent Penquerc'h d854327df1 structure: error out when trying to fixate a fraction near an invalid target 2014-04-12 12:22:24 +01:00
Jose Antonio Santos Cadenas 03a093c97c baseparse: Fix memory leak
Queued frames were not released after being pushed, this
caused a leak of the GstBaseParseFrame structure.

https://bugzilla.gnome.org/show_bug.cgi?id=727883
2014-04-12 12:20:10 +01:00
Edward Hervey 70eca443ec gst-launch.1: Playbin2 is dead, long live playbin
Looks like that was the last remaining mention in core ...
2014-04-12 12:17:51 +01:00
Sebastian Dröge def820ddf1 pad: Include event type in debug output when delaying a sticky event because of not-linked 2014-04-12 12:16:40 +01:00
Wim Taymans f24ad01787 launch: place the deep-notify on the right pipeline
If the toplevel bin is not not a pipeline, we place the bin in a
pipeline. Also make sure that we connect to the deep-notify of this new
pipeline because we will g_signal_handler_disconnect() from it later.
2014-04-12 12:16:04 +01:00
Tim-Philipp Müller 2b7412acae docs: fix multiqueue docs for new template names foo_%d -> foo_%u
https://bugzilla.gnome.org/show_bug.cgi?id=726358
2014-04-12 12:10:12 +01:00
George Kiagiadakis 31597fcd68 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-04-12 12:06:48 +01:00
George Kiagiadakis c72ba7e3d9 ghostpad: hold a reference to the target pad while unlinking it
https://bugzilla.gnome.org/show_bug.cgi?id=725809
2014-04-12 12:06:43 +01:00
Wim Taymans 3e043378d8 buffer: remove wrong comment
Refcount and writability are not related for memory objects.
2014-04-12 12:03:37 +01:00
Sebastian Dröge 4494f032d6 parse: Don't dist the bison and flex generated headers
https://bugzilla.gnome.org/show_bug.cgi?id=727253
2014-04-07 12:00:36 +02:00
Sebastian Rasmussen 0b845fc88c docs: Fix typos and remove unknown annotations
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=725517
2014-03-02 21:55:12 +01:00
Wim Taymans cc6ffdbe06 queue2: don't truncate the temp file on shutdown
We want to keep the downloaded file untruncated so that we can use it
again later.

Fixes: https://bugzilla.gnome.org/show_bug.cgi?id=724373
2014-02-18 15:57:23 +01:00
Wim Taymans b73769e673 queue2: Fix merging of ranges
Make a method to get the seeking threshold. If data is further away from
this threshold we want to perform a seek upstream.
When the current downloaded range can merge with the next range,
actually include the data of the next range into the current range
instead of discarding it. Also decide if we seek to the write position
of the merged range or continue reading.
2014-02-18 15:57:23 +01:00
Sebastian Dröge a77aafc54b error: GST_RESOURCE_ERROR_NOT_AUTHORIZED will be available since 1.2.4 2014-02-11 13:28:13 +01:00
Sebastian Dröge 93bf011a74 error: Add RESOURCE_NOT_AUTHORIZED error
This allows to distinguish normal read failures from read failures
where we miss authorization.
2014-02-11 13:28:12 +01:00
Sebastian Dröge 3461ae6d95 Release 1.2.3 2014-02-08 11:36:27 +01:00
Sebastian Dröge ae87b4fb6c Update .po files 2014-02-08 11:35:15 +01:00
Arnaud Vrac 7e3815e3ab multiqueue: do not reduce single queue below current level
When the single queue size was just bumped by 1 to allow more buffers to
be added, the buffers limit could be reduced to the current level when
setting the max-size-buffers property. This would result in a stall
since the queue would not grow anymore at this point.

Prevent this by not reducing a single queue size below the current
number of buffers + 1.

https://bugzilla.gnome.org/show_bug.cgi?id=712597
2014-02-04 17:01:41 +01:00
Sebastian Dröge a7420fe0ec po: Update translations 2014-02-04 16:20:34 +01:00
Thiago Santos c6f8d25557 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:13:47 -03:00
Thiago Santos ddc76753e0 multiqueue: prevent buffering forever with playbin
When prerolling/buffering, multiqueue has its buffers limit set
to 0, this means it can take an infinite amount of buffers.

When prerolling/buffering finishes, its limit is set back to 5, but
only if the current level is lower than 5. It should (almost) never be
and this will cause prerolling/buffering to need to wait to reach the
hard bytes and time limits, which are much higher.

This can lead to a very long startup time. This patch fixes this
by setting the single queues to the max(current, new_value) instead
of simply ignoring the new value and letting it as infinite(0)

https://bugzilla.gnome.org/show_bug.cgi?id=712597
2014-01-15 10:01:59 -03:00
Sebastian Dröge 87cdd96270 segment: gst_segment_offset_running_time() will be available in 1.2.3 2014-01-15 11:14:48 +01:00
Wim Taymans 13c6f035ed tests: improve check, also check stream-time 2014-01-15 11:13:06 +01:00
Wim Taymans 202ba1025f tests: add unit test for segment _offset_running_time()
Add a unit test to check that positive and negative offsets are applied
correctly in various cases.
2014-01-15 11:12:58 +01:00
Wim Taymans 313949a6a6 pad: use new segment offset method to apply the offset
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=721422
2014-01-15 11:12:43 +01:00
Wim Taymans f8582e27da 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-15 11:12:28 +01:00
Thiago Santos 05eaa6bc1b baseparse: do not ignore TIME segments
TIME segments are being ignored and a standard initialized
segment is used instead. This causes issues as not properly detecting
reverse playback or not cliping output based on the segment.

This seems to be a regression from one of the GstSegment/GstEvent
redesigns on the 0.10 -> 1.0 transition
2014-01-14 13:07:59 +01:00
Wim Taymans 3f88d10f3e segment: take offset into account in _to_position()
Take the offset into account when converting between running-time and
segment positions.
2014-01-14 13:07:40 +01:00
Wim Taymans ca5852456a collectpads: take offset into account for expected segment position
The firt valid segment position is start + offset.
Also add some more debug and a FIXME
2014-01-14 13:07:15 +01:00
Thiago Santos 3f2bea0d47 tests: baseparse: add test for reverse playback on passthrough
Baseparse stores buffers for reverse playback to push on the next
DISCONT, the issue was that it wouldn't ever check for a discont
on passthrough mode as it skips all real parsing. This test
was create to verify this issue and prevent it from happening again

https://bugzilla.gnome.org/show_bug.cgi?id=721941
2014-01-13 09:28:04 -03:00
Thiago Santos cd51c9c6d3 tests: baseparse: add basic test for baseparse
Just a small test to check that basic playback works
2014-01-13 09:28:04 -03:00
Thiago Santos 8f2a972071 baseparse: do not accumulate buffers on passthrough mode
If on passthrough during reverse playback, do not accumulate buffers as
baseparse will never check for DISCONT flag to push those buffers.
So just push buffers downstream as if it was forward playback.

https://bugzilla.gnome.org/show_bug.cgi?id=721941
2014-01-13 09:28:04 -03:00
Thiago Santos c8196719e7 baseparse: remove pending_segment as it was being misused
It wasn't required, instead baseparse was using it to check the media
caps to identify if it was handling audio or video.

The pending_segment was removed and a checked_media boolean
replaced it for a more accurate naming.

https://bugzilla.gnome.org/show_bug.cgi?id=721350
2014-01-08 13:59:21 -03:00