[Mplayer-cvslog] CVS: main/libmpeg2 header.c,1.4,1.5 mpeg2_internal.h,1.8,1.9

Arpi of Ize arpi at mplayer.dev.hu
Sun Oct 14 19:29:51 CEST 2001


Update of /cvsroot/mplayer/main/libmpeg2
In directory mplayer:/var/tmp.root/cvs-serv10437

Modified Files:
	header.c mpeg2_internal.h 
Log Message:
mpeg2 fps fix by Ivan Kalvatchev <iive at yahoo.com>

Index: header.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpeg2/header.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- header.c	22 Aug 2001 16:24:00 -0000	1.4
+++ header.c	14 Oct 2001 17:29:49 -0000	1.5
@@ -203,6 +203,7 @@
     picture->repeat_first_field = (buffer[3] >> 1) & 1;
     picture->progressive_frame = buffer[4] >> 7;
 
+#if 0
     // repeat_first implementation by A'rpi/ESP-team, based on libmpeg3:
     if(picture->repeat_count>=100) picture->repeat_count=0;
     if(picture->repeat_first_field){
@@ -216,7 +217,30 @@
                 picture->repeat_count+=50;
         }
     }
+    //repeat_count=display_time-100%
+#else
+   // repeat_first implemantation by iive, based on A'rpi/ESP-team and libmpeg3
+    if( picture->progressive_sequence == 1 )
+    {
+        if( picture->repeat_first_field == 0 ) picture->display_time=100;//normal
+	else
+	{
+	    if( picture->top_field_first == 0 ) picture->display_time=200;//2 frames
+	    else picture->display_time=300;//3 frames
+	}
+    }else
+    {
+         if( picture->progressive_frame == 0 )
+	     picture->display_time=100;//2fields, interlaced in time
+	 else
+	 {
+	     if( picture->top_field_first == 0 ) picture->display_time=100;//reconstruct 2 fields
+	     else picture->display_time = 150;//reconstruct 3 fields
+	 }
 
+	 if( picture->picture_structure!=3 ) picture->display_time/=2;//we calc on every field
+    }
+#endif
     return 0;
 }
 

Index: mpeg2_internal.h
===================================================================
RCS file: /cvsroot/mplayer/main/libmpeg2/mpeg2_internal.h,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- mpeg2_internal.h	2 Oct 2001 21:45:41 -0000	1.8
+++ mpeg2_internal.h	14 Oct 2001 17:29:49 -0000	1.9
@@ -146,7 +146,7 @@
     int display_picture_width;
     int display_picture_height;
     int pp_options;
-    int repeat_count;
+    int display_time;
 
     struct vo_frame_s * display_frame;
     int slice;




More information about the MPlayer-cvslog mailing list