News for hackers. Stuff that matters.
Re:Show HN: Monte Carlo ray tracer in Rust by boulos on Sunday April 19, 2020 @07:40PM (#22919740)
That’s pretty common, because the area lights are often very bright. So the subpixel values are either 0 or white hot (and much brighter than 1.0). If you model the light sources with actual physical units and do some sort of exposure process for the “film”, you can get a more natural result.
Re:Show HN: Monte Carlo ray tracer in Rust by Dalamar42 on Sunday April 19, 2020 @08:08PM (#22919903)
Do you happen to have a link to any reference material or paper explaining the technique you are describing or a term for it I can search for? I knew why this aliasing was happening, but I wasn't quite sure how to fix it.
Re:Show HN: Monte Carlo ray tracer in Rust by boulos on Sunday April 19, 2020 @08:24PM (#22920004)
I’d actually search for “tone mapping” for the camera / film part.

For physical light units you want to look for “lumens”, “lux” and “IES Lights” (though you probably don’t need to care about the directional profile). It’s super handy to be able to plug in real units sometimes like “oh, this lightbulb is 500 lumens, I’ll use that”.

Re:Show HN: Monte Carlo ray tracer in Rust by Dalamar42 on Monday April 20, 2020 @06:01AM (#22922538)
Thanks, I'll look them up
Re:Show HN: Monte Carlo ray tracer in Rust by pvg on Monday April 20, 2020 @02:30AM (#22921656)
I guess I assumed the apparent AA elsewhere was a result of some sort of post-processing but what you're describing makes more sense, thanks.
Re:Show HN: Monte Carlo ray tracer in Rust by Dalamar42 on Monday April 20, 2020 @06:07AM (#22922565)
The basic idea for the anti-aliasing is to take many samples inside every pixel and average them out which smooths outs the edges. The problem with the lights, as the other commenter explained, is that even with this the light is so bright that there is still a hard edge between the adjoining pixels.

[0] https://raytracing.github.io/books/RayTracingInOneWeekend.ht...