3 ms·
Here's what I think is going on - - In raytracing, you're evaluating some complicated equation at each pixel location. In this case, there are some cosine comp
by thatcherc 6y ago
Here's what I think is going on -
- In raytracing, you're evaluating some complicated equation at each pixel location. In this case, there are some cosine components that have a really high spatial frequency, so you get that aliased TV-static-looking effect in some parts of the image
- One way to avoid that would be take many samples in a small region around each pixel location (at sub-pixel distances) which the author refers to as 'supersampling'. This would work except you'd need to raytrace a lot more points, which would slow down rendering
- What you could do instead would be (and this is what the post is mostly about) would be to replace the cosine(x) function with a function that is "the average value of cosine(x) from x-w/2 to x+w/2" - that's the big integral in the post. This function would effectively just be cosine(x) when x is much greater than w, but would average out the high-frequency cosine components of the image when x ~=< w
- The neat effect is that you can get the same smooth, alias-free image as you would with the expensive super-sampling operation just by using a modified version of cosine instead!
- 0-_-0 6y agoIn short: as the frequency of the cosine gets too high you gradually turn it off so you don't get aliasing from the high frequencies.