[vlc-devel] Fixing reported length in a growing file

Bernat Foj Capell bfoj at gnuine.com
Wed Apr 8 17:23:39 CEST 2009


Hello,
I am writing a stream into a file and, some time after this starts, I
start playing the file. However, there is one small problem to this, and
is that the length of the file is not being updated. The position and
time are correctly reported though, so I figure that it's not an
impossible thing to do to update it, and that the problem is that length
is just calculated or read when opening the file because it's not
supposed to change.

Since this is something I'd like to fix I have started looking into the
code, and I found that maybe registering a callback to do it every time
that position and time are also set would do the trick. However, I don't
know if this could originate any efficiency issues, or if it's not
already being done by a good reason. Perhaps if the latter is the case,
having an option to configure this "length reload" would be useful in
these cases when length varies.

In short, I am willing to do it, but I don't know if I am looking in the
right direction, or even if fixing this is a good idea. So, any thoughts
about this?

Cheers,
Bernat




More information about the vlc-devel mailing list