News for hackers. Stuff that matters.
Re:Palette lighting tricks on the Nintendo 64 by typeofhuman on Saturday May 17, 2025 @11:01AM (#44014830)
It blows my mind how genius these game engineers were. They dealt with so many limitations and created such imaginative and brilliant solutions.
Re:Palette lighting tricks on the Nintendo 64 by Dwedit on Saturday May 17, 2025 @11:07AM (#44014875)
This is new stuff, not stuff done during the reign of the N64.
Re:Palette lighting tricks on the Nintendo 64 by bob1029 on Saturday May 17, 2025 @11:37AM (#44015062)
Only recently did we figure out how to make Mario64 run at 30fps.

https://news.ycombinator.com/item?id=31075622

Re:Palette lighting tricks on the Nintendo 64 by corysama on Saturday May 17, 2025 @01:49PM (#44015842)
Around the end of the PS2’s lifetime, some engine dev friends of mine figure out to do palletized spherical harmonic lighting on the PS2. That was pretty straightforward.

What was tricky was a separate technique to get real cubemaps working on the PS2.

Unfortunately, these came too late to actually ship in any PS2 games. The SH trick might have been used in the GameCube game “The Conduit”. Same team.

Re:Palette lighting tricks on the Nintendo 64 by OCASMv2 on Saturday May 17, 2025 @06:37PM (#44017539)
> What was tricky was a separate technique to get real cubemaps working on the PS2.

Any details on that?

Re:Palette lighting tricks on the Nintendo 64 by corysama on Saturday May 17, 2025 @09:01PM (#44018178)
If you lay out a cubemap as a 2d texture that looks literally like https://www.turais.de/content/images/size/w1000/2021/05/Stan... it's not hard, given the VU1-based triangle processing (like proto-mesh-shaders 25 years ago), to set the UVs of triangles independently to use the correct square even in the case of dynamic reflections. This doesn't do per-pixel spherical UV normalization. But, with a dense enough mesh, a linear approximation looks good enough.

Except... The triangle UVs will often cross over between multiple squares. With the above texture, it will cross over into the white area and make the white visible on the mesh. So, you fill the white area with a duplicate of the texels from the square that is adjacent on the cube. That won't work for huge triangles that span more than 1.5 squares. But, it's good enough given an appropriate mesh.

Probably would have been better to just use a lat-long projection texture like https://www.turais.de/content/images/size/w1600/2021/05/spru... Or, maybe store the cubemap as independent squares and subdivide any triangles that cross square boundaries.

Re:Palette lighting tricks on the Nintendo 64 by OCASMv2 on Saturday May 17, 2025 @09:48PM (#44018351)
Interesting, thanks!
Re:Palette lighting tricks on the Nintendo 64 by msk-lywenn on Sunday May 18, 2025 @02:29AM (#44019414)
I always thought triace had shipped sh lighting on ps2 but maybe it was just a demo?

http://research.tri-ace.com/Data/Practical%20Implementation%...

Re:Palette lighting tricks on the Nintendo 64 by corysama on Monday May 19, 2025 @03:38AM (#44027367)
They were doing per-vertex SH. That was a much more practical approach :)
Re:Palette lighting tricks on the Nintendo 64 by 90s_dev on Saturday May 17, 2025 @11:46AM (#44015117)
Limitations demand and produce extraordinary creativity. That's the secret behind pico8 and Animal Well and so many amazing games.

I wish I didn't think of a significantly better architecture for my 2d-pixel-art-game-maker-maker this weekend. Now it'll be another month before I can release it :(

Re:Palette lighting tricks on the Nintendo 64 by jebarker on Saturday May 17, 2025 @12:15PM (#44015291)
What were the limitations for Animal Well?
Re:Palette lighting tricks on the Nintendo 64 by 90s_dev on Saturday May 17, 2025 @12:22PM (#44015335)
- 320 x 180 screen size for starters

- Limited map size

- Limited color palette I think

- and more!

Re:Palette lighting tricks on the Nintendo 64 by jebarker on Saturday May 17, 2025 @12:31PM (#44015403)
Were those imposed as artistic choices rather than due to hardware limitations etc? I just asked because it shipped on PC and the major consoles, so any limitations seem like they were by choice.
Re:Palette lighting tricks on the Nintendo 64 by 90s_dev on Saturday May 17, 2025 @12:35PM (#44015438)
Yeah he talks about how it was a choice he made simply so he could get stuff done and have some end in sight.
Re:Palette lighting tricks on the Nintendo 64 by 01HNNWZ0MV43FF on Saturday May 17, 2025 @12:02PM (#44015223)
Limitations, and, popularity
Re:Palette lighting tricks on the Nintendo 64 by 90s_dev on Saturday May 17, 2025 @12:23PM (#44015344)
Popularity comes from utility. Utility comes from the right trade offs. Limitations demand careful trade offs.
Re:Palette lighting tricks on the Nintendo 64 by 01HNNWZ0MV43FF on Saturday May 17, 2025 @01:07PM (#44015613)
The tradeoff was that the N64 was cheap and had Pokemon on it
Re:Palette lighting tricks on the Nintendo 64 by amaranth on Saturday May 17, 2025 @01:48PM (#44015836)
The N64 is older than Pokemon.
Re:Palette lighting tricks on the Nintendo 64 by bonki on Saturday May 17, 2025 @04:43PM (#44016865)
Not true, the N64 was released a couple of months after the first Game Boy games.
Re:Palette lighting tricks on the Nintendo 64 by anthk on Sunday May 18, 2025 @05:18AM (#44020065)
Pokémon in Japan came much earlier. Also, the PSX was the cheap choice, among the rampant CD piracy vs the very expensive N64 cartridges.
Re:Palette lighting tricks on the Nintendo 64 by ninjin on Saturday May 17, 2025 @10:04PM (#44018426)
Cheap? In its generation the Nintendo 64 was the expensive choice. Maybe not because of the console itself (price varied across its lifetime relative to the competition) but because of the cost of the games (and nearly complete lack of piracy).

As for Pokémon, the Nintendo 64 launched in June 1996 and the first Pokémon game was Pokémon Snap released nearly three years after the console in March 1999.

Re:Palette lighting tricks on the Nintendo 64 by Sharlin on Saturday May 17, 2025 @12:57PM (#44015554)
I'm sure they were but, as noted, this specifically is 2025 stuff, and demoscene, not gamedev.