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 > Help Choosing Video Mode

#125458 - KertDawg - Fri Apr 13, 2007 2:53 pm

Hello all,

I ask for any advice on how to accomplish something on the DS. I use devKitPro (the latest as of about a week ago), and DeSmuME 0.6.0. I'm new to PAlib, but I've used libnds and a little straight-up assembly. I use my R4DS, as well, for testing.

My primary goal is to have a large bitmap (1024x1024) pan and zoom on the DS top screen. The bitmap could be either 8-bit or 16-bit. If that isn't possible, then I could do without zooming. The next thing to drop would be the size. 512x512 would be better than nothing.

I can't seem to do this using PAlib or libnds. For instance, I tried to use an 8-bit bitmap background in PAlib. I couldn't find a way to scroll or rotate it. Then, I tried a large tile map (or whatever it's called in PAlib). When I converted the 1024x1024 bitmap to a tile map, it claimed that there were too many tiles. I completely understand that, but that left me with no good answer.

The best that I could do was pan four 256x256 tile maps separately to make one large 512x512 map. This, of course, doesn't let me do text or parallax, but it works.

Does anybody have any suggestions for which video mode I should use? I'm pretty sure that if somebody told me that it's possible in a certain video mode, then I'd be able to at least start.

Thanks in advance.
_________________
- Kertis

#125469 - Lick - Fri Apr 13, 2007 5:46 pm

You could do a 256x256 16-bit bitmap (in any mode with an Extended Rotation Background), and copy 256x192 from Main RAM to VRAM when needed.
_________________
http://licklick.wordpress.com

#125726 - silent_code - Mon Apr 16, 2007 11:31 am

for scrolling: take a 512x256 text bg (tiled) and simply shift the given tile row or column in the appropriate direction when you've moved the bg one tile. then reset the bg's position and repeat. you should keep track of unused tiles, that can be replaced by newly needed ones - of course only if you run out of tile memory. :^)
now, zooming is somewhat different. it would require more tiles and a bigger bg, but should also be doable. be warned: this may seem trivial, but it is not.

happy coding!