[MPlayer-users] OSD problems with DVDs

Davide Capodaglio davidecapod at inwind.it
Thu Jan 19 10:29:05 CET 2006


Sorry, I was having wrong system date...

Davide Capodaglio ha scritto:
> Dominik 'Rathann' Mierzejewski ha scritto:
>> On Wednesday, 18 January 2006 at 23:17, Davide Capodaglio wrote:
>>> Hi everybody, these are the problems I have with DVDs and OSD:
>>>
>>> - sometimes the total time is lower than real time, for all the film 
>>> length
>>> - sometimes the total time is lower than real time, but at a certain 
>>> point of the film it becomes the correct time
>>> - sometimes the current time at a certain point goes back to 0: e.g. 
>>> 00:00-31:00, then resets to 00:00, then 00:00-28:32, reset to 00:00, 
>>> etc. (VOB boundary??).
>>> (For this I produced a patch, and now the current time follow the 
>>> total time, but if this is wrong I'm stuck again)
>>> - the strangest case: the total time is 00:00, but the current time 
>>> goes on
>>>
>>> All these DVDs with problems work perfectly under xine and even with 
>>> a simple lsdvd.
>>> Can anyone report these problems as well?
>>
>> This is all normal, as MPlayer shows the REAL pts, as decoded from the
>> video stream. MPEG pts don't have to be monotonic AFAIK.
> 
> Well it may be normal for mplayer, but in fact it's an annoying bug, not 
> present for example in xine.
> 
>>> Little OT: If someone is interested I wrote a patch to show CPU 
>>> usage, frames dropped etc (the last part of the status line) as OSD 
>>> level 4.
>>
>> Please post the patch.
>>
> 
> Attached osd4.patch (it's against mplayer 1.0-pre7try2).
> Any feedback is appreciated.
> 
>> Regards,
>> R.
>>
> 
> Bye
> Davide
> 
> 
> ------------------------------------------------------------------------
> 
> --- mplayer.c.orig	2005-04-15 14:14:24.000000000 +0200
> +++ mplayer.c	2005-12-13 09:21:17.171875000 +0100
> @@ -222,7 +222,8 @@
>  int enqueue=0;
>  #endif
>  
> -#define MAX_OSD_LEVEL 3
> +//DAVIDE
> +#define MAX_OSD_LEVEL 4
>  
>  int osd_level=1;
>  int osd_level_saved=-1;
> @@ -387,6 +388,9 @@
>  #define INITED_VCODEC  2048
>  #define INITED_ALL 0xFFFF
>  
> +//DAVIDE
> +char debug_osd_buf[100];
> +
>  static void uninit_player(unsigned int mask){
>    mask=inited_flags&mask;
>  
> @@ -888,6 +892,8 @@
>        (int)sh_video->num_frames,
>        (int)sh_video->num_frames_decoded);
>  
> +  char *debugpos = line + strlen(line); //DAVIDE
> +
>    // CPU usage
>    if (sh_video) {
>      if (sh_video->timer > 0.5)
> @@ -923,6 +929,11 @@
>    memset(&line[pos], ' ', width - pos);
>    line[width] = 0;
>    mp_msg(MSGT_AVSYNC, MSGL_STATUS, "%s\r", line);
> +
> +  //DAVIDE
> +  if (osd_level == 4)
> +       strncpy(debug_osd_buf, debugpos, sizeof(debug_osd_buf));
> +
>    free(line);
>  }
>  
> @@ -3882,6 +3893,7 @@
>  #endif
>  
>  
> +
>  //================= Update OSD ====================
>  #ifdef USE_OSD
>    if(osd_level>=1 && sh_video){
> @@ -3997,6 +4009,8 @@
>  	     (frame_dropping == 1 ? "on" :
>  	     (frame_dropping == 2 ? "hard"  : "off")));
>  	  osd_show_framedropping--;
> +      } else if (osd_level == 4) {   //DAVIDE
> +         strcpy(osd_text_tmp, debug_osd_buf);
>        } else if(osd_level>=2) {
>            int len = demuxer_get_time_length(demuxer);
>            int percentage = -1;
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> MPlayer-users mailing list
> MPlayer-users at mplayerhq.hu
> http://mplayerhq.hu/mailman/listinfo/mplayer-users




More information about the MPlayer-users mailing list