Added palette constraint modes: Run the program with command-line option "/rgb <N>" to force RGB components have N levels instead of 256. Ex: /rgb 16 enforces a classic Amiga 4096 color palette, 64 is PC VGA, /rgb 3 is Amstrad CPC...)
Added missing messages for /wide and /tall command-line arguments. git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@477 416bcca6-2ee7-4201-b75f-2eb2f807beb1
This commit is contained in:
7
divers.c
7
divers.c
@@ -35,6 +35,7 @@
|
||||
#include "clavier.h"
|
||||
#include "sdlscreen.h"
|
||||
#include "windows.h"
|
||||
#include "palette.h"
|
||||
|
||||
word Palette_Compter_nb_couleurs_utilisees(dword* Tableau)
|
||||
{
|
||||
@@ -76,9 +77,9 @@ void Set_palette(T_Palette Palette)
|
||||
SDL_Color PaletteSDL[256];
|
||||
for(i=0;i<256;i++)
|
||||
{
|
||||
PaletteSDL[i].r=Palette[i].R;
|
||||
PaletteSDL[i].g=Palette[i].V;
|
||||
PaletteSDL[i].b=Palette[i].B;
|
||||
PaletteSDL[i].r=(Palette[i].R=Palette_Scale_Component(Palette[i].R));
|
||||
PaletteSDL[i].g=(Palette[i].V=Palette_Scale_Component(Palette[i].V));
|
||||
PaletteSDL[i].b=(Palette[i].B=Palette_Scale_Component(Palette[i].B));
|
||||
}
|
||||
SDL_SetPalette(Ecran_SDL, SDL_PHYSPAL | SDL_LOGPAL, PaletteSDL,0,256);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user