Maintain a separate variable to control src and sink flowreturn values so that
we can unlock the src part without shutting down the sink part.
Add flushing for upstream pull based elements that unblocks our getrange
function. This implements seeking when blocking for more data.
Add some arbitrary threshold before attempting a seek. Add a FIXME for this
because we need to find a sensible threshold based on the input rate.
When in download mode and the requested offset is too far away, attempt to do a
seek request to fetch the data.
Keep track of all downloaded parts and merge ranges when needed.
Fixes#600877
Add an option to automatically remove the temp file (TRUE by default). This
should make it possible for the application to keep the temp file by other means
than hardlinking or holding an fd open.
Fixes#607739
Cast the variable to gint to conform to the printf format used.
It is casted rather than changing the format because the
message is created with a cast to gint too.
queue2 would crash when using small buffer sizes because
it would overflow when calculating the percentage, resulting
in the buffering GstMessage not being created and trying to be
used. This patch uses a gint64 instead of a gint to do the
percentage math, making it harder to overflow.
Using the current fill level of the queue, and the average input
rate, we can determine how long it will take to finish downloading
the whole stream to the temporary file.
Fixes#600726