[MPlayer-dev-eng] None
Frodo hobbit
csharprules at hotmail.com
Thu Feb 6 15:12:19 CET 2003
>ignore it if it's 0
ok, sounds fair enough! will do thx.
(btw d_video->pts2 doesnt exists in the current CVS
in mplayer.c d_video is defined :
static demux_stream_t *d_video=NULL;
and demux_stream_t is defined in libmpdemux\demuxer.h which doesnt
contain a pts2. )
>no wonder. no way to get correct values for VBR files...
Yep I can imagine this is troublesome, however I wonder how
other players like windows media player do this.
They always give the exact duration for any given file.
Maybe it scans the whole file and calculates the total duration?
Then again maybe I can tweak it myself, since seeking with demux_seek() in
VBR files works perfectly.
So I could imagine something like:
...
stream=open_stream(...)
demuxer=demux_open(...)
...
// calculate total play time
float fTotalPlayTime=demuxer_get_time_length(demuxer);
if (demuxer->seekable)
{
fTotalPlayTime=0.0;
while (demux_seek(demuxer,0,fTotalPlayTime))
{
fTotalPlayTime = fTotalPlayTime + 1.0;
}
}
btw thx a lot for your quick answers
Frodo
_________________________________________________________________
Hotmail en Messenger on the move
http://www.msn.nl/communicatie/smsdiensten/hotmailsmsv2/
More information about the MPlayer-dev-eng
mailing list