comparison libvo/vo_svga.c @ 10940:b99be2c88faf

OSD stride fix and correct email
author iive
date Thu, 25 Sep 2003 01:48:47 +0000
parents f531971e44cf
children 6e35326c742f
comparison
equal deleted inserted replaced
10939:55c9903bd51c 10940:b99be2c88faf
97 }PageStore[MAXPAGES]; 97 }PageStore[MAXPAGES];
98 98
99 static vo_info_t info = { 99 static vo_info_t info = {
100 "SVGAlib", 100 "SVGAlib",
101 "svga", 101 "svga",
102 "Ivan Kalvachev <iive@sf.net>", 102 "Ivan Kalvachev <iive@users.sf.net>",
103 "" 103 ""
104 }; 104 };
105 105
106 #ifdef CONFIG_VIDIX 106 #ifdef CONFIG_VIDIX
107 static char vidix_name[32] = ""; 107 static char vidix_name[32] = "";
643 } 643 }
644 644
645 static void draw_alpha(int x0, int y0, int w, int h, unsigned char *src, 645 static void draw_alpha(int x0, int y0, int w, int h, unsigned char *src,
646 unsigned char *srca, int stride) { 646 unsigned char *srca, int stride) {
647 char* base; 647 char* base;
648 int bytelen;
649 648
650 if(verbose>2) 649 if(verbose>2)
651 printf("vo_svga: draw_alpha(x0=%d,y0=%d,w=%d,h=%d,src=%p,srca=%p,stride=%d\n", 650 printf("vo_svga: draw_alpha(x0=%d,y0=%d,w=%d,h=%d,src=%p,srca=%p,stride=%d\n",
652 x0,y0,w,h,src,srca,stride); 651 x0,y0,w,h,src,srca,stride);
653 if(!blackbar_osd) { 652 if(!blackbar_osd) {
657 } 656 }
658 657
659 if(verbose>3) 658 if(verbose>3)
660 printf("vo_svga: OSD draw in page %d\n",cpage); 659 printf("vo_svga: OSD draw in page %d\n",cpage);
661 base=PageStore[cpage].vbase + y0*mode_stride + x0*modeinfo->bytesperpixel; 660 base=PageStore[cpage].vbase + y0*mode_stride + x0*modeinfo->bytesperpixel;
662 bytelen = modeinfo->width * modeinfo->bytesperpixel;
663 switch (mode_bpp) { 661 switch (mode_bpp) {
664 case 32: 662 case 32:
665 vo_draw_alpha_rgb32(w, h, src, srca, stride, base, bytelen); 663 vo_draw_alpha_rgb32(w, h, src, srca, stride, base, mode_stride);
666 break; 664 break;
667 case 24: 665 case 24:
668 vo_draw_alpha_rgb24(w, h, src, srca, stride, base, bytelen); 666 vo_draw_alpha_rgb24(w, h, src, srca, stride, base, mode_stride);
669 break; 667 break;
670 case 16: 668 case 16:
671 vo_draw_alpha_rgb16(w, h, src, srca, stride, base, bytelen); 669 vo_draw_alpha_rgb16(w, h, src, srca, stride, base, mode_stride);
672 break; 670 break;
673 case 15: 671 case 15:
674 vo_draw_alpha_rgb15(w, h, src, srca, stride, base, bytelen); 672 vo_draw_alpha_rgb15(w, h, src, srca, stride, base, mode_stride);
675 break; 673 break;
676 } 674 }
677 } 675 }
678 676
679 static uint32_t get_image(mp_image_t *mpi){ 677 static uint32_t get_image(mp_image_t *mpi){