
Dissecting the 128-byte raycaster (2014) - petercooper
http://finalpatch.blogspot.com/2014/06/dissecting-128-byte-raycaster.html
======
nategri
Bonus content: Terry Davis randomly shilling TempleOS in the comments.

~~~
welfare
What happened to that guy? Haven't seen anything lately.

~~~
TekMol
Alive and kicking:
[https://www.youtube.com/user/COCONUT202](https://www.youtube.com/user/COCONUT202)

~~~
busterarm
So he's not homeless?

~~~
monocasa
AFAIU, he's on disability pretty much permanently.

Which I'm all for FWIW.

------
a_t48
The author implemented\improved the shader as
[https://www.shadertoy.com/view/MdXXz2](https://www.shadertoy.com/view/MdXXz2)

I copypasted the original code here -
[https://www.shadertoy.com/view/MdtcDX](https://www.shadertoy.com/view/MdtcDX)
\- neat!

------
petercooper
Heads up to userbinator who posted about this in yesterday's mini Wolfenstein
post BTW:
[https://news.ycombinator.com/item?id=16534119](https://news.ycombinator.com/item?id=16534119)

------
AtomicOrbital
writing in assembly is such a joy ... cuts to the essence ... such speed,
power and danger ... especially when doing graphics pre gpu ... your post
inspires me to get back on that saddle ... loved back when I found how to
control one pixel then over a few days implemented bresenham's line algorithm
then had objects moving in 3d with perspective projection all in a few pages
of code, of course no libraries ... electrical engineering majors who get
assembly as their first programming course like me are exposed to programming
in the spirit of a chainsaw haircut

great post

------
s-macke
To calculate a simple xor (color=x ^ y) to produce a texture for walls was a
common hack in the early days of computer graphics. I used it frequently under
DOS. It is still useful for these kind of hacks :-)

~~~
hoosieree
It's visually distinctive as well. As soon as I saw the screen capture I
thought "that's an XOR".

~~~
msarnoff
It's known as "munching squares":
[https://en.wikipedia.org/wiki/Munching_square](https://en.wikipedia.org/wiki/Munching_square)

------
finalpatch
Author (of the article, not the demo) here. I still remember debugging this
thing in Turbo Debugger in DosBox and the CDQ instruction was causing trouble
because Turbo Debugger could not recognise it.

------
Tepix
I just tried it in dosbox 0.74 on Linux and it doesn't work - it renders very
slowly and nothing that looks like that youtube video. Does it work for anyone
else?

------
bhhaskin
Thanks for posting this! It was a great read. I have always been interested in
low level graphics programming.

------
jfacoustic
That's real time? Awesome!

