Commit Graph

45 Commits

Author SHA1 Message Date
Antonio Niño Díaz
5a10679dfb build: docs: Remove outdated devkitARM makefiles
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.
2025-03-24 21:03:01 +00:00
Antonio Niño Díaz
39117696aa build: Uniformize all devkitARM makefiles
Add DATA and GRAPHICS directories to all of them so that it's easier to
maintain the files.
2024-12-31 16:20:02 +01:00
Antonio Niño Díaz
1c752174e9 examples: Stop using NE_RGB5 in examples
This texture format sets bit 15 manually to 1. This is slow, and it's
better if the developer converts graphics in a way that the bit is already
set to 1.
2024-06-03 18:39:33 +01:00
Antonio Niño Díaz
935f7eb084 examples: Update binaries used by the examples
This isn't strictly required, but this way running the global assets.sh
won't cause lots of files to be marked as modified.
2024-06-02 21:55:32 +01:00
Antonio Niño Díaz
0f92fc9da7 build: Use BlocksDS paths for assets conversion scripts 2024-06-02 21:50:06 +01:00
Antonio Niño Díaz
3ba35ba48e docs: build: library: examples: Set BlocksDS as main toolchain
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.
2024-06-02 17:38:52 +01:00
Antonio Niño Díaz
12b7389d1f examples: Remove asset from example that doesn't use it 2024-03-29 19:39:12 +00:00
Antonio Niño Díaz
82171bbf69 chore: Simplify copyright years in notices
Instead of listing every individual year, keep only the first and last
years.
2024-03-09 01:42:29 +00:00
Antonio Niño Díaz
47c8061168 examples: test: Refactor to avoid global variables
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[])".
2024-03-08 18:44:02 +00:00
Antonio Niño Díaz
9f81541075 examples: Remove global variables from some examples 2024-03-08 02:43:18 +00:00
Antonio Niño Díaz
052a15b974 example: Stop using deprecated NE_ShadingEnabled() 2024-03-07 01:49:25 +00:00
Antonio Niño Díaz
bf63ddea8a examples: Remove unneeded calls to NE_ShadowEnable()
This function wasn't required for regular shading, but for toon shading.
2024-03-07 01:49:07 +00:00
Antonio Niño Díaz
edf4457d49 examples: Fix typo 2024-03-06 22:02:30 +00:00
Antonio Niño Díaz
e952990ae4 examples: Improve volumetric shadow example
The light in the dark room was too bright.
2024-03-06 21:41:11 +00:00
Antonio Niño Díaz
3273bd7333 examples: Fix comment 2024-03-06 21:41:11 +00:00
Antonio Niño Díaz
5a2b722128 examples: Add shadow volume example 2024-03-06 21:41:11 +00:00
Antonio Niño Díaz
83dd805fe8 examples: library: docs: Fix "properties" typo everywhere
Function names have also been changed, but this patch adds defines to
preserve compatibility with old names for the time being.
2024-02-05 01:45:14 +00:00
Antonio Niño Díaz
33f9bd4416 examples: Remove unneeded casts
They were needed in older versions of Nitro Engine, but now the functions
that take data arrays expect a void pointer, so casts are not needed.
2024-01-27 19:33:56 +00:00
Antonio Niño Díaz
55a53a91dc examples: Add warnings to BlocksDS makefiles 2024-01-27 18:31:17 +00:00
Antonio Niño Díaz
c037b79af4 examples: Stop using img2ds and switch to grit
img2ds is still required for the clear bitmap example because grit doesn't
support the clear depth format.
2024-01-27 18:25:38 +00:00
Antonio Niño Díaz
6fde18d712 library: examples: Use stdint.h types 2023-11-17 01:00:40 +01:00
Antonio Niño Díaz
0d5bd874e8 examples: library: Simplify dual 3D mode selection
Instead of having a different set of functions for each dual 3D mode,
have one set of functions that is clever enough to select the right code
to run based on the initialization function.
2023-10-09 22:58:10 +01:00
Antonio Niño Díaz
16258d711f examples: Add safe dual 3D examples 2023-10-09 01:32:06 +01:00
Antonio Niño Díaz
d659bc8915 build: docs: Support BlocksDS 2023-04-01 15:15:02 +01:00
Antonio Niño Díaz
8c42302c23 build: Small changes to assets.sh scripts and ROM titles 2023-04-01 14:35:09 +01:00
Antonio Niño Díaz
00568feec2 build: Add scripts to build assets in all examples 2023-04-01 13:33:38 +01:00
Antonio Niño Díaz
1acfca1a24 examples: Wait for VBL in the right place
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.
2023-01-21 19:32:02 +00:00
Antonio Niño Díaz
7ff191fe42 examples: Improve specular material example
Show the models with diffuse and specular materials at the same time.
2022-10-25 23:50:50 +01:00
Antonio Niño Díaz
65bdac84a5 examples: Prevent using an empty shininess table 2022-10-25 18:42:06 +01:00
Antonio Niño Díaz
6b992279d3 examples: Improve specular material example 2022-10-25 18:30:35 +01:00
Antonio Niño Díaz
9e813fc6ef examples: Repurpose example as a specular material example
The model wasn't really high poly anyway, this example will be more
useful.
2022-10-24 23:01:13 +01:00
Antonio Niño Díaz
3ebcac15ba library: examples: Add enums for texture formats and parameters
This helps discover the possible options.
2022-10-20 01:51:19 +01:00
Antonio Niño Díaz
185d477271 examples: Cleanup almost all remaining examples 2022-10-20 00:14:36 +01:00
Antonio Niño Díaz
da2be26de1 examples: Change license to CC0-1.0 2022-10-16 22:55:06 +01:00
Antonio Niño Díaz
db8add4d7e example: Cleanup source files 2022-10-16 22:03:41 +01:00
Antonio Niño Díaz
1b4d3270dc library: Cleanup code and add missing enum entries 2022-10-16 02:35:54 +01:00
Antonio Niño Díaz
e98698febf Update Makefiles to the ones used by devkitARM now
Fetched from:

    6afa09b205

Reported by lifehackerhansol:

    https://github.com/DS-Homebrew/TWiLightMenu/issues/1753
2022-01-18 18:23:23 +00:00
Antonio Niño Díaz
3d58fcd273 Fix name of variable for consistency 2019-06-13 00:31:51 +01:00
Antonio Niño Díaz
930916fa35 Minor fixes to examples 2019-06-09 01:58:58 +01:00
Antonio Niño Díaz
01f57b8609 Fix coding style of remaining effects examples 2019-06-04 18:08:18 +01:00
Antonio Niño Díaz
7d31063039 Convert all example files to UNIX line endings 2019-06-04 17:56:18 +01:00
Antonio Niño Díaz
f59b181ce5 Fix coding style of more examples 2019-06-04 17:54:34 +01:00
Antonio Niño Díaz
2a9a2ce0cc Change expected install path of Nitro Engine
Now it should be $(DEVKITPRO)/nitro-engine
2019-06-04 16:40:00 +01:00
Antonio Niño Díaz
c2c9b41c9a Fix style of Makefiles
Also, convert line endings to UNIX-style endings.
2019-06-04 16:36:20 +01:00
Antonio Niño Díaz
4640f17c4a Rename all folders to lowercase 2019-06-04 15:57:30 +01:00