top | item 41306589

How the SNES Graphics System Works

79 points| grigy | 1 year ago |fabiensanglard.net

25 comments

order

monero-xmr|1 year ago

Nand 2 Tetris (which gets posted on HN a lot, rightly) will give you a fundamental understanding of a lot of these low-level concepts https://www.nand2tetris.org/

A good exercise for the junior systems engineer, or someone who wants to fundamentally understand computers better than the REPL, is to build their own emulator.

There is likely a wealth of tutorials out there, but if there is not yet a canonical book on how to write an NES, Genesis, SNES, etc. emulator from scratch that can load real ROMs, I think this would really scratch an itch for the aspiring hardcore developer. It is a very illuminating exercise and given the performance of modern computers and the extensive number of graphics libraries for every semi-popular language in existence, I think a universal book could be written that pseudo-codes the concepts of emulation and enables developers of all stripes to build their own emulator.

j_m_b|1 year ago

I always upvote mentions of Nand2Tetris, this course helped me understand how computers REALLY work. I'm in the middle of writing a Typescript NES emulator. Even with the help of the excellent Mesen emulator, it's a challenging task! It amazes me how people could first write these emulators that worked so well in the 90s with such few resources.

k_sze|1 year ago

Here is an interesting tidbit: the Japanese version of the SNES was called Super Famicom. There was a physical notch that prevented Japanese cartridges from being used in the North American SNES. But for people who knew, it was actually possible to just cut off the notch in the North American SNES, and then you could use Japanese cartridges. My cousin gave me a Japanese Star Fox cartridge back in the days and I could play it on the North American SNES.

What I really never understood is how the whole system dealt with the differences between PAL and NTSC. For starters, the Japanese system outputs in PAL, which is 625 horizontal scan lines at ~25 fps. The North American system outputs in NTSC, which is 525 horizontal scan lines at ~29.97 fps.

Does anybody understand how that worked?

mmaniac|1 year ago

As other commentors have pointed out, Japan uses NTSC. PAL is mostly a European thing.

As far as the SNES is concerned, PAL consoles simply letterbox the video and run the game 16.6% slower. Occasionally the game speed is modified to account for the decreased framerate. Super Metroid's engine was sped up so that gameplay was faster frame-by-frame and approximately as fast in wall clock time, but this introduced a number of bugs.

It wasn't until framebuffer based consoles like the Playstation where using the extra lines of PAL signal became common. Game speed was still a common issue until the Dreamcast and PS2 where game speed ceased to be an issue and optional 60Hz support was also common.

deergomoo|1 year ago

As other people have said, Japan used an NTSC-based system.

I’m in the UK but I ended up buying a Super Famicom to play SNES games* because I didn’t want to play the crappy slowed-down PAL versions and a good-condition SFC was significantly cheaper than a US SNES. The Japanese/European case design is also way cooler than the US one imo.

Funnily enough the Sega Mega Drive/Genesis power supply is a perfect match for connecting a Super Famicom to a UK power socket.

*I know US SNES carts are physically larger and won’t fit in an SFC without an adaptor, but I was using a flash cart with an SFC-sized shell. I had it connected to a CRT at the time so I wanted real hardware rather than emulation.

Moru|1 year ago

Europe runs PAL, here it was popular to hunt TV's that could run NTSC because of the higher framerate. This leads to less flicker. All TV's that can run NTSC can also run PAL so you can switch between the 50/60 Hz as you need on computers. Can't remember how it was with consoles, once I got a computer I never really touched a console again :-)

jader201|1 year ago

FWIW, this seems to get reposted a lot. I think this is the fourth submission in the past 10 days. Three recent submissions:

https://news.ycombinator.com/item?id=41207608 (147 points, 8 comments)

https://news.ycombinator.com/item?id=41210537 (18 points, 2 comments)

https://news.ycombinator.com/item?id=41207756 (2 points, 0 comments)

redbell|1 year ago

> I think this is the fourth submission in the past 10 days.

I just checked those submissions, and it turned out they were posted in a single day (August 10th) with an eleven-hour time frame! The first submission was at 05:48 AM, the second at 06:37 AM (within less than an hour from the first), and the third at 16:24 PM, which raises one of the weirdest behaviors of the HN system (at least for me): "How or why on earth some submissions got accepted as 'duplicates' where others did not? ". I encounter this a lot when I try to submit a story and it gets rejected because it was already submitted. Sometimes, even if the original story is a month old or more!!

0xEF|1 year ago

I don't mind reposts now and then, since the odds of two people independently finding the same link interesting over time are pretty good, given the way things tend to circulate on social media and other aggregate platforms.

I also worry that HN is slowly turning into a karma farm like Reddit did. The point of reposting on HN just to build Internet Points escapes me,. At least on Reddit there was a market for accounts with high karma, so I guess I could see the motivation there. But here?

pvg|1 year ago

You can just flag it as a dupe or email hn@ycombinator.com if you think it's misranked.