Commit graph

572 commits

Author SHA1 Message Date
Sean Maas
97a1eee0e6 Prevent edge touchscreen presses from wrapping around 2020-01-05 07:16:50 -05:00
Sean Maas
45d2f79b21 Rework the I/O register system to handle multiple bytes at once 2020-01-05 04:15:28 -05:00
Sean Maas
8e5f36574c Fix Z-buffering and add W-buffering 2020-01-03 19:50:58 -05:00
Sean Maas
9a17f7ac48 Get rid of floats in the 3D renderer 2019-12-30 02:58:14 -05:00
Sean Maas
f51c4cf560 Fix wraparound issues in both the 2D and 3D engines 2019-12-24 05:10:12 -05:00
Sean Maas
0f63c09d07 Fix texture palette address mask
This is the greatest derp of all time
2019-12-24 04:14:13 -05:00
Sean Maas
ef350b4c90 Implement texture coordinate transformation
Also convert vertex colors to RGB6 in the geometry engine
2019-12-24 00:42:38 -05:00
Sean Maas
f24f459766 Wait for V-blank before swapping buffers 2019-12-23 23:46:05 -05:00
Sean Maas
da5c0dfb86 Fix Windows builds 2019-12-22 17:33:04 -05:00
Sean Maas
d6d9a90c6b Fix interpolation to be perspective-correct 2019-12-17 00:14:56 -05:00
Sean Maas
2c96f7a37d Implement proper clipping 2019-12-16 22:41:34 -05:00
Sean Maas
bfd2f9acea Implement texture clamping and flipping 2019-12-12 01:15:20 -05:00
Sean Maas
854d96d5fe Handle GXFIFO overflows a bit better 2019-12-12 00:34:28 -05:00
Sean Maas
15ee56d5b8 Update for libnx v3.0.0 2019-12-11 22:19:08 -05:00
Sean Maas
ab10541dbe Prevent off-screen polygons from being stored in memory 2019-12-11 22:07:26 -05:00
Sean Maas
f902032636 Implement GXFIFO DMA timing 2019-12-09 23:58:00 -05:00
Sean Maas
aa499e1f96 Switch to 18-bit color precision 2019-12-08 22:54:27 -05:00
Sean Maas
5a376b7555 Implement the remaining texture formats
Also optimize vector normalization by only doing it once per frame
2019-12-08 14:50:52 -05:00
Sean Maas
ea0c7e45e7 Fix major cases of exploding vertices 2019-12-08 08:25:31 -05:00
Sean Maas
34380bb568 Minor fixes to how polygons are stored
Fixes texture issues that some games were experiencing
2019-12-07 18:30:46 -05:00
Sean Maas
f4e7202ebb Initial texture implementation 2019-12-07 04:38:55 -05:00
Sean Maas
17a0989e6b Render filled geometry and add Z-buffer and interpolation 2019-12-05 13:07:43 -05:00
Sean Maas
443274f9de Various 3D-related fixes and improvements
Properly handle "current" matrices
Add clip matrix result registers
Draw quad strip vertices in the correct order
2019-11-25 04:39:21 -05:00
Sean Maas
e97efc4c62 Implement LDRD/STRD instructions
Also make vertex color persistent
2019-11-15 16:26:15 -05:00
Sean Maas
11a52a75a6 Add missing vertex commands and render wireframe polygons 2019-11-15 01:39:45 -05:00
Sean Maas
ab30267d09 Fix screen flickering on Windows 2019-11-14 17:48:01 -05:00
Sean Maas
363116ca25
Merge pull request #1 from matrizzo/macos_ui_fix
Make the UI work on macOS
2019-11-14 15:44:53 -05:00
Matteo Rizzo
bd56591775 Make the UI work on macOS 2019-11-14 21:25:46 +01:00
Sean Maas
86c786df8a Set up automatic builds for macOS and Switch 2019-11-14 14:18:09 -05:00
Sean Maas
6b0e67dfbf Set up automatic builds for Linux and Windows
Also fix compilation on Windows
2019-11-13 23:33:48 -05:00
Sean Maas
b8241163c0 Implement some geometry commands and render some dots
A bit of a mess right now, but hey, you can almost make out some
actual graphics!
2019-11-12 02:01:12 -05:00
Sean Maas
920a678b92 Add the GXFIFO and related registers
Doesn't actually implement any commands yet, but it pretends to run
them which stops 3D games from hanging
2019-11-07 16:35:43 -05:00
Sean Maas
4959c31624 Ensure the save file actually gets written on desktop
Also "implement" the page program command for FLASH saves
2019-11-06 01:51:12 -05:00
Sean Maas
2f7ad8e4e9 Add support for extended affine backgrounds, part 2 2019-11-06 00:45:46 -05:00
Sean Maas
85b75fdaaf Add support for extended affine backgrounds, part 1
Also made the master brightness registers readable
2019-11-05 20:27:45 -05:00
Sean Maas
1f2a9a88e1 Implement master brightness 2019-11-03 20:49:16 -05:00
Sean Maas
7afca33b2e Basically rewrite everything
Well, the interpreter and memory were completely rewritten. Most of
the other stuff wasn't changed too much, apart from some cleanup and
reorganization. Oh, and it's object-oriented now. And endian-safe.
And faster and more accurate!

(I won't do anything like this again I swear)
2019-11-02 21:37:21 -04:00
Sean Maas
c5748e0491 make the framelimiter cross-platform 2019-09-18 17:48:43 -04:00
Sean Maas
e36febdcdf mask out PC bit 1 in ARM mode 2019-09-08 15:20:25 -04:00
Sean Maas
f0e28d35c7 add support for mapping VRAM to the ARM7
also set registers before copying rom to memory for direct boot
to fix some homebrews
2019-09-07 19:35:14 -04:00
Sean Maas
b78fb9f734 add support for rotscale objects 2019-09-07 15:26:32 -04:00
Sean Maas
a36e27a99e improve direct boot so it works with commercial games 2019-09-02 17:43:31 -04:00
Sean Maas
1e20af28a9 implement 2D object mapping 2019-08-30 14:16:08 -04:00
Sean Maas
5801cb205e optimize CPU halts 2019-08-26 23:06:45 -04:00
Sean Maas
1efbc808a9 write the save file on the switch as well 2019-08-26 18:11:27 -04:00
Sean Maas
f433bc88c2 add save support 2019-08-26 17:33:00 -04:00
Sean Maas
ba5fd6df44 implement SMLAXY and SMULXY opcodes 2019-08-24 17:04:27 -04:00
Sean Maas
60fae4cda8 add touchscreen support 2019-08-19 01:54:10 -04:00
Sean Maas
807620829e make BIOS read-only 2019-08-17 23:10:47 -04:00
Sean Maas
523ba62393 object priority, text bg fixes, partial cleanup 2019-08-17 00:15:10 -04:00