[Mplayer-cvslog] CVS: main/libvo font_load.c,1.7,1.8

GEREOFFY arpi_esp at users.sourceforge.net
Thu Mar 29 18:39:39 CEST 2001


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

Modified Files:
	font_load.c 
Log Message:
optimized alpha resampling

Index: font_load.c
===================================================================
RCS file: /cvsroot/mplayer/main/libvo/font_load.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -r1.7 -r1.8
*** font_load.c	2001/03/29 16:06:36	1.7
--- font_load.c	2001/03/29 16:39:37	1.8
***************
*** 211,218 ****
              int y=desc->pic_b[i]->bmp[j];
  
! 	    x=((x*f)>>8); // scale
! 	    if(x<0) x=0; else if(x>255) x=255;
! 	    x^=255; // invert
! 	    
  	    if(x+y>255) x=255-y; // to avoid overflows
  	    
--- 211,218 ----
              int y=desc->pic_b[i]->bmp[j];
  
! 	    x=255-((x*f)>>8); // scale
! 	    //if(x<0) x=0; else if(x>255) x=255;
! 	    //x^=255; // invert
! 
  	    if(x+y>255) x=255-y; // to avoid overflows
  	    
***************
*** 221,229 ****
              //x=((x*f*(255-y))>>16)+y;
              //x=(x*f)>>8;if(x<y) x=y;
!             
              if(x<1) x=1; else
              if(x>=252) x=0;
! 	    
              desc->pic_a[i]->bmp[j]=x;
          }
          printf("DONE!\n");
--- 221,230 ----
              //x=((x*f*(255-y))>>16)+y;
              //x=(x*f)>>8;if(x<y) x=y;
! 
              if(x<1) x=1; else
              if(x>=252) x=0;
! 
              desc->pic_a[i]->bmp[j]=x;
+ //            desc->pic_b[i]->bmp[j]=0; // hack
          }
          printf("DONE!\n");


_______________________________________________
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