Live data from Hacker News

New 3D FPS released for 1979 Atari 800

atari8.dev

61–70 of 78 posts

Re: New 3D FPS released for 1979 Atari 800

#61

Having written realtime ray tracers in the classic demoscene style on e.g. 300 MHz Pentium 2 Celeron (the original one with no cache, that overclocked to 450-550 MHz), I sometimes wonder about how cool it would be to open source a modern rendering engine around the time of the first Pentium 3 with SSE, in 1999. You could completely revolutionise computer graphics on that era of hardware, with the view to increasing v…

The game uses ray casting, not ray tracing. Ray casting is when you send a ray once for every column of pixels to get a distance to a wall. Also, if the walls are only horizontal or vertical the calculations get simpler. Also I wonder how you can achieve clock frequency like 300 MHz without a cache. Shouldn't CPU stumble on fetching every command?

The Covington Celerons had an L1 cache but no L2 cache. The Pentium II of the era had an off-die L2 cache. So the accelerometer was a binned Pentium II without any L2 cache. A later model of the Celeron was released with a 128k L2 off-die L2 cache.

At its base clock speeds the Celerons were middling chips. But since they readily overclocked you could get them up to 450-466MHz. They wouldn't be equivalent to the same speed Pentium II (because of no L2 cache) but they punched above their weight for the price.

Re: New 3D FPS released for 1979 Atari 800

#62
post #4

Earlier quoted context omitted.

the FPS is really smooth - and the floating point (?!) calculations of the raycasting engine seem to be totally "on point" ?!?!

So I was curious about how the Atari 800 handled floating point calculations. As it turns out, Steve Wozniak helped develop the FP routines for the 6502. http://archive.6502.org/publications/dr_dobbs_journal_select...

I doubt there are any floating point numbers because FP is very slow to emulate (for example, just to add two numbers you have to shift mantissas and 6502 has no fast way to do it). If I was writing a game for an 8-bit CPU, I would use fixed point numbers (for example, 8.8 numbers which use 8 bits for integral part and 8 bits for the fractional part, or maybe 10.6, or 12.4 numbers).

6502 cannot multiply or divide (division is a costly operation even on modern CPUs) so I would use adding or subtracting logarithms for this purpose. 12-bit precision logarithm table requires just 8 Kb RAM (and you can get 13-bit precision with interpolation).

The disadvantage of this approach is that every time you convert a number from linear to logarithm or vice versa you get approximately up to 0.3% error (for 12-bit logarithm). So multiplying or dividing several numbers in a row is fine, but if you have to alternate multiplication with additions you will accumulate an error. So I would look for formulas that avoid this. But for a game a little error in calculations is not noticeable.

Also one might think that the most time-consuming part for pseudo-3D game is math and calculations. I doubt that. The most of CPU cycles are usually spent in rasterisation and applying textures. Is is easy to calculate positions of 3 vertices of a triangle, but it takes a lot of time to draw it line by line, pixel by pixel, and if you want to have textures this time can be multiplied 5x-10x.

Re: New 3D FPS released for 1979 Atari 800

#65
post #54

Earlier quoted context omitted.

Yes, it had a lot of custom chips, and some of the same people (like Jay Miner) who worked on the Atari 800 design later were involved in designing the Amiga which likewise was based on custom chips.

there were 3 custom chips (ANTIC, GTIA and POKEY) 1 semi-custom (SALLY was a VERY MINOR modification of 6502) and 1 common industry chip (PIA). I would not say exactlly "lot of" ;-)

