gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

DS development > Rotation and extended rotation backgrounds are the same?

#75293 - patroclus02 - Sat Mar 11, 2006 11:19 pm

I can't find much info abput this on DS
I know how to use EBR text mode background and framebuffer. But I wonder if EBR is the same as rotation background.

Also.. why do the possible map sizes vary depending on if you're using text mode background or ERB?

Thank you

#75297 - Webez - Sun Mar 12, 2006 12:26 am

Rotation bg are tiled

#75301 - patroclus02 - Sun Mar 12, 2006 1:00 am

So, rotatin backgrounds are tiled and ERB are bitmap only? or can they be tiled too?

#75304 - Webez - Sun Mar 12, 2006 1:19 am

Quote:
So, rotatin backgrounds are tiled and ERB are bitmap only?


I think so.

#75309 - DekuTree64 - Sun Mar 12, 2006 1:58 am

Text BGs are mostly the same as on GBA (4-bit or 8-bit char data, 16-bit map entries, size options 256x256, 512x256, 256x512, 512x512).

Normal affine BGs are the same as on GBA (8-bit char data, 8-bit map entries, size options 128x128, 256x256, 512x512, 1024x1024).

Extended affine uses the same sizes as normal affine, but with 16-bit map entries, so you can H/V flip each char. They can't use 4-bit char data though, but the palette field is used if expanded palettes are enabled (16 256-color palettes).

Extended affine layers can also be set as an 8-bit or 16-bit bitmap. 16-bit uses bit15 of each pixel as an alpha bit.
_________________
___________
The best optimization is to do nothing at all.
Therefore a fully optimized program doesn't exist.
-Deku

#75311 - tepples - Sun Mar 12, 2006 2:12 am

So extended rotation BGs replace GBA modes 3-5, right?
_________________
-- Where is he?
-- Who?
-- You know, the human.
-- I think he moved to Tilwick.

#75316 - SeanMon - Sun Mar 12, 2006 2:52 am

If 8-bit is used, how are the colors divided, 3r,3g,2b or is it 2r2g2b (with 2 unused)?

#75317 - DekuTree64 - Sun Mar 12, 2006 3:15 am

tepples wrote:
So extended rotation BGs replace GBA modes 3-5, right?

Yep, and nice to have all the other BG layers available at the same time.

SeanMon wrote:
If 8-bit is used, how are the colors divided, 3r,3g,2b or is it 2r2g2b (with 2 unused)?

8-bit paletted, like mode 4 on the GBA.
_________________
___________
The best optimization is to do nothing at all.
Therefore a fully optimized program doesn't exist.
-Deku

#75347 - patroclus02 - Sun Mar 12, 2006 9:54 am

So for normal affine BGs you can only address first 256 tiles (8 bit map entry)

What is the data format for the 16 bits map entry??
As far as I know, only 1024 tiles can be used.
This limitation is due to the 16 bits map entry having only 10 bits per screenblock entry. Am I wrong? If not, then 6 bits are not used, or are used for flip,... Where can I find info about what do rest bits stands for?

#75536 - patroclus02 - Mon Mar 13, 2006 11:31 pm

is this correct ?

Code:

Bit 15-12       Selects palette 0-15. Ignore if you use 256-col BG.
Bit 11          Horizontal flip
Bit 10          Vertical flip
Bit 9-0         Character number 0-1023

#75538 - DekuTree64 - Mon Mar 13, 2006 11:57 pm

patroclus02 wrote:
is this correct ?
...

Yep
_________________
___________
The best optimization is to do nothing at all.
Therefore a fully optimized program doesn't exist.
-Deku