by busfahrer · 1y ago · 0 comments
The PSX had no real 3D capability, you could just throw a list of triangles at it to draw. The problem here is that you have to sort the list of triangles yourself, since there is no such thing as a z-buffer.
For Crash Bandicoot, since the path is essentially linear, they were able to pre-sort most of the triangles at build time, which allowed them to achieve greater visual fidelity compared to contemporary titles that allowed for freer movement.
Another challenge was dealing with foreground objects: you have to somehow sort these into the pre-sorted background polygons. This mostly worked with bucket sorting but we had to use the gross hack of allowing each foreground object to have tunable “push-back” to fix sorting glitches. This required manual work for each level.
Finally, while precomputing the per-frame sort order for a game like Crash would be trivial now, in 1995 we had to build our own Beowulf cluster thingy and farm the level precompute out in pieces to the artists’ SGI workstations, and levels typically took an hour to process. The artists LOVED that. :)
Separate 2MB of main ram and 1MB of VRAM for 3MB total.
The packer was the final step after a level was pre-sorted and otherwise processed. It was quite fast, so it added only a little bit of extra time to the primary work of pre-rendering every frame of the level to recover the sort order (which typically took around an hour).
I did experiment with solver algorithms but they were so obviously going to be too slow that I abandoned the idea.
I sometimes wonder what the Nintendo 64’s library would have been like if they had sorted polygons on the CPU like other consoles of the era.