Agreed, ray tracing will make SSAO less necessary. One of the goals of ray tracing is to be able to unify all the ad-hoc techniques like SSAO into one easier to use framework.
Ray traced games might still have over-darkening though, at least initially. A lot of ray tracing code I’m seeing is using very short max distances for AO rays. This helps with both tracing performance and with noise. But I think looking at too small of a local neighborhood is a big part of what’s responsible for the over-darkening the author is pointing out. To get realistic corner darkening, you really need path tracing or some other global illumination rendering.
> Ray traced games might still have over-darkening though, at least initially.
Couldn't we get around that similar to how we used to get around draw-distance back in the day with fake "fog" by assuming distant rays are more scattered, and hence can be modeled by less rays somehow?
Yeah, I think we could. There are definitely a bunch of ways to somewhat mitigate over-darkening. We can never completely get around it, though, unless we just go for global illumination. And still in that case, we definitely want to assume & leverage your idea that distant rays are more scattered. Aside from that, separating AO from material will always cause some kind of problem.
Methods like Adaptive Raytracing [1] should allow raytracers to mix large and small max distances and use machine learning to spot the differences and estimate it for all the rays even though a tiny percentage of rays were actually to a large distance.
It would be pretty interesting to use a neural network for AO! It's a good coincidence you linked to SSIM based adaptive sampling, I'm actually using the research you linked to: I implemented the OptiX API for SSIM prediction. So far, we've used it for choosing where to send more rays, but I'm not aware of anyone using it to adapt the max distance for AO rays. That might be fun & fruitful to try!
I'm not certain, but I think in theory that capping the max distance will always bias the AO (to the extent that AO even makes physical sense). You can reduce the bias by mixing lengths, but I'm not sure if you can ever fully compensate for it. More importantly, it's always (theoretically) biasing to separate AO shading from the normal surface shading & lighting calculation. AO is a beautiful simple hack, but I'm not sure it will survive the future, especially as ray and compute budgets increase.
I know I've seen other AI attempts to learn AO & global illumination, just googling a bit:
Ray traced games might still have over-darkening though, at least initially. A lot of ray tracing code I’m seeing is using very short max distances for AO rays. This helps with both tracing performance and with noise. But I think looking at too small of a local neighborhood is a big part of what’s responsible for the over-darkening the author is pointing out. To get realistic corner darkening, you really need path tracing or some other global illumination rendering.