Especially drop tag events when flushing to not send them over
and over again.
Should've been in the last commit already but I forgot to call
git rebase --continue...
basesrc's default event handler returns TRUE regardless of whether the
event is handled or not. This fixes the handler to conform with the
expected behaviour (which is to only return TRUE when the event has
actually benn handled). gst_bin_do_latency_func() depended on this
(incorrect) behaviour, and is now modified as well.
(Remaining 1-liner change in gstbasesrc.c is to keep gst-indent happy)
Deal with the hints from gtk-doc and fix the xrefs. Apply a work-around for ()
precedence over @. Move "MT Safe" text to doc body in many places. Trim eol
whitespaces.
Only go into LIVE_WAIT when the are not live_running and only stop waiting when
live_running is TRUE. If we don't loop, we could deadlock when called from
outside of basesrc, such as baseaudiosrc.
Fixes#635785
Make the _get_caps functions behave like the _get_caps_reffed variants and
remove the _reffed variants. This means that _get_caps doesn't return a writable
caps anymore and an explicit _make_writable() is needed before modifying the
caps.
_get_range() is a pad function set by ourselves, therefore we're certain that
the parent is a GstBaseSrc.
Speeds up _get_range by 38%, and the total call by 30%. (valgrind instruction
calls measurements).
Fixes#610246
Updating the segment values must only be done while holding the
STREAM_LOCK and OBJECT_LOCK. This means, reading can be done as
long as one of them is held, not both, which removes some lock-unlock
blocks from performance critical code paths.
Also document, that gst_base_src_set_format() *must* be called in
states <= READY and add an assertion for this. Changing the format
later will completely mess up the segment information.
Set the pad flushing and stop the pad task when the initial seek fails
during activation. Avoids racy calls into the _create() function when
BaseSrc::stop() has already run.
Fixes: #603059
Also, fix some misspelled comments.
There's not much point in using GST_DEBUG_FUNCPTR with GObject
virtual functions such as get_property, set_propery, finalize and
dispose, since they'll never be used by anyone anyway. Saves a
few bytes and possibly a tenth of a polar bear.
When we quickly switch from PLAYING to PAUSED and back to PLAYING it's possible
in some cases that the task refuses to start, This is because when we go to
PAUSED, we unschedule the clock timeout, which could return UNSCHEDULED when
we're back to PLAYING, causing the task to PAUSE again with a wrong-state.
This patch checks if we are running when we return with an UNSCHEDULED return
value and if we are, try to create a new buffer.
Fixes#597550
In most places in core and baseclasses we just need the caps to do caps-
intersections. In that case ref'ed caps are enough (no need to copy).
This patch also switches the code to use the new functions.
API: gst_pad_get_caps_refed(), gst_pad_peer_get_caps_refed()