[MPlayer-dev-eng] Architect: follow mode

Sam Liddicott sam at liddicott.com
Sat Jun 29 15:31:49 CEST 2002


D Richard Felker III wrote:

>On Sat, Jun 29, 2002 at 08:11:28AM +0100, Sam Liddicott wrote:
>  
>
>>D Richard Felker III wrote:
>>
>>    
>>
>>>On Fri, Jun 28, 2002 at 08:48:48PM +0100, Sam Liddicott wrote:
>>>
>>>
>>>      
>>>
>>>>I'm slowly modifying mplayer for a follow mode as part of my 
>>>>introduction to it's internals, and I think it advisable to consult here 
>>>>        
>>>>
>>>>from time to time so I don't make any major errors.
>>>      
>>>
>>>>I want a mode where if mplayer is playing a file and the file grows 
>>>>while playing mplayer doesn't stop early.
>>>>  
>>>>
>>>>        
>>>>
>>>Afaik that was implemented a few weeks ago already.
>>>
>>>      
>>>
>>Hmm, doesn't work for me; if I start mplayer with -dumpstream on an asf 
>>stream and dump to a file, and then a few(enough) seconds later start 
>>mplayer from that file it stops at eof quickly, I restart (from start) 
>>and it goes longer and then stops, etc.
>>
>>I guess it is stopping at the size of file when it started.
>>    
>>
>
>Well there are two issues at hand here.
>
>One, dumpstream is entirely different and it prolly wont work with
>that.
>
>Two, dumpstream goes fast so there's probably no chance for this
>feature to kick in. If mplayer ever *reaches* the end of the file, it
>stops playing; it doesn't just stop there and wait for more data,
>because it's already gotten eof. The idea is that if you're playing a
>movie (rather than dumping a stream) you can start it before your
>download finishes, and as long as the download stays ahead of
>playback, you're fine.
>

Yeah, I did try for this, I actually let the dumpstream get ahead by 
quite a few minutes to make sure it wasn't inconstant transmission speeds.

>However, what you want to do should be very easy too. It's not a
>matter of doing anything special in mplayer, just making good use of
>unix. Try the following:
>
>tail -c 1000000000 -f incomplete.asf | mplayer -dumpstream -
>
Or;
tail -f -n+0 dump.asf | mplayer -vo svga -

as I was using, but of course it isn't seekable then.

>The number 1000000000 isn't special; it just needs to be larger than
>the number of bytes already downloaded.
>
Hmm; I don't know what your command line was trying to acheive; if 
incomplete.asf isn't that big, you need at least -F for it to keep 
trying; but incomplete.asf is my dumpstreamed file from mplayer 
-dumpstream -dumpfile incomplete.asf http://...../...asf

But I know a whole crowd who want seekable growable streams (circular 
buffers to follow soon).

Sam




More information about the MPlayer-dev-eng mailing list