[vlc-devel] Results of GSOC project - ogg seeking

salsaman salsaman at gmail.com
Fri Aug 6 17:39:45 CEST 2010

Actually I was wrong, there is a way to do this by finding the last
granulepos for the vorbis stream and looking at the vorbis audio rate.
This will give you a precise duration.

Sorry, I hadn't done this because I had not considered ogg files with
no video (only ogg/vorbis).

I can implement this, but not until september now, as it will take a
couple of days to research, implement and test.

In the meantime, you should implement what I suggested earlier, if
DEMUX_GET_LENGTH returns VLC_EGENERIC, do whatever calculation is done
if DEMUX_GET_LENGTH does not exist. This will be needed anyway for ogg
files which contain non-standard video (.ogm)



On Fri, Aug 6, 2010 at 12:12 PM, salsaman <salsaman at gmail.com> wrote:
> On Fri, Aug 6, 2010 at 9:53 AM, Ilkka Ollakka <ileoo at videolan.org> wrote:
>> On Fri, Aug 06, 2010 at 09:07:19AM -0300, salsaman wrote:
>>> OK, sorry about that. I have slightly updated patch 8 to fix this.
>> Yes works ok now, j-b noticed regression on ogg/vorbis duration missing
>> after your patches, and I see it too.
> I am not sure how to fix this, because in the original ogg.c there was
> no control function for DEMUX_GET_LENGTH
> I have implemented this control since it is needed for dirac and
> theora. If there is no dirac or theora stream then it just returns
> VLC_EGENERIC. So I don't know how the length was calculated before my
> changes, but you get VLC_EGENERIC then you should use that alternate
> method.
> Also the definition of b_seekable can be removed from line 438 in
> ogg.c (patch 8)
> But I am running very short of time...
> Gabriel.

More information about the vlc-devel mailing list