Menger Sponge
Last weekend I found some time to tie together some loose ends of my Haskell ray-tracing project. The new functionality was first put into use to render the inevitable Menger Sponge as you can see below.
Here’s a quick rundown of what’s new with this iteration:
- added support for triangles (and meshes thereof); indeed everything visible in the above scene consists solely of triangles
- implemented a simple BVH for intersection acceleration; the performance still leaves something to desire, but at least it makes rendering scenes with more than like 15 primitives bearable
- there were several cleanups and simplifications all around, but it’s been a while and I don’t remember exactly…
And here’s a level 3 Menger Sponge on a “brushed metal” ground, which take ages to render, mainly because of the inefficient sampling of the glossiness:
About this entry
You’re currently reading “Menger Sponge”, an entry on Waldheinz
- Published:
- 3.8.11 / 8pm
- Category:
- English
- Tags:
- coding, graphics, haskell, raytracing


2 Comments
Jump to comment form | comments rss [?] | trackback uri [?]