nvpro-samples / vk_raytracing_tutorial_KHR

Ray tracing examples and tutorials using VK_KHR_ray_tracing
Apache License 2.0
1.36k stars 143 forks source link

[question] why is the output of ray_tracing_gltf so noisy #13

Closed Adi146 closed 3 years ago

Adi146 commented 3 years ago

Hi, one quick questsion. If I run the binary of the ray_tracing_gltf, I get a pretty noisy output. If I understand it correctly it is normal to get a noisy Image with realtime raytracing. But why isn't the output of the other tutorials also noisy?

mklefrancois commented 3 years ago

The scene used in this example has only one area light (emissive material) in an half closed environment. This make it harder to resolve compare to an open space environment with a "real" single point light. In the other scenes, we were shooting a ray toward that light, in the glTF a random ray hits the emissive material. To make it less noisy, we would have to do importance sampling and other advance techniques.

This sample https://github.com/nvpro-samples/vk_raytrace is using importance sampling with an HDR image. It is still noisy at the first frames, but resolves quickly.