Follow

`instance Monad Material where`

Sitting on my hands to avoid going full CPS on it (again)

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...)

@pmidden Translating "Ray tracing: the next week" book code to Haskell

Sign in to participate in the conversation
Qoto Mastodon

QOTO: Question Others to Teach Ourselves
An inclusive, Academic Freedom, instance
All cultures welcome.
Hate speech and harassment strictly forbidden.