Hacker News new | past | comments | ask | show | jobs | submit login
The Polygons of Doom: PSX (fabiensanglard.net)
242 points by guiambros 13 days ago | hide | past | web | favorite | 53 comments

I'm fascinated by the quote from Carmack:

>>The joke here is that if we ever do a CD version of DOOM, you are going to get the game and “The Making of DOOM” a one hour feature film.

I would pay good money for a proper documentary about the making of Doom! As someone who only looks at gaming from the outside as a casual gamer who happens to write software, something like that would be awesome! I've watched several "making of" histories of games on YouTube pieced together by fans. Getting a more direct, from the horse's mouth, account quite compelling.

You should absolutely get "Masters of Doom", which is exactly about the early days of id and how they build Keen, Wolf3d, and Doom. A really great read that sort of gives you a real-world "Halt and Catch Fire"-vibed story.

Smile/Amazon: https://smile.amazon.com/Masters-Doom-Created-Transformed-Cu...

It’s really a great book, especially if you grew up playing old shareware games. I generally won’t read a book for entertainment unless it manages to hook me within the first few pages. I read the entire book in a single sitting, I was so captivated by the storytelling.

There are a ton of YouTube documentaries and things.

From John Romero and Tom Hall: Doom: Classic Game Postmortem: https://youtu.be/NnkCujnYNSo

And a great one made by a fan: RetroAhoy: Doom: https://youtu.be/6A4-SVUHQYI

You can dig around YouTube and find a lot more. There are proper documentaries for DOOM (2016) by “NoClip”.

I'd like us to document as much as we can sooner rather than later (and not necessarily dramatized media) as DOOM is incredibly impactful in the games industry and I want us to understand it 200-300 years from now.

There is a book about it :P!

Can I just call attention to the fact that this webpage is amazingly well designed. It uses only a minimal amount of CSS and clean HTML but renders perfectly on both my mobile phone and desktop without additional logic.

Full time Front-End dev here-- this site is pure delight. Reading the markup and seeing the styles is a real pleasure. It's the web as it was always intended to be, simple, effective, effortless.

It uses monospaced type, and then does full justification by adding arbitrary extra space between words. Overall the legibility is awful, and typographers are puking.

I used my web browser’s “reader” mode on it.

Sorry you did not like the typesetting. It is hard to have an opinionated design and appeal to everyone. Happy you found a way to read it anyway. Also don't forget to wash your mouth, acid is bad for the teeth.

Sorry, Fabien, if that came across harsher or more personally than intended. I was exaggerating a bit for effect. I’m a fan of your work, and have found many of your posts insightful.

You are certainly welcome to style your page how you like. Justified monospaced text is a pretty big typographical faux pas though, and I personally find it pretty hard to read.

That might be true, but the radio buttons aren’t coded up correctly.

Tangentially, I’d argue that it’s missing an HSTS policy of redirecting pages to a canonical HTTPS version; e.g. TFA should be linked as https://fabiensanglard.net/doom_psx/

I just discovered this blog recently. I recommend reading the author's older stuff as well, there are some really good ones!

Same. As someone who began programming at the time knowing about IRQs, DMA and video card 'modes' was a requirement to do anything mildly advanced in graphics, this blog has been an enjoyable trip down memory lane and simpler times. Great read in these insane times we are living.

Fabien's books are also phenomenal:

- Game Engine Black Book: Wolfenstein 3D - https://www.amazon.com/gp/product/B0768B3PWV/

- Game Engine Black Book: DOOM - https://www.amazon.com/gp/product/1099819776/

He also posted earlier that the eventual revenue he receives from Amazon is about 50 cents from a $50 book. So it is not the best channel to buy his books.

This poor revenue is unfortunate. I sell my own self-published book on Amazon. I manage to make around 2.50$ on a 10$ book, but I willingly chose to forego colour and chose a very small print size.

Self-publishing is ill-equipped to deal with what amounts to a colour phone book. It seems its best bang for the buck is a text-only paperback, at around 200 pages.

I do understand why Fabian chose Amazon however. I get to sit in my pajamas on my couch, safe in the knowledge that my self-published book is available worldwide for around 10 US dollars with ridiculously cheap shipping. In my case, it meant I found an audience I didn't know would be interested in my book: Germans.

