comparison libvo/vo_vesa.c @ 13568:1cb0e1833515

Currently vbeGetProtModeInfo call the 0x4f0a function of int 10h the get a simple 32 bits protected mode interface to some VESA functions. This protected mode interface is interesting because it's quicker than the raw int 10h interface. Unfortunatly, begining with VBE 3.0, the 0x4f0a function is optional, and some video cards don't implement it (3dfx, intel 845/855/865...). This protected mode interface is then only used in vbeSetWindow and vbeSetDisplayStart : ?- vbeSetWindow already implement an alternative methode if protected mode interface is not available. ?- vbeSetDisplayStart also contain an alternative implementation, but this one is disabled with a #if 0. I don't exactly know why because it works well ! So currently, cards which don't have the 0x4f0a function are not supported. This patch correct this. ?- vbeGetProtModeInfo failure is not fatal. ?- vbeSetDisplayStart has it's alternative implementation reenabled. ? ?it's used only with cards which don't have the 0x4f0a function ? ?so this won't make any difference for cards which were already ? ?working. This patch also make the failure of vbeGetModeInfo not fatal. The VBE 3.0 standard state that GetModeInfo can fail with some mode which are listed as supported if the mode can't be used in the current situation (not enough video memory for example). So a failure of vbeGetModeInfo don't mean that other modes won't work and should really not be fatal. patch by Aurelien Jacobs <aurel@gnuage.org>
author faust3
date Wed, 06 Oct 2004 08:42:13 +0000
parents c10922751a8e
children e98f3d37bc1c
comparison
equal deleted inserted replaced
13567:8f75b26e847c 13568:1cb0e1833515
737 for(i=0;i < num_modes;i++) 737 for(i=0;i < num_modes;i++)
738 { 738 {
739 if((err=vbeGetModeInfo(mode_ptr[i],&vmib)) != VBE_OK) 739 if((err=vbeGetModeInfo(mode_ptr[i],&vmib)) != VBE_OK)
740 { 740 {
741 PRINT_VBE_ERR("vbeGetModeInfo",err); 741 PRINT_VBE_ERR("vbeGetModeInfo",err);
742 return -1; 742 continue;
743 } 743 }
744 if(vmib.XResolution >= w && 744 if(vmib.XResolution >= w &&
745 vmib.YResolution >= h && 745 vmib.YResolution >= h &&
746 (vmib.ModeAttributes & MOVIE_MODE) == MOVIE_MODE && 746 (vmib.ModeAttributes & MOVIE_MODE) == MOVIE_MODE &&
747 vmib.BitsPerPixel == bpp && 747 vmib.BitsPerPixel == bpp &&