Mercurial > mplayer.hg
diff libvo/sub.c @ 1727:9da2b587b029
changes according to OSD calculations
author | atlka |
---|---|
date | Tue, 28 Aug 2001 14:22:37 +0000 |
parents | 38871427a131 |
children | 85dda3b18445 |
line wrap: on
line diff
--- a/libvo/sub.c Tue Aug 28 12:43:41 2001 +0000 +++ b/libvo/sub.c Tue Aug 28 14:22:37 2001 +0000 @@ -34,8 +34,8 @@ // if we have n=256 bars then OSD progbar looks like below // -// 0 1 2 3 ... 256 <= vo_osd_progbar_value -// | | | | | +// 0 1 2 3 ... 256 <= vo_osd_progbar_value +// | | | | | // [ === === === ... === ] // // the above schema is rescalled to n=elems bars @@ -56,12 +56,9 @@ if (vo_osd_progbar_value<=0) mark=0; - else { - int mm=vo_osd_progbar_value*elems; - mark=mm>>8; - if (mm & 0x00FF) mark++; - if (mark>elems) mark=elems; - } + else if ((mark=(vo_osd_progbar_value*elems)>>8)>elems) + mark=elems; + // printf("osd.progbar width=%d xpos=%d\n",width,x); c=vo_osd_progbar_type;