Well, relatively speaking that was a lot for late 1970s microcomputers. The original Apple ][ and TRS-80 Model I were essentially built from off the shelf chips (which is why both got off-brand clones).

Re: New 3D FPS released for 1979 Atari 800

#66
post #60

Earlier quoted context omitted.

The game uses ray casting, not ray tracing. Ray casting is when you send a ray once for every column of pixels to get a distance to a wall. Also, if the walls are only horizontal or vertical the calculations get simpler. Also I wonder how you can achieve clock frequency like 300 MHz without a cache. Shouldn't CPU stumble on fetching every command?

> The game uses ray casting, not ray tracing. Ray casting is when you send a ray once for every column of pixels Both ‘ray casting’ and ‘ray tracing’ are overloaded terms, the distinction isn’t as clear as you suggest. You’re talking about 2d ray casting, but 3d ray casting is common, and means to many people the same thing as ‘ray tracing’. Ray casting “is essentially the same as ray tracing for computer graphics”.…

I've given up on the semantics of "ray-tracing", everyone has their own opinion. However it's fairly common for "ray-casting" to mean non-recursive, and the wiki article you link explicitly says this.

I think the biggest difference between ray-type algorithms is everything vs ray-marching, because regardless of recursion, and strategies towards lighting, texture sampling and physical realism, with ray-marching a single ray is not really a ray at all but lots of little line segments, and you don't usually bother finding explicit and intersections which gets really complex and expensive... that's the whole point, instead you find proximity or depth, which means you can render implicit surfaces like fractals.

Re: New 3D FPS released for 1979 Atari 800

#67
post #66
post #60

Earlier quoted context omitted.

> The game uses ray casting, not ray tracing. Ray casting is when you send a ray once for every column of pixels Both ‘ray casting’ and ‘ray tracing’ are overloaded terms, the distinction isn’t as clear as you suggest. You’re talking about 2d ray casting, but 3d ray casting is common, and means to many people the same thing as ‘ray tracing’. Ray casting “is essentially the same as ray tracing for computer graphics”.…

I've given up on the semantics of "ray-tracing", everyone has their own opinion. However it's fairly common for "ray-casting" to mean non-recursive, and the wiki article you link explicitly says this. I think the biggest difference between ray-type algorithms is everything vs ray-marching, because regardless of recursion, and strategies towards lighting, texture sampling and physical realism, with ray-marching a sing…

Yes, ray casting does not ever imply recursion, it’s simply referring to casting a ray to test visibility from one point to another. Ray tracing now most commonly means exactly the same thing, and expecting anything else will often lead to confusion.

“Ray marching” is also overloaded ;) but what you’re referring to (also and originally called ‘sphere tracing’) is a new and separate idea from either ray casting or ray tracing (if you’re thinking of something other than ray casting when you say that.) Ray casting/tracing is most often done using non-iterative analytic intersection functions, where the style of ray marching you’re referring to is a distance field query, not a point to point visibility query, so ”ray marching” generally implies a different traversal algorithm, and (usually) a different representation of the geometry.

You can use any/all of these to build path tracers, but they come with different tradeoffs.

Re: New 3D FPS released for 1979 Atari 800

#68
post #2

Slovak group GMG released a full featured FPS for 40+ year old computer (64kb of ram, 1.79Mhz 6502) Features: - raycaster engine running at 25 - 30 FPS - animated textures - lighting system - destroyable walls - automap - 3 enemy types - final boss game is fully playable in Altirra emulator video: https://www.youtube.com/watch?v=lRd3MucaRoU homepage: https://atari8.dev/final_assault discussion: https://atariage.com/f…

- 80x30 resolution

- mostly 8 colors

Its impressive, but unplayable.

Re: New 3D FPS released for 1979 Atari 800

#69

Earlier quoted context omitted.

The game uses ray casting, not ray tracing. Ray casting is when you send a ray once for every column of pixels to get a distance to a wall. Also, if the walls are only horizontal or vertical the calculations get simpler. Also I wonder how you can achieve clock frequency like 300 MHz without a cache. Shouldn't CPU stumble on fetching every command?

The Covington Celerons had an L1 cache but no L2 cache. The Pentium II of the era had an off-die L2 cache. So the accelerometer was a binned Pentium II without any L2 cache. A later model of the Celeron was released with a 128k L2 off-die L2 cache. At its base clock speeds the Celerons were middling chips. But since they readily overclocked you could get them up to 450-466MHz. They wouldn't be equivalent to the same…

The Celeron-A's had on-die cache, making them pretty much a match for a regular P2 of the same clock/bus speed. There was also a mobile P2 with 256K of on-die L2, predating Coppermine P3's.

Re: New 3D FPS released for 1979 Atari 800

#70
post #7
post #4

Earlier quoted context omitted.

the FPS is really smooth - and the floating point (?!) calculations of the raycasting engine seem to be totally "on point" ?!?!

Comment a bit of a limitation of the ray casting: https://atariage.com/forums/topic/326709-final-assault-new-g... simply amazing what they did. could you imagine if this came out in the 80s?!?!

I could tell something was off, but couldn't put my finger on it. Very cool
Post reply on HN