It's actually pretty capable. The first images were simple, but had a point. Having seen the result it proposed a few tweaks. And after getting the sources for example scenes and elementary functions it picked up more stuff to its satisfaction.
Long time, no SIMD #Haskell
JK, the naivest stupidest binary tree blows fancy 4-way SIMDed BVH out of the water.
Actually, it may be slower by itself, but multicore apparently *destroys* wide instruction performance. At the same time cache^W completely oblivious scalar traversal is happy to run on all the capabilities available.
High ceremony 4-wide or primitive 10-/20-/whatever-wide?
BVH is love, BVH is life 📦
Ramped up samples, bounces, and resolution and the rendering time is still less than the first attemts with the linear traversal of all objects in the world.
Converting interaction event into a single-constructor with additive, multiplicative, and scatter components helped a little too.
Also, skipped ray bouncing when attenuation drops below 10-bit range. The limit practically remains to prevent infinite bounces between perfect mirrors.
Cornell box, here I come!
Textures are just `Material a` combinators concerned with producing stuff at hit points.
Since the Material is a Monad now, no need for special cases for colors and then another bunch of combinators for materials.
A sampler can be used to pick entire materials if needed.
(Ooops, I actually CPSd a little...)
Been fever-dreamin' some DIY material layering and light sources (before I get to the chapter 7 of the second book).
The amount of noise from emissive materials is.. ugh. Apparently this is why we bother with "light sources" instead of just dropping some light bulbs here and there.
Toots as he pleases.