[Mplayer-cvslog] CVS: main/libvo vo_svga.c,1.64,1.65

Ivan Kalvachev CVS iive at mplayerhq.hu
Sun Mar 23 00:54:33 CET 2003


Update of /cvsroot/mplayer/main/libvo
In directory mail:/var/tmp.root/cvs-serv9560

Modified Files:
	vo_svga.c 
Log Message:
fix find_best fail if the black area is bigger than image, few more verbose messages, OSD not rendered if native mode

Index: vo_svga.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/vo_svga.c,v
retrieving revision 1.64
retrieving revision 1.65
diff -u -r1.64 -r1.65
--- vo_svga.c	20 Mar 2003 01:45:40 -0000	1.64
+++ vo_svga.c	22 Mar 2003 23:54:26 -0000	1.65
@@ -15,10 +15,10 @@
  -  retrace sync works only in doublebuffer mode.
  -  the retrace sync may slow down decoding a lot - mplayer is blocked while
     waiting for retrace
- -  denoice3d fails to find common colorspace, vf_scale doesn't help - I work on it.
+ -  denoise3d fails to find common colorspace, vf_scale doesn't help - It is 
+    mplayer bug.
    
 TODO:
- - OSD without flicker (w/h & w/o double buffer)
  - let choose_best_mode take aspect into account
  - set palette from mpi->palette or mpi->plane[1]
  - let OSD draw in black bars - need some OSD changes
@@ -361,7 +361,7 @@
  vga_modeinfo *vminfo;
 //int best aspect mode // best linear mode // best normal mode (no modeX)
 
-  prev_badness = req_w * req_h;
+  prev_badness = 0;//take care of special case below
   bestmode = 0; //0 is the TEXT mode
   lastmode = vga_lastmodenumber();
   for(i=1;i<lastmode;i++){
@@ -375,7 +375,7 @@
     if(squarepix) 
       if( vminfo->width*3 != vminfo->height*4 ) continue;
 
-    if( prev_badness >= badness ){//modeX etc...
+    if( bestmode==0 || prev_badness >= badness ){//modeX etc...
       prev_badness=badness;
       bestmode=i;
       if(verbose>3)
@@ -497,6 +497,13 @@
       }
     }
   }//fi force native
+  if(mode_capabilities&CAP_LINEAR){
+    printf("vo_svga: video mode is linear and memcpy could be used for image transfer\n");
+  }
+  if(mode_capabilities&CAP_ACCEL_PUTIMAGE){
+    printf("vo_svga: video mode have hardware acceleration and put_image could be used\n");
+    printf("vo_svga: If it works for you i would like to know \nvo_svga: (send log with `mplayer test.avi -v -v -v -v &> svga.log`). Thx\n");
+  }
   
 //here is the place to handle strides for accel_ modes;
   mode_stride=modeinfo->linewidth;
@@ -661,8 +668,9 @@
   
   //only modes with bytesperpixel>0 can draw OSD
   if(modeinfo->bytesperpixel==0) return;
-//  if(!(mode_capabilities&CAP_LINEAR)) return;//force_native will remove OSD
-
+  if(!(mode_capabilities&CAP_LINEAR)) return;//force_native will remove OSD
+  if(verbose>3)
+    printf("vo_svga: OSD draw in page %d",cpage);
   base=PageStore[cpage].vbase + y0*mode_stride + x0*modeinfo->bytesperpixel;
   bytelen = modeinfo->width * modeinfo->bytesperpixel;   
   switch (mode_bpp) {



More information about the MPlayer-cvslog mailing list