Home ~ Back to cs6650 ~ Back to Code Pit ~ Class Web Site
Create an image of the Cornell Box using photon mapping.
Well, I decided that I would Russian-roulette for photon propagation. The results from two different values for the probability follow. Notice the one using the average value produces images with bright spots. This is due to some photons becoming super-charged when they survive Russian-roulette. It takes a crazy number of photons to average out these guys. These two images were made using 100 samples per pixel for soft shadows and anit-aliasing, as well as 4,500,000 photons emitted from the light, 5,000,000 total photons in the photon map using an estimate of photon density with 1500 photons and a max distance of the search of 30. I also used ray tracing to compute the direct light, and the photon map to compute the indirect light.
![]() |
![]() |
| Ugly jpeg | Ugly jpeg |
| With probability of propagating photon as the average of the colors on the surface. | With probability of propagating photon as the max of the colors on the surface. |
When you are rendering using density estimation you are fighting a battle between two forces. Lumpy with features, or smooth and blurry. You can simulate the indirect light quick quicky with only a few photons in the map and a large percentile in the estimate.
This image was rendered with 50,000 photons in the map, and an estimate of 500 photons within a distance of 150cm. There is only 1 sample per pixel, just to give an idea of the indirect lighting contribution.

Notice how many of the finer features are missing, but you still get a resonable estimate.
Here's an example of when you either didn't use enough photons in you estimate or too many photons in your photon map. When you get results like this, Jensen suggests using more photons in you estimate. However, in order to overcome the problem of blurriness, you need more photons overall.
One sample per pixel. 500,000 photons, 500 used in estimate, max
distance was 150.

Ugly
jpeg