#softwarerendering

2025-04-23

Wrote some more about extending the "HAKMEM 149 line algorithm" to a quad rasterizer to be able to draw billboards (sprites) up to 3D sprites, the HAKMEM approach (and forward mapping) lose a bit of interest when degrees of freedom (and projection) are added up though but it was fun to retrace the sprites history a bit. :blobcatcomfysmirk:

onirom.fr/wiki/codegolf/main/#

#computergraphics #softwarerendering #algorithm

2025-03-18

Some neat trickery Ray the Rendering Engine can do.

This overhang is still done without variable ceiling heights.

#GameDev #IndieDev #RayCasting #SoftwareRendering

A little short stone laneway, but the left-most building juts over part of it, with wood supports seemingly holding it up.
2025-01-17

A tiny way to compute a square / triangle wave at the same time without conditionals, only basic arithmetic and shifts.

This can be used for #oscillators or animations etc. #algorithm is a variant of HAKMEM 149.

Can also be used to draw a square. (And other shapes, see previous toot)

Code also shows how to draw a diamond shape by rotating the square by 45°.

There are two versions, optimized for size and optimized for speed.

#computergraphics #p5js #softwarerendering #codegolf #sizecoding

Square wave and triangle waveform computed without conditionals, only basic arithmetic and shifts using HAKMEM 149 algorithm variants. Also show 2D shapes (square and diamond) drawn by combining the triangle and square value.p5js code of the algorithm optimized for size (has overdraw !)p5js code of the algorithm optimized for speed, the render code is moved outside the algorithm iteration loop, has much less overdraw except on the square wave code which is unchanged due to the sharp transition.
2025-01-03

A tiny way to draw an "isometric" (dimetric) cube in an iterative fashion with a single loop, all integers with an integer variant of HAKMEM 149 (so called Minsky circle) display hack. (Sin / Cos approximation)

Can also be used to draw a hexagon (it is a filled hexagon after all) and can easily render fractured cubes as well by varying "l" (second screenshot)

#cube #p5js #computergraphics #isometric #dimetric #hexagon #softwarerendering

Fractured cube render drawn iteratively. l = 720Dimetric cube code (JavaScript), iterative algorithm with HAKMEM 149 display hack, can also be used to draw a hexagon or a fractured cube by varying "l". "o" is draw offset.
2024-11-26

I've been writing some software rendering code, and one of the benchmarks I wrote produced some nice looking output! The most recent feature I implemented was MSAA for so the triangles could be anti-aliased.

#zig #SoftwareRendering #triangles

Many overlapping colored trianglesSame as the previous picture, but the triangles are anti-aliased.
Jari Komppa 🇫🇮 (has moved)sol_hsa@peoplemaking.games
2024-10-10

okay, now it's good enough.

#softwarerendering #fireforks #gif #sdl3

Jari Komppa 🇫🇮 (has moved)sol_hsa@peoplemaking.games
2024-10-07

Tutorial now updated to work with the latest sdl3:

solhsa.com/gp2/index.html

also includes a bunch of fixes and cleanups. A lot of new stuff coming as soonish. (Should I add fedi comments to these pages?)

(fyi @icculus)

#sdl #sdl3 #tutorial #programming #graphics #pixel #lowlevel #softwarerendering #wtfbbq

Client Info

Server: https://mastodon.social
Version: 2025.04
Repository: https://github.com/cyevgeniy/lmst