]> git.tuebingen.mpg.de Git - paraslash.git/commitdiff
FEC timing improvements.
authorAndre Noll <maan@systemlinux.org>
Sat, 12 Sep 2009 16:16:56 +0000 (18:16 +0200)
committerAndre Noll <maan@systemlinux.org>
Sat, 12 Sep 2009 18:23:07 +0000 (20:23 +0200)
Currently we compute the time of a FEC group as the number of
containing chunks times the chunk time. The time between sending
two slices therefore depends only on the number of chunks the group
contains. Groups containing many slices are sent with larger delays
than groups containing few slices.

This approach is not optimal for the following reason: Consider a group
containing only few slices which is followed by a group containing
many slices. This happens frequently at the end of VBR MP3 files which
contain some seconds of silence or applause at the end because this
last part is often encoded at a lower bitrate than the preceding part.

In this scenario buffer underruns in the receiving application can
easily occur if the previous FEC group has been decoded and completely
fed to the writer before enough slices of the next group have arrived
to decode the second group.

This patch changes the timing of FEC groups such that all but the
first group use the duration of the _previous_ group as the basis
for the timing.


No differences found