Fixed all warnings, some little bugs, and improved compatibility with >1GB RAM

git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@54 416bcca6-2ee7-4201-b75f-2eb2f807beb1
This commit is contained in:
Adrien Destugues
2008-07-21 12:47:32 +00:00
parent 750e68ed35
commit 272506e850
17 changed files with 1535 additions and 1584 deletions

View File

@@ -3,6 +3,7 @@
#include "sdlscreen.h"
#include "global.h"
#include "graph.h" //Afficher_curseur
#include "erreurs.h"
// Gestion du mode texte de départ (pour pouvoir y retourner en cas de problème
byte Recuperer_nb_lignes(void)
@@ -48,16 +49,14 @@ word Palette_Compter_nb_couleurs_utilisees(dword* Tableau)
void Set_palette(T_Palette Palette)
{
SDL_Color PaletteSDL[255];
byte i=0;
do
register int i;
SDL_Color PaletteSDL[256];
for(i=0;i<256;i++)
{
PaletteSDL[i].r=Palette[i].R*4; //Les couleurs VGA ne vont que de 0 à 63
PaletteSDL[i].g=Palette[i].V*4;
PaletteSDL[i].b=Palette[i].B*4;
i++;
}
while(i!=0);
SDL_SetPalette(Ecran_SDL,SDL_PHYSPAL|SDL_LOGPAL,PaletteSDL,0,256);
}