mirror of
https://github.com/Rafostar/clapper.git
synced 2025-08-29 23:32:04 +02:00
clapper: Do not reset "adaptive-bandwidth" to zero
When new instance of adaptive demuxer is created (different video is played) this prop value would become zero. We want to avoid that and instead report only bandwidth after fragment is downloaded, so when video will be unplayable, next one will not start from lowest quality.
This commit is contained in:
@@ -726,6 +726,11 @@ _adaptive_demuxer_bandwidth_changed_cb (GstElement *adaptive_demuxer,
|
||||
|
||||
g_object_get (adaptive_demuxer, "current-bandwidth", &bandwidth, NULL);
|
||||
|
||||
/* Skip uncalculated bandwidth from
|
||||
* new adaptive demuxer instance */
|
||||
if (bandwidth == 0)
|
||||
return;
|
||||
|
||||
GST_OBJECT_LOCK (self);
|
||||
if ((changed = bandwidth != self->bandwidth))
|
||||
self->bandwidth = bandwidth;
|
||||
|
Reference in New Issue
Block a user