[Mplayer-cvslog] CVS: main mplayer.c,1.45,1.46

GEREOFFY arpi_esp at users.sourceforge.net
Thu Apr 12 02:40:44 CEST 2001


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

Modified Files:
	mplayer.c 
Log Message:
OSD fixes, patch by Kebert Martin

Index: mplayer.c
===================================================================
RCS file: /cvsroot/mplayer/main/mplayer.c,v
retrieving revision 1.45
retrieving revision 1.46
diff -C2 -r1.45 -r1.46
*** mplayer.c	2001/04/11 21:36:56	1.45
--- mplayer.c	2001/04/12 00:40:42	1.46
***************
*** 1114,1117 ****
--- 1114,1118 ----
  int grab_frames=0;
  char osd_text_buffer[64];
+ int osd_level=2;
  int osd_visible=100;
  int osd_function=OSD_PLAY;
***************
*** 1706,1709 ****
--- 1707,1723 ----
      if(!osd_visible) vo_osd_progbar_type=-1; // disable
    }
+ 
+   if(osd_function==OSD_PAUSE){
+       printf("\n------ PAUSED -------\r");fflush(stdout);
+       while(
+ #ifdef HAVE_LIRC
+           lirc_mp_getinput()<=0 &&
+ #endif
+           getch2(20)<=0 && mplayer_get_key()<=0){
+ 	  video_out->check_events();
+       }
+       osd_function=OSD_PLAY;
+   }
+ 
    } //  while(v_frame<a_frame || force_redraw)
  
***************
*** 1755,1758 ****
--- 1769,1773 ----
      case ' ':
        osd_function=OSD_PAUSE;
+ #if 0
        printf("\n------ PAUSED -------\r");fflush(stdout);
        while(
***************
*** 1764,1768 ****
--- 1779,1787 ----
        }
        osd_function=OSD_PLAY;
+ #endif
        break;
+     case 'o':  // toggle OSD
+       osd_level=(osd_level+1)%3;
+       break;
    }
    if(rel_seek_secs)
***************
*** 1930,1938 ****
  
          // Set OSD:
!       osd_visible=default_fps;
!       vo_osd_progbar_type=0;
!       vo_osd_progbar_value=(demuxer->filepos)/((avi_header.movi_end-avi_header.movi_start)>>8);
!       printf("avi filepos = %d  \n",vo_osd_progbar_value);
! //      printf("avi filepos = %d  (len=%d)  \n",demuxer->filepos,(avi_header.movi_end-avi_header.movi_start));
  
    }
--- 1949,1959 ----
  
          // Set OSD:
!       if(osd_level){
!         osd_visible=default_fps;
!         vo_osd_progbar_type=0;
!         vo_osd_progbar_value=(demuxer->filepos)/((avi_header.movi_end-avi_header.movi_start)>>8);
!         //printf("avi filepos = %d  \n",vo_osd_progbar_value);
!   //      printf("avi filepos = %d  (len=%d)  \n",demuxer->filepos,(avi_header.movi_end-avi_header.movi_start));
!       }
  
    }
***************
*** 2046,2052 ****
  //================= Update OSD ====================
  { int i;
!   sprintf(osd_text_buffer,"%c %02d:%02d:%02d",osd_function,(int)v_pts/3600,((int)v_pts/60)%60,((int)v_pts)%60);
  //  for(i=1;i<=11;i++) osd_text_buffer[10+i]=i;osd_text_buffer[10+i]=0;
!   vo_osd_text=osd_text_buffer;
    
    // find sub
--- 2067,2078 ----
  //================= Update OSD ====================
  { int i;
!   if(osd_level>=2){
!       vo_osd_text=osd_text_buffer;
!       sprintf(vo_osd_text,"%c %02d:%02d:%02d",osd_function,(int)v_pts/3600,((int)v_pts/60)%60,((int)v_pts)%60);
!   } else {
!       vo_osd_text=NULL;
!   }
  //  for(i=1;i<=11;i++) osd_text_buffer[10+i]=i;osd_text_buffer[10+i]=0;
! //  vo_osd_text=osd_text_buffer;
    
    // find sub


_______________________________________________
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