Help - Search - Members - Calendar
Full Version: Background scrolling
1Emulation.Com > Official Emulator Forums > Dualis
pacifist
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
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.
mic
You're talking about the rotation/scaling position registers now, right?
pacifist
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

CODE
#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.
mic
Yes, what you call CX and CY are the rotation/scaling position registers. The real scrolling registers are BG*HOFS, BG*VOFS (which only apply to text BGs).
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2010 Invision Power Services, Inc.