[Mplayer-cvslog] CVS: main mplayer.c,1.109,1.110

Zoltan Ponekker pontscho at users.sourceforge.net
Thu May 10 11:14:02 CEST 2001


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

Modified Files:
	mplayer.c 
Log Message:
stime compile bug fixed. and GUI_MSG macro defined.

Index: mplayer.c
===================================================================
RCS file: /cvsroot/mplayer/main/mplayer.c,v
retrieving revision 1.109
retrieving revision 1.110
diff -C2 -r1.109 -r1.110
*** mplayer.c	2001/05/10 03:39:54	1.109
--- mplayer.c	2001/05/10 09:13:36	1.110
***************
*** 15,18 ****
--- 15,19 ----
  #include <sys/ioctl.h>
  #include <unistd.h>
+ #include <time.h>
  #include <sys/mman.h>
  
***************
*** 90,94 ****
  #define DEBUG if(0)
  #ifdef HAVE_GUI
!  int nogui=1; // new
  #endif
  int verbose=0;
--- 91,95 ----
  #define DEBUG if(0)
  #ifdef HAVE_GUI
!  int nogui=1;
  #endif
  int verbose=0;
***************
*** 355,358 ****
--- 356,362 ----
  #ifdef HAVE_GUI
   #include "../Gui/mplayer/psignal.h"
+  #define GUI_MSG(x) if ( !nogui ) { mplSendMessage( x ); usleep( 10000 ); }
+ #else
+  #define GUI_MSG(x)
  #endif
  
***************
*** 584,590 ****
  if(!parse_codec_cfg(get_path("codecs.conf"))){
      printf("(copy/link DOCS/codecs.conf to ~/.mplayer/codecs.conf)\n");
!     #ifdef HAVE_GUI
!      if ( !nogui ) { mplSendMessage( mplCodecConfNotFound ); usleep( 10000 ); }
!     #endif
      exit(1);
  }
--- 588,592 ----
  if(!parse_codec_cfg(get_path("codecs.conf"))){
      printf("(copy/link DOCS/codecs.conf to ~/.mplayer/codecs.conf)\n");
!     GUI_MSG( mplCodecConfNotFound )
      exit(1);
  }
***************
*** 652,658 ****
      if (dvd_import_key(dvdimportkey)) {
  	fprintf(stderr,"Error processing DVD KEY.\n");
!         #ifdef HAVE_GUI
!          if ( !nogui ) { mplSendMessage( mplErrorDVDKeyProcess ); usleep( 10000 ); }
!         #endif
  	exit(1);
      }
--- 654,658 ----
      if (dvd_import_key(dvdimportkey)) {
  	fprintf(stderr,"Error processing DVD KEY.\n");
!         GUI_MSG( mplErrorDVDKeyProcess )
  	exit(1);
      }
***************
*** 661,667 ****
    if (dvd_device) {
      if (dvd_auth(dvd_device,f)) {
!         #ifdef HAVE_GUI
!          if ( !nogui ) { mplSendMessage( mplErrorDVDAuth ); usleep( 10000 ); }
!         #endif
          exit(0);
        } 
--- 661,665 ----
    if (dvd_device) {
      if (dvd_auth(dvd_device,f)) {
!         GUI_MSG( mplErrorDVDAuth )
          exit(0);
        } 
***************
*** 740,746 ****
    printf("============= Sorry, this file format not recognized/supported ===============\n");
    printf("=== If this file is an AVI, ASF or MPEG stream, please contact the author! ===\n");
!   #ifdef HAVE_GUI
!    if ( !nogui ) { mplSendMessage( mplUnknowFileType ); usleep( 10000 ); }
!   #endif
    exit(1);
  }
--- 738,742 ----
    printf("============= Sorry, this file format not recognized/supported ===============\n");
    printf("=== If this file is an AVI, ASF or MPEG stream, please contact the author! ===\n");
!   GUI_MSG( mplUnknowFileType )
    exit(1);
  }
***************
*** 793,799 ****
        if(v_pos==-1){
          printf("AVI_NI: missing video stream!? contact the author, it may be a bug :(\n");
!         #ifdef HAVE_GUI
!          if ( !nogui ) { mplSendMessage( mplErrorAVINI ); usleep( 10000 ); }
!         #endif
          exit(1);
        }
--- 789,793 ----
        if(v_pos==-1){
          printf("AVI_NI: missing video stream!? contact the author, it may be a bug :(\n");
!         GUI_MSG( mplErrorAVINI )
          exit(1);
        }
***************
*** 820,826 ****
    if(!ds_fill_buffer(d_video)){
      printf("AVI: missing video stream!? contact the author, it may be a bug :(\n");
!     #ifdef HAVE_GUI
!      if ( !nogui ) { mplSendMessage( mplAVIErrorMissingVideoStream ); usleep( 10000 ); }
!     #endif
      exit(1);
    }
--- 814,818 ----
    if(!ds_fill_buffer(d_video)){
      printf("AVI: missing video stream!? contact the author, it may be a bug :(\n");
!     GUI_MSG( mplAVIErrorMissingVideoStream )
      exit(1);
    }
***************
*** 864,870 ****
    if(!ds_fill_buffer(d_video)){
      printf("ASF: missing video stream!? contact the author, it may be a bug :(\n");
!     #ifdef HAVE_GUI
!      if ( !nogui ) { mplSendMessage( mplASFErrorMissingVideoStream ); usleep( 10000 ); }
!     #endif
      exit(1);
    }
--- 856,860 ----
    if(!ds_fill_buffer(d_video)){
      printf("ASF: missing video stream!? contact the author, it may be a bug :(\n");
!     GUI_MSG( mplASFErrorMissingVideoStream )
      exit(1);
    }
***************
*** 935,941 ****
          if(verbose)  printf("NONE :(\n");
          printf("MPEG: FATAL: EOF while searching for sequence header\n");
!         #ifdef HAVE_GUI
!          if ( !nogui ) { mplSendMessage( mplMPEGErrorSeqHeaderSearch ); usleep( 10000 ); }
!         #endif
          exit(1);
        }
--- 925,929 ----
          if(verbose)  printf("NONE :(\n");
          printf("MPEG: FATAL: EOF while searching for sequence header\n");
!         GUI_MSG( mplMPEGErrorSeqHeaderSearch )
          exit(1);
        }
***************
*** 949,955 ****
     if(!videobuffer){ 
       printf("Cannot allocate shared memory\n");
!      #ifdef HAVE_GUI
!       if ( !nogui ) { mplSendMessage( mplErrorShMemAlloc ); usleep( 10000 ); }
!      #endif
       exit(0);
     }
--- 937,941 ----
     if(!videobuffer){ 
       printf("Cannot allocate shared memory\n");
!      GUI_MSG( mplErrorShMemAlloc )
       exit(0);
     }
***************
*** 957,970 ****
     if(!read_video_packet(d_video)){ 
       printf("FATAL: Cannot read sequence header!\n");
!      #ifdef HAVE_GUI
!       if ( !nogui ) { mplSendMessage( mplMPEGErrorCannotReadSeqHeader ); usleep( 10000 ); }
!      #endif
       exit(1);
     }
     if(header_process_sequence_header (picture, &videobuffer[4])) {
       printf ("bad sequence header!\n"); 
!      #ifdef HAVE_GUI
!       if ( !nogui ) { mplSendMessage( mplMPEGErrorBadSeqHeader ); usleep( 10000 ); }
!      #endif
       exit(1);
     }
--- 943,952 ----
     if(!read_video_packet(d_video)){ 
       printf("FATAL: Cannot read sequence header!\n");
!      GUI_MSG( mplMPEGErrorCannotReadSeqHeader )
       exit(1);
     }
     if(header_process_sequence_header (picture, &videobuffer[4])) {
       printf ("bad sequence header!\n"); 
!      GUI_MSG( mplMPEGErrorBadSeqHeader )
       exit(1);
     }
***************
*** 973,986 ****
      if(!read_video_packet(d_video)){ 
        printf("FATAL: Cannot read sequence header extension!\n");
!       #ifdef HAVE_GUI
!        if ( !nogui ) { mplSendMessage( mplMPEGErrorCannotReadSeqHeaderExt ); usleep( 10000 ); }
!       #endif
        exit(1);
      }
      if(header_process_extension (picture, &videobuffer[4])) {
        printf ("bad sequence header extension!\n");  
!       #ifdef HAVE_GUI
!        if ( !nogui ) { mplSendMessage( mplMPEGErrorBadSeqHeaderExt ); usleep( 10000 ); }
!       #endif
        exit(1);
      }
--- 955,964 ----
      if(!read_video_packet(d_video)){ 
        printf("FATAL: Cannot read sequence header extension!\n");
!       GUI_MSG( mplMPEGErrorCannotReadSeqHeaderExt )
        exit(1);
      }
      if(header_process_extension (picture, &videobuffer[4])) {
        printf ("bad sequence header extension!\n");  
!       GUI_MSG( mplMPEGErrorBadSeqHeaderExt )
        exit(1);
      }
***************
*** 1096,1102 ****
  if(i>=CODECS_MAX_OUTFMT){
      printf("Sorry, selected video_out device is incompatible with this codec.\n");
!     #ifdef HAVE_GUI
!      if ( !nogui ) { mplSendMessage( mplIncompatibleVideoOutDevice ); usleep( 10000 ); }
!     #endif
      exit(1);
  }
--- 1074,1078 ----
  if(i>=CODECS_MAX_OUTFMT){
      printf("Sorry, selected video_out device is incompatible with this codec.\n");
!     GUI_MSG( mplIncompatibleVideoOutDevice )
      exit(1);
  }
***************
*** 1108,1114 ****
   case 2: {
     if(!init_video_codec(sh_video)) {
!      #ifdef HAVE_GUI
!       if ( !nogui ) { mplSendMessage( mplUnknowError ); usleep( 10000 ); }
!      #endif
       exit(1);
     }  
--- 1084,1088 ----
   case 2: {
     if(!init_video_codec(sh_video)) {
!      GUI_MSG( mplUnknowError )
       exit(1);
     }  
***************
*** 1119,1125 ****
  #ifndef USE_DIRECTSHOW
     printf("MPlayer was compiled WITHOUT directshow support!\n");
!    #ifdef HAVE_GUI
!     if ( !nogui ) { mplSendMessage( mplCompileWithoutDSSupport ); usleep( 10000 ); }
!    #endif
     exit(1);
  #else
--- 1093,1097 ----
  #ifndef USE_DIRECTSHOW
     printf("MPlayer was compiled WITHOUT directshow support!\n");
!    GUI_MSG( mplCompileWithoutDSSupport )
     exit(1);
  #else
***************
*** 1295,1301 ****
                        title,out_fmt)){
       printf("FATAL: Cannot initialize video driver!\n");
!      #ifdef HAVE_GUI
!       if ( !nogui ) { mplSendMessage( mplCantInitVideoDriver ); usleep( 10000 ); }
!      #endif
       exit(1);
     }
--- 1267,1271 ----
                        title,out_fmt)){
       printf("FATAL: Cannot initialize video driver!\n");
!      GUI_MSG( mplCantInitVideoDriver )
       exit(1);
     }


_______________________________________________
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