[MPlayer-cvslog] r37953 - trunk/mplayer.c

reimar subversion at mplayerhq.hu
Wed Aug 30 23:16:40 EEST 2017


Author: reimar
Date: Wed Aug 30 23:16:40 2017
New Revision: 37953

Log:
Restore frametime on seek.

Fixes issue #2331.

Modified:
   trunk/mplayer.c

Modified: trunk/mplayer.c
==============================================================================
--- trunk/mplayer.c	Wed Aug 30 22:49:50 2017	(r37952)
+++ trunk/mplayer.c	Wed Aug 30 23:16:40 2017	(r37953)
@@ -3833,6 +3833,7 @@ goto_enable_cache:
                         } else {
                             frame_time = mpctx->sh_video->frametime;
                         }
+                        // mark as last frame. Note: needs to be reset on seeking
                         mpctx->sh_video->frametime = -1;
                         mpctx->sh_video->endpts = MP_NOPTS_VALUE;
                     }
@@ -4032,6 +4033,9 @@ goto_enable_cache:
                     }
                 }
 
+                // reset last frame marker
+                if (mpctx->sh_video->frametime < 0)
+                    mpctx->sh_video->frametime = 1.0f / mpctx->sh_video->fps;
                 rel_seek_secs = 0;
                 abs_seek_pos  = 0;
                 loop_seek     = 0;


More information about the MPlayer-cvslog mailing list