[Mplayer-cvslog] CVS: main/libvo vo_mpegpes.c,1.7,1.8

Arpi of Ize arpi at mplayer.dev.hu
Thu Oct 4 01:34:36 CEST 2001


Update of /cvsroot/mplayer/main/libvo
In directory mplayer:/var/tmp.root/cvs-serv5206

Modified Files:
	vo_mpegpes.c 
Log Message:
using poll() only for DVB card - not required for file write

Index: vo_mpegpes.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_mpegpes.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- vo_mpegpes.c	27 Sep 2001 14:21:56 -0000	1.7
+++ vo_mpegpes.c	3 Oct 2001 23:34:15 -0000	1.8
@@ -21,10 +21,11 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <fcntl.h>
-#include <sys/poll.h>
 
 #ifdef HAVE_DVB
 
+#include <sys/poll.h>
+
 #include <sys/ioctl.h>
 #include <stdio.h>
 #include <time.h>
@@ -251,9 +252,10 @@
 #endif
 }
 
-#define NFD   2
 
 static void my_write(unsigned char* data,int len){
+#ifdef HAVE_DVB
+#define NFD   2
     struct pollfd pfd[NFD];
 
 //    printf("write %d bytes  \n",len);
@@ -278,6 +280,10 @@
 	    } else usleep(1000);
 	}
     }
+
+#else
+    write(vo_mpegpes_fd,data,len); // write to file
+#endif
 }
 
 static unsigned char pes_header[PES_MAX_SIZE];




More information about the MPlayer-cvslog mailing list