comparison src/video/nds/SDL_ndsvideo.c @ 2682:f7594fc66bda gsoc2008_nds

Some debug work on the video driver, shows an error in the BG's vertical placement
author Darren Alton <dalton@stevens.edu>
date Sat, 26 Jul 2008 05:52:59 +0000
parents c15b6c758be5
children 71c56e900f8b
comparison
equal deleted inserted replaced
2681:c15b6c758be5 2682:f7594fc66bda
198 NDS_SetDisplayMode(_THIS, SDL_DisplayMode * mode) 198 NDS_SetDisplayMode(_THIS, SDL_DisplayMode * mode)
199 { 199 {
200 printf("+NDS_SetDisplayMode\n"); 200 printf("+NDS_SetDisplayMode\n");
201 /* right now this function is just hard-coded for 256x192 ABGR1555 */ 201 /* right now this function is just hard-coded for 256x192 ABGR1555 */
202 videoSetMode(MODE_5_2D | 202 videoSetMode(MODE_5_2D |
203 DISPLAY_BG2_ACTIVE | DISPLAY_BG3_ACTIVE 203 DISPLAY_BG2_ACTIVE | DISPLAY_BG3_ACTIVE |
204 DISPLAY_SPR_1D_LAYOUT | DISPLAY_SPR_ACTIVE); /* display on main core */ 204 DISPLAY_SPR_1D_LAYOUT | DISPLAY_SPR_ACTIVE); /* display on main core */
205 videoSetModeSub(MODE_0_2D | DISPLAY_BG0_ACTIVE); /* debug text on sub */ 205 videoSetModeSub(MODE_0_2D | DISPLAY_BG0_ACTIVE); /* debug text on sub */
206 vramSetMainBanks(VRAM_A_MAIN_BG_0x06000000, VRAM_B_MAIN_BG_0x06020000, 206 vramSetMainBanks(VRAM_A_MAIN_BG_0x06000000, VRAM_B_MAIN_BG_0x06020000,
207 VRAM_C_SUB_BG_0x06200000, VRAM_D_SUB_BG_0x06220000); 207 VRAM_C_SUB_BG_0x06200000, VRAM_D_MAIN_BG_0x06040000);
208 vramSetBankE(VRAM_E_MAIN_SPRITE); 208 vramSetBankE(VRAM_E_MAIN_SPRITE);
209 /* set up console for debug text 'n stuff */ 209 /* set up console for debug text 'n stuff */
210 SUB_BG0_CR = BG_MAP_BASE(31); 210 SUB_BG0_CR = BG_MAP_BASE(31);
211 BG_PALETTE_SUB[255] = RGB15(31, 31, 31); 211 BG_PALETTE_SUB[255] = RGB15(31, 31, 31);
212 /* debugging purposes, uncomment this later. then remove it & add 2screen. 212 /* debugging purposes, uncomment this later. then remove it & add 2screen.