[Mplayer-cvslog] CVS: main/mp3lib test.c,1.1,1.2

GEREOFFY arpi_esp at users.sourceforge.net
Thu May 17 00:23:16 CEST 2001


Update of /cvsroot/mplayer/main/mp3lib
In directory usw-pr-cvs1:/tmp/cvs-serv25800

Modified Files:
	test.c 
Log Message:
dump to file

Index: test.c
===================================================================
RCS file: /cvsroot/mplayer/main/mp3lib/test.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** test.c	2001/05/13 18:58:23	1.1
--- test.c	2001/05/16 22:23:13	1.2
***************
*** 1,3 ****
--- 1,5 ----
  
+ #define DUMP_PCM
+ 
  // gcc test.c -I.. -L. -lMP3 -o test -O4
  
***************
*** 34,37 ****
--- 36,43 ----
    unsigned int time1;
    float length;
+ #ifdef DUMP_PCM
+   FILE *f=NULL;
+   f=fopen("test.pcm","wb");
+ #endif
    
    mp3file=fopen((argc>1)?argv[1]:"test.mp3","rb");
***************
*** 47,53 ****
    
    time1=GetTimer();
!   while((len=MP3_DecodeFrame(buffer,-1))>0){
        total+=len;
        // play it
        //putchar('.');fflush(stdout);
    }
--- 53,62 ----
    
    time1=GetTimer();
!   while((len=MP3_DecodeFrame(buffer,-1))>0 && total<2000000){
        total+=len;
        // play it
+ #ifdef DUMP_PCM
+       fwrite(buffer,len,1,f);
+ #endif
        //putchar('.');fflush(stdout);
    }


_______________________________________________
Mplayer-cvslog mailing list
Mplayer-cvslog at lists.sourceforge.net
http://lists.sourceforge.net/lists/listinfo/mplayer-cvslog



More information about the MPlayer-cvslog mailing list