Nitro Engine doesn't work with the current libraries of devkitARM. It's
better to remove the makefiles and to stop pretending that devkitARM is
supported. Updating the makefiles wouldn't be enough, though, it's likely
that the library will require code changes, as well as the examples.
Until now the main makefiles of Nitro Engine have been the ones of
devkitPro, forcing users to go through extra steps to build everything
under BlocksDS.
Now, the easy makefiles are the BlocksDS ones, and additional notes have
been added to warn about the limitations of devkitPro:
- No GRF support in libnds.
- NitroFS doesn't work in melonDS.
Using global variables is generally discouraged. Now that NE_ProcessArg()
and NE_ProcessDualArg() exist, it's better to show how to use them instead
of NE_Process() and NE_ProcessDual() while using global variables.
Also, switch from "int main(void)" to "int main(int argc, char *argv[])".
This change is a bit pedantic, but it makes the ROMs run better in
DeSmuMe.
Some examples (particularly the dual 3D examples) used to flicker during
one or two seconds right after starting. In dual 3D examples the top and
bottom screen would start swapped, and they would eventually swap and
stop flickering. This would never happen in melonDS or real hardware.
I suspect this is because of the interaction between GFX_FLUSH and
swiWaitForVBlank(), where there would be some timing difference to reach
the first swiWaitForVBlank() or GFX_FLUSH, and that caused the desync.
This commit moves swiWaitForVBlank() to the beginning of the game loop.
This means that, even in the first iteration of the game loop, all
emulators and hardware will be synchronized. This doesn't actually
matter in any other situation, it just makes the first iteration
consistent.
- Provide the original assets for everything used in the examples. Add
scripts to convert the original assets into the formats used by the DS
instead of only providing the pre-converted files. The pre-converted
assets are still provided for convenience.
- Move away from BMP files in the examples: They aren't a realistic way
to use Nitro Engine to load textures. Use pre-converted PNG files
instead.