From 5607881696f210fcf9d72391a8c686f7db83fe12 Mon Sep 17 00:00:00 2001 From: rsf Date: Thu, 6 Nov 2003 05:53:04 +0000 Subject: Increased the threshold for how many incoming frames to look at while guessing the video frame rate (if "-fps" isn't used) - from 100, to 300. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@11398 b3059339-0415-0410-9bf9-f77b7e298cf2 --- libmpdemux/demux_rtp_codec.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'libmpdemux/demux_rtp_codec.cpp') diff --git a/libmpdemux/demux_rtp_codec.cpp b/libmpdemux/demux_rtp_codec.cpp index f59504506b..bad3c0f700 100644 --- a/libmpdemux/demux_rtp_codec.cpp +++ b/libmpdemux/demux_rtp_codec.cpp @@ -220,12 +220,13 @@ static void needVideoFrameRate(demuxer_t* demuxer, // non-zero "pts" timestamps: unsigned char* packetData; unsigned packetDataLen; float lastPTS = 0.0, curPTS; - unsigned const maxNumFramesToWaitFor = 100; + unsigned const maxNumFramesToWaitFor = 300; for (unsigned i = 0; i < maxNumFramesToWaitFor; ++i) { if (!awaitRTPPacket(demuxer, d_video, packetData, packetDataLen, curPTS)) { break; } + fprintf(stderr, "%d: cur %f, last %f\n", i, curPTS, lastPTS);//#####@@@@@ if (curPTS > lastPTS && lastPTS != 0.0) { // Use the difference between these two "pts"s to guess the frame rate. // (should really check that there were no missing frames inbetween)##### -- cgit v1.2.3