Blite: Nintendo DS

celshade_1

After programming for Win32 for most of the time I’ve been programming, and Playstation 2 for a little bit when I first came to university. I decided for a bit of change, and began to learn to make games on the Nintendo DS through homebrew.

Using a basic 3D engine I had wrote for the PC a long time ago when I first started making 3D programming, I ported it over. It was a little confusing at first, since I had no experience with fixed point numbers.

After a while, I discovered how to make Cel Shading working, there was very little documentation on how these things work on the Nintendo DS unless you were an actual developer. My initial attempts were to change the table to be filled with three shades of a colour, then switch it over when another colour material needed to be rendered. However this didn’t work, everything was the same colour.

In the end, I figured it out, what you needed was to fill the shading table with a few shades of white to black, then using a texture for a table of colours to use. When combined together, the texture with colours would colour things the correct colour, while the shading table would multiply against these and give a cel shaded effect.

One other annoying problem I had was with the FIFO, it was hard to debug the ARM7 since it kept breaking. Eventually it turned out you needed to clear the error flags if an error occurred.