head 1.1; branch 1.1.1; access ; symbols start:1.1.1.1 PAlibDoc:1.1.1; locks ; strict; comment @# @; 1.1 date 2005.11.02.08.30.25; author jandujar; state Exp; branches 1.1.1.1; next ; 1.1.1.1 date 2005.11.02.08.30.25; author jandujar; state Exp; branches ; next ; desc @@ 1.1 log @Initial revision @ text @
Defines | |
#define | PA_LoadPal(palette, source) DMA_Copy((void*)source, (void*)palette, 256, DMA_16NOW); |
Load a 256 color palette in the Bg or Sprite palette of screen 0 or 1. Ex : PA_LoadPal(PALETTE_BG1, bg_pal); | |
#define | PA_LoadPal16(palette, n_palette, source) DMA_Copy((void*)source, (void*)(palette + (n_palette << 5)), 16, DMA_16NOW); |
Load a 16 color palette in the Bg or Sprite palette of screen 0 or 1. Ex : PA_LoadPal16(PALETTE_BG1, 4, bg_pal); | |
#define | PA_RGB(r, g, b) ((1 << 15) + (r) + ((g)<<5) + ((b)<<10)) |
Convert Red, Green, and Blue color indexes into a number used in the palette system. Careful : the R, G, B values range from 0 to 31 on gba ! | |
#define | PA_SetBgPalCol(screen, color_number, colorRGB) BG_PALETTE[color_number + (screen << 9)] = colorRGB |
Change de color of one of the background palette colors | |
#define | PA_SetSpritePalCol(screen, color_number, colorRGB) BG_PALETTE[256 + color_number + (screen << 9)] = colorRGB |
Change de color of one of the sprite palette colors | |
Functions | |
void | PA_SetBrightness (bool screen, s8 bright) |
Set the screen's brightness | |
void | PA_SetPalNeg (u32 palette) |
Set all the palette's color to negative. To undo this, simply negative again... | |
void | PA_SetPal16Neg (u32 palette, u8 n_palette) |
Set 16 color palette to negative. To undo this, simply negative again... | |
void | PA_InitSpriteExtPal (void) |
Initialise 16 palette mode for 256 color sprites | |
void | PA_InitBgExtPal (void) |
Initialise 16 palette mode for 256 color backgrounds | |
void | PA_LoadSpriteExtPal (bool screen, u16 palette_number, void *palette) |
Load a 256 color palette in the Sprite extended palettes | |
void | PA_LoadBgExtPal (bool screen, u16 palette_number, void *palette) |
Load a 256 color palette in the Background extended palettes |
|
Load a 256 color palette in the Bg or Sprite palette of screen 0 or 1. Ex : PA_LoadPal(PALETTE_BG1, bg_pal);
|
|
Load a 16 color palette in the Bg or Sprite palette of screen 0 or 1. Ex : PA_LoadPal16(PALETTE_BG1, 4, bg_pal);
|
|
Convert Red, Green, and Blue color indexes into a number used in the palette system. Careful : the R, G, B values range from 0 to 31 on gba !
|
|
Change de color of one of the background palette colors
|
|
Change de color of one of the sprite palette colors
|
|
Load a 256 color palette in the Background extended palettes
|
|
Load a 256 color palette in the Sprite extended palettes
|
|
Set the screen's brightness
|
|
Set 16 color palette to negative. To undo this, simply negative again...
|
|
Set all the palette's color to negative. To undo this, simply negative again...
|