[HN Gopher] I wrote a Raytracer for DOS, 16 VGA colors (2011)
       ___________________________________________________________________
        
       I wrote a Raytracer for DOS, 16 VGA colors (2011)
        
       Author : whereistimbo
       Score  : 60 points
       Date   : 2021-01-17 15:42 UTC (7 hours ago)
        
 (HTM) web link (www.youtube.com)
 (TXT) w3m dump (www.youtube.com)
        
       | fortran77 wrote:
       | BTW: The Hebrew on the test pattern that appears in the start of
       | the video is Isaiah 12:3 "vshbtm mym bshshvn mm`yyny hyshv`h"
       | 
       | Not sure what it's doing there.
        
         | pan69 wrote:
         | He writes about religious stuff on his website. See "Writings"
         | section.
         | 
         | https://bisqwit.iki.fi/jutut/#h5
        
       | shdon wrote:
       | Bisqwit's channel is full of awesome stuff like this. Well worth
       | a look at his other videos too.
        
       | jezze wrote:
       | Bizqwit has done some phenomenal work. I loved his videos on how
       | DOOM style 3D engines work where he goes through raycasting and
       | BSP trees. He also has videos around how passwords work in old
       | 8-bit console games. His article about dithering I read a while
       | back was also super interesting and I can see that he used that
       | in this raytracer. Highly recommended.
        
         | endgame wrote:
         | His "doom-style engine" video is closer to BUILD than DOOM - it
         | recursively chases through convex sectors rather than using a
         | BSP tree.
         | 
         | I particularly love his older stuff, where the tech choices
         | were just plain _weird_ because that's all he had lying around
         | and needed to make stuff work.
        
         | blackhaz wrote:
         | His channel is jaw-dropping.
        
       | iamgopal wrote:
       | DJGPP.
        
       | ChuckNorris89 wrote:
       | I love stuff like this as it brings a smile to my face.
       | 
       | Reminds me of the time I was writing ESP/ESC software for car
       | ECUs back in the days before Simulink models and automatic code
       | generation where we had the vehicle dynamics books with all the
       | physics of the car, and had to convert the math functions from
       | continuous to discrete, then implement them in fixed point C,
       | along with trigonometric functions (the CPU had no HW SIN/COS),
       | optimized enough to run 100 times/second on a 16bit chip while
       | keeping CPU load under 85%.
       | 
       | Test drivers were in awe and thought it's voodoo. No, it's just
       | basic math implemented in C, similar to what Carmack was doing
       | for the Doom/Quake 3D engines ;)
        
         | mberning wrote:
         | I have always been curious how some of these ECUs worked behind
         | the scenes. I know many times when they were reverse engineered
         | by tuners the major tables such as ignition advance, fueling,
         | mass air flow, etc. would be identified and that would be
         | enough to allow some tuning of the car. But there were always
         | many tables with a mysterious purpose, such as tau adjustments,
         | which were never fully understood. I also wondered how values
         | were interpolated by the ECU considering most things are table
         | based. The tables might have 500 rpm, 1000rpm, etc cells with
         | timing values, but when you log the ECU you do not see big
         | jumps in timing at those cutoff points.
        
           | ChuckNorris89 wrote:
           | _> The tables might have 500 rpm, 1000rpm, etc cells with
           | timing values, but when you log the ECU you do not see big
           | jumps in timing at those cutoff points._
           | 
           | Because in the old days you had little memory to work with,
           | 32kb for PROGRAM(Flash) and 2kb for DATA(RAM), so you'd store
           | a few points in your table and use a linear interpolation
           | function for the rest. Now, because silicon is cheap, even
           | the chip controlling your headlights has 1MB of PROGRAM
           | memory or more and could run DOOM but instead of fancy algos
           | it's used to store all AutoSar libraries it needs for
           | networking and certification.
        
       | takeda wrote:
       | It's kind of interesting, it's supposedly about raytracer, but
       | raytracers even existed back then. I think the code that was
       | presenting him "typing" the raytracer code and then presenting it
       | was really the harder part to do.
        
         | ChuckNorris89 wrote:
         | IIRC we've had raytracers since the 60's since they're
         | basically trigonometry and vector math, but due to limited
         | memory computers at the time had it was never really used.
        
           | enneff wrote:
           | I used to use an open source ray tracer called POV-Ray in the
           | early nineties and it was pretty impressive. Here's an
           | example of an early scene you could render with it: https://a
           | mp.reddit.com/r/vintagecgi/comments/eswamt/chesspov...
        
           | ci5er wrote:
           | Well, the algorithm was developed in the 1600's, but I
           | remember Turner Whitted's 1979 SIGGRAPH paper blowing me
           | away. I mean, sure, they were slow, but before REYES, they
           | were about the only solution to GlobIlum. (Forward from the
           | lights and backwards from the camera - you could even do
           | specular lighting!)
        
         | egypturnash wrote:
         | http://www.etwright.org/cghist/juggler.html - similar work from
         | 1987 on an Amiga
         | 
         |  _Realtime_ raytracing didn't exist until recently but people
         | have been dabbling with doing it at much slower speeds, and
         | sequencing the resulting frames, for a long time.
        
       | airstrike wrote:
       | This is art, and I mean that in the most literal way possible.
        
       | minism wrote:
       | Love bisqwit's videos.
       | 
       | For anyone curious how the mario animation is rendered in the
       | editor:
       | https://github.com/bisqwit/that_editor/blob/master/mario.cc
        
       ___________________________________________________________________
       (page generated 2021-01-17 23:00 UTC)