Open EGAMatsu opened 1 month ago
Unfortunately details about the SuperFX were kind of trade secrets, and most 3D rendering resources make hardware assumptions which the SuperFX does not satisfy, so it's very hard to find resources on algorithms that are of any use.
I don't know exactly what kind of details you want so here are some birdshot answers:
The most useful resources I found were the Rigid Geometric Algebra wiki (https://www.rigidgeometricalgebra.org) and Fabian Giesen's blog (https://fgiesen.wordpress.com/ particularly "Graphics Pipeline" and "Maths"), which for different reasons have very useful math in very useful forms (alongside a lot of irrelevant stuff). Although you may know enough math already.
For technical details I used the SNES dev manual, regs.txt, fullsnes, and the bsnes-plus (https://github.com/devinacker/bsnes-plus) source code.
As far as I can tell the best rendering method to use on the FX is a relatively "naïve" one: go through all the models on-screen to fill up a buffer with triangles; do rotation and perspective division to get screen-space coordinates; sort the triangles into furthest-to-nearest order; draw the triangles in order; upload the frame buffer to VRAM and make the PPU display it. It's probably easiest to write a renderer starting from the end of that sequence and working backward.
If you want the fussy details about how to manage frame buffers or caches or whatever I will need more specific questions.
I was wondering if we could talk on Discord?
I am new to the SuperFX and wanted too know the best sources for making a 3D renderer on the SFX?
I am planning to make a SuperFX API of sorts for pvsneslib, I got SFX code running, but don't know where too start.