libnds: REG_BG2X_SUB_H naming inconsistency

Post Reply
joseluisjazz
Posts: 2
Joined: Wed Apr 30, 2008 11:18 am

libnds: REG_BG2X_SUB_H naming inconsistency

Post by joseluisjazz » Sat May 03, 2008 7:19 pm

nds\arm9\background.h > lines 378 to 383.

Code: Select all

#define	REG_BG2X_SUB_L		(*(vu16*)0x4001028)
#define	REG_BG2X_SUB_H		(*(vu16*)0x400102A)
/*! \brief Background 2 Screen Offset (sub engine)*/
#define	REG_BG2Y_SUB		(*(vu32*)0x400102C)
#define	REG_BG2Y_SUB_L		(*(vu16*)0x400102C)
#define	REG_BG2Y_SUB_H		(*(vu16*)0x400102E)
should be changed to:

Code: Select all

#define	REG_BG2X_L_SUB		(*(vu16*)0x4001028)
#define	REG_BG2X_H_SUB		(*(vu16*)0x400102A)
/*! \brief Background 2 Screen Offset (sub engine)*/
#define	REG_BG2Y_SUB		(*(vu32*)0x400102C)
#define	REG_BG2Y_L_SUB		(*(vu16*)0x400102C)
#define	REG_BG2Y_H_SUB		(*(vu16*)0x400102E)
For consistency with all the rest of definitions.

And the doxygen comments at lines 394 & 398, should indicate "(sub engine)" instead of "(main engine)":

Code: Select all

/*! \brief Background 3 Screen Offset (main engine)*/
#define	REG_BG3X_SUB		(*(vu32*)0x4001038)
#define	REG_BG3X_L_SUB		(*(vu16*)0x4001038)
#define	REG_BG3X_H_SUB		(*(vu16*)0x400103A)
/*! \brief Background 3 Screen Offset (main engine)*/
#define	REG_BG3Y_SUB		(*(vu32*)0x400103C)
#define	REG_BG3Y_L_SUB		(*(vu16*)0x400103C)
#define	REG_BG3Y_H_SUB		(*(vu16*)0x400103E)
Last edited by joseluisjazz on Sat May 03, 2008 7:22 pm, edited 1 time in total.

WinterMute
Site Admin
Posts: 1989
Joined: Tue Aug 09, 2005 3:21 am
Location: UK
Contact:

Re: naming inconsistency between REG_BG3X_H_SUB & REG_BG2X_SUB_H

Post by WinterMute » Sat May 03, 2008 7:21 pm

Please create a patch for these issues and submit to the patch tracker.

http://sourceforge.net/tracker/?group_i ... tid=668553
Help keep devkitPro toolchains free, Donate today

Personal Blog

dovoto
Developer
Posts: 43
Joined: Fri Aug 12, 2005 10:01 pm
Contact:

Re: libnds: REG_BG2X_SUB_H naming inconsistency

Post by dovoto » Tue Jul 15, 2008 5:02 am

Corrected by removing definitions for low and high register parts (no idea why we even have them). Unless someone has a good reason for them being there in the first place?

Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 1 guest