Is there a better channel? Would love a copy but would also like to get the author paid.

Do we know that other sources give him more of the cut?

Writing a technical book is rarely a big money-maker for the author, with or without Amazon.

Best is for you to get the free PDF and send a gift over paypal.

If I remember correctly, he said that online sales of PDF (e.g. Play Store) give a significantly larger cut.

Buy the book and then send a PayPal donation using the link at the top of their website.

Is there an ideal channel to buy physical copies of the books? I was thinking of getting a copy.

Love this blog. The only slightly negative thing I could possibly say about it is I wish the screenshot comparisons used <label for=""> instead of making me precisely click the radio buttons. Still more than worth it :)

Oh cool, I did not know you could do that. I have fixed the article now. Thank you for the tip, it was very useful :) !

You might also want to implement changing the image without using JS: https://kyusuf.com/post/completely-css-tabs/

you can put radio input inside the label element, less typing

> Trivia: In the source code of PSXDOOM-RE the ArchVile is completely removed. Even its #DEFINE is commented out.

  #define CC_ZOMBIE  "Zombieman"
  #define CC_SHOTGUN  "Shotgun Guy"
  #define CC_HEAVY  "Heavy Weapon Dude"
  #define CC_HELL   "Hell Knight"
  //#define CC_ARCH "Arch-Vile"
  #define CC_SPIDER "The Spider Mastermind"
  #define CC_CYBER  "The Cyberdemon"
  #define CC_HERO   "Our Hero"
That is hilarious and awesome.

I presume it's a simple way to cause compile error wherever code needs to be removed

This blog is a public service.

Yes! the blog is full of more articles just like this, i love this stuff.


> The whole system has no floating-point capability.


Not that uncommon back in the day. Even Doom on PC didn't use floating-point; instead relying on fixed point.

This set me reminiscing about the x87 series FP co-processors. Nice nostalgia break waiting for a build to finish, thanks!

Yes, and what few people know, is that x86 co-processors in general really only had to stick to the hardware interface given by Intel. What they actually did with that was up to the co-processor. Best known case in point were the Weitek math co-processors which were not actually machine code compatible with the Intel x87s.

Modern Vintage Gamer made a video[1] about this a few days ago

[1]: https://www.youtube.com/watch?v=x8TO-nrUtSI

I was going to link that video, especially considering regarding the problem of affine texture mapping. MVG discussed the common workaround in PSX: tesselating flat surfaces so the perspective distortion is minimized. I was surprised to see in OP's article that the PSX-Doom devs took a completely different approach of drawing a polygon for each scanline to emulate the PC-Doom's raymarching line-renderer.

This lead to some interesting issues when porting PC to PlayStation


Is this why geometries loved to jiggle and dance?

That's why I was so surprised! I've heard of early PCs omitting floating-point, but it seems crazy for a platform designed specifically for games, for precisely this kind of reason.

That's not the reason, though.

It seems so. A recent video about the graphical quirks of the PlayStation:

Why PlayStation 1 Graphics Warped and Wobbled so much https://youtu.be/x8TO-nrUtSI

The reasons mentioned in the video have nothing to do with the warping and wobbling, see what i wrote on Reddit about it: https://www.reddit.com/r/Games/comments/fnl0o1/why_playstati...

Yep. 16 bits isn't enough precision for 3D no matter how you use it.

When you get up to 32 or 64 bits, fixed and float are both very good.

Yes, though the affine texture mapping is not the only solution, just the easiest/ best conceptually at the time.

There's a port of Quake II to the Atari Falcon which has an interesting take on this lack of FP. See if interested:


In other news, does anyone know whether there is an initiative now for a PS2 emulator on the Raspberry Pi 4? When the new Pi came out one of the most interesting things to me was that PS2 emulation should (maybe) now be possible.

> The library (e.g: libcd, libds) developed by Psygnosis are also well detailed.

kudos to lemmings creators!

Psygnosis was the publisher of Lemmings (though they created most of the later sequels after Lemmings 2), DMA Design (aka Rockstar North) was the original creator of Lemmings.

oh God, you're right! DMA Design, they were truly amazing!

Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact