Page 1 of 1

Streaming http I can't seek avi files but can seek vmw files

Posted: 28 Jan 2007 23:11
by aslanski
Hi All,

I run a webserver to stream out. When I watch a movie with vmw extension, it is seekable but other movies with avi (mostly divx) or mpeg extension are not, though I can watch them without seeking. The webserver has been coded by me. I first thought there might be a problem with my code but I don't understand how vmw files can be OK.

Any idea?

Posted: 29 Jan 2007 12:32
by aslanski
Hmm. I checked the HTTP request headers for avi and wmv files and they are similar. So I guess there is an index at the beginning of wmv files so they are seekable.

GET /xxx.avi HTTP/1.1
Host: localhost:8888
User-Agent: VLC media player - version 0.8.5 Janus - (c) 1996-2006 the VideoLAN team
Range: bytes=0-
Icy-MetaData: 1
Connection: Close

GET /xxx.wmv HTTP/1.1
Host: localhost:8888
User-Agent: VLC media player - version 0.8.5 Janus - (c) 1996-2006 the VideoLAN team
Range: bytes=0-
Icy-MetaData: 1
Connection: Close

ogm

Posted: 21 Feb 2007 06:55
by efurban
ogm and mpg files are also seekable. I have no luck with avi as well. I had converted my avi files to ogm in the past but it's just too much work.
Let me know if you find a solution.

Posted: 21 Feb 2007 10:25
by Jean-Baptiste Kempf
Could one of you check if this is not registered as a trac ticket already ?

Could you ask on vlc-devel ml, since I have no idea of the answer ?

avi over http fail to seek

Posted: 20 Mar 2008 12:04
by thannoy
I have a similar issue, maybe the same.

Playing an avi file (like mrl= http://streams.videolan.org/streams-vid ... vX-AC3.avi ) on
- mozilla plugin : give me input.length equals to zero
- vlc player git-0.9 : a "AVI file is broken" message then zero length (like TV streaming..)
The same file (downloaded then played as mrl= /home/account/...video.avi ) works fine.

I have not found track ticket for this issue, except old commits (*1), so I have opened one ( https://trac.videolan.org/vlc/ticket/1532 ).


*1 : commit messages
r2080 | fenrir | 2002-07-10 00:18:23 +0200 (mer, 10 jui 2002) | 7 lines

plugins/avi/avi.c : now you can see avi over http (true interleaved
file only), and seek is allowed (but with great unsynchronisation,
and sometimes it fails). But in order to make it working, I have to
limit the number of bytes I read at a time. It's strange since in
previous version of vlc, I don't need to do that ... ( it segfaults in
input_SplitBuffer but not always on the same frame )


r2779 | fenrir | 2002-11-16 23:25:07 +0100 (sam, 16 nov 2002) | 2 lines

* avi: fix playing over http (a bug I have introduced).