Jump to content

pacifist

Members+
  • Posts

    10
  • Joined

  • Last visited

pacifist's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. yes and no there are 4 rotation scaling values and 2 positional values that scroll the whole background (as I'm sure you know). from ndslib these values are #define BG3_XDX (*(vuint16*)0x04000030) #define BG3_XDY (*(vuint16*)0x04000032) #define BG3_YDX (*(vuint16*)0x04000034) #define BG3_YDY (*(vuint16*)0x04000036) #define BG3_CX (*(vuint32*)0x04000038) #define BG3_CY (*(vuint32*)0x0400003C) #define SUB_BG3_XDX (*(vuint16*)0x04001030) #define SUB_BG3_XDY (*(vuint16*)0x04001032) #define SUB_BG3_YDX (*(vuint16*)0x04001034) #define SUB_BG3_YDY (*(vuint16*)0x04001036) #define SUB_BG3_CX (*(vuint32*)0x04001038) #define SUB_BG3_CY (*(vuint32*)0x0400103C) When I change BG3_CX or BG3_CY then SUB_BG3_CX or SUB_BG3_CY change as well. This might well be true for the rot/scale data too. I just set them both to the identity.
  2. Alright! Dualis 10 is running things beautifully! I stopped using dualis a month ago and just started deving on my ds but dualis now emulates all the things important to me. Plus I can pass my game around to friends w/o a passme now. Hoorah for mic! Actually there is one minor thing that dualis 10 is doing wrong for me. When I set the scroll registers for gb3 the scroll registers for sub_bg3 also change. so the ndslib code BG3_CX = 50; BG3_CY = 50; scrolls BG3 as well as SUB_BG3. I can work up a quick demo to show it off if you like. Also, not surprisingly, fading to white does crazy bad things.
  3. ok I'm thinkin' the vblank stuff is my fault I went and grabbed the new version of ndslib, re-compiled, and dualis is havin' no troubles. although while I was building the demo I did notice that while on hardware this code displays one screen red and one screen blue on dualis they are both white. void irqVBlank(void) { IF = IRQ_VBLANK; } int main(void) { POWER_CR = POWER_ALL_2D; DISPLAY_CR = MODE_0_2D | DISPLAY_BG0_ACTIVE; SUB_DISPLAY_CR = MODE_0_2D | DISPLAY_BG0_ACTIVE; irqInitHandler(irqDefaultHandler); irqSet(IRQ_VBLANK, irqVBlank); PALETTE[0] = RGB15(0, 0, 31); PALETTE[512] = RGB15(31, 0, 0); while(1) swiWaitForVBlank; return 0; } Not a big deal for me, but I thought I'd mention it since I stumbled across it. sorry about the false alarm on the VBlank
  4. I can probably work out a demo for that as well if you like.
  5. I'm using mode 3 Here's a quick demo to show off the problem. http://on-tap.ca/Mode3.zip expected output is one screen with every second pixel red and the other with every second pixel yellow.
  6. Alright! I've been looking foreward to this version of dualis. I'm having some troubles though. Enabling the VBlank interrupt with this code irqInitHandler(irqDefaultHandler); irqSet(IRQ_VBLANK, irqVBlank); seems to always crash the emu. I can do it the long way: IME = 0; IRQ_HANDLER = &irqVBlank; IE = IRQ_VBLANK; IF = ~0; DISP_SR = DISP_VBLANK_IRQ; IME = 1; but only if I have turned the power to the screen on first POWER_CR = POWER_ALL_2D; and even then dualis crashes after I start excecuting code. Turning on a timer TIMER2_CR = (TIMER_ENABLE | TIMER_DIV_256); also crashes dualis if I haven't set the power cr yet. Also I'm having problems with my bitmap backgrounds: vramSetMainBanks(VRAM_A_MAIN_BG, VRAM_B_MAIN_BG, VRAM_C_SUB_BG, VRAM_D_SUB_SPRITE); vramSetBankE(VRAM_E_MAIN_SPRITE); vramSetBankI(VRAM_I_SUB_BG); SUB_BG3_CR = BG_BMP8_256x256 | BG_BMP_BASE(BMP_BASE) | BG_PRIORITY_1; for(int i = 0; i < 128*256; i++) ((u16*)BG_BMP_RAM_SUB(BMP_BASE))[i] = (u16)0; (note this code isn't a straight copy and paste there are other backgrounds being set-up, scaling registers being set etc...) this crashes when I try to initialise the background, that is, on this line: for(int i = 0; i < 128*256; i++) ((u16*)BG_BMP_RAM_SUB(BMP_BASE))[i] = (u16)0; I assume this is a VRAM thing but I don't really understand VRAM. I can work up a demo for any of this if you like. btw, mic, in my struggle to get various bitmap backgrounds going I stumbled upon your graphics notes and found them exTREMELY helpfull. thanks for posting them.
  7. ah beautiful! Looks just like the hardware.
  8. There I've worked up a really simple test. It just loads 4 different tiles into the 4 quadrants of the screen and then repositions the screen so you can see the point where they all meet. The four quarters of the screen should all contain different tiles. Works on DS but gives dualis 8 some trouble. http://on-tap.ca/64tiledBG.zip Thanks again for all the work on dualis! Cheers Colin Northway
  9. First off thanks an amazing amount for your work on dualis, it's a godsend for development. Secondly I've found a couple of bugs. When I specify rotational data for 16x16 sprites they end up cut in half. It happens regardless of what the transformation matrix is. The same doesn't happen with 8x8 sprites and it doesn't happen if I don't specify rotational information. Also I'm having problems with 64x64 tile backgrounds. The two top quadrants work fine but the two bottom two don't. They kind of mimick the bottom two.. or mabey dualis is trying to emulate 64x32 tile backgrounds? I can confirm that neither of these problems happen on the DS itself. If these aren't known bugs I'll work up a little demo to show them off. Cheers.
×
×
  • Create New...