Radiance ambient and penumbra test v1.0

Mark J. Stock

Introduction

Both ambient accuracy and penumbral smoothness are qualities that make a raytraced image appear more realistic. We tested Radiance's rpict renderer, with some specific paramters set, to determine the optimal settings to achieve smooth gradations in the ambient calculation and smooth-appearing penumbras.

Because the scenes that we are interested in are composed of large numbers of primitives, both near the observer and far away, and commonly fill up the computer's RAM (1 GB, normally), it was decided that we should set rpict's -aa (ambient accuracy) paramter to zero. This forces an ambient calculation to be made for every intersection of a view ray with a surface (with a few minor exceptions, such as mirrors).

In addition, because of the inability of simply using the -ds (direct sampling) parameter alone to create smooth penumbras (we have it set at 0.1), we also set the -dj (direct jitter) paramter rather high (0.6).

With these paramters set, we rendered a scene of a modified Sierpinski gasket with a single area light and no sky dome while varying the following parameters:

Ultimately, we decided to filter all images down to 256x256 pixels using pfilt with the -r 0.7 option and save them as PNG files. We based that smoothing radius on some of our previous work.

The rpict statement used is the following:

rpict -vp 3.6 2 1.5 -vd -3.6 -2 -1.1 -vh 25 -vv 25 -ds 0.1 -dj 0.6 -aa 0 -ab N -ad N -x N -y N scene.oct
Of additional importance is the use of rpict's default values for the following parameters:

-pj 0.67 -ps 4 -pt 0.05 -aw 0 -as 0
The perl script used to make the images in this table is called renderall.pl, and the source files are in this directory.

NOTE: The Radiance distribution was compiled with the -DMC option, which enables true Monte-Carlo sampling of specular highlights, penumbras, and the like. This causes no repeatable change in render times.

NOTE: All reported CPU times are from an Athlon XP 2000 processor in a system with 1 GB RAM.


Using -ab 1

-ad 4 -ad 16 -ad 64 -ad 256
1x final resolution
0.908s, 40971 bytes

2.943s, 38974 bytes

16.406s, 35837 bytes

47.939s, 34572 bytes
2x final resolution
3.561s, 39744 bytes

11.443s, 36973 bytes

1m3.332s, 35837 bytes

2m58.037s, 33240 bytes
3x final resolution
7.908s, 38143 bytes

25.465s, 35256 bytes

2m20.682s, 32811 bytes

6m31.549s, 32213 bytes
4x final resolution
13.988s, 36796 bytes

45.076s, 34042 bytes

4m8.195s, 31686 bytes

11m18.621s, 31136 bytes
6x final resolution
31.352s, 34701 bytes

1m41.002s, 31993 bytes

9m15.141s, 30050 bytes
8x final resolution
55.623s, 33100 bytes

2m59.893s, 30625 bytes

16m19.447s, 28839 bytes

Using -ab 2

-ad 4 -ad 16 -ad 64 -ad 256
1x final resolution
1.840s, 45050 bytes

16.354s, 42099 bytes

3m13.193s, 37102 bytes

35m9.725s, 35087 bytes
2x final resolution
7.293s, 42468 bytes

1m4.271s, 38229 bytes

12m27.719s, 34491 bytes
3x final resolution
16.371s, 39996 bytes

2m24.789s, 35744 bytes

27m36.326s, 32763 bytes
4x final resolution
28.916s, 38034 bytes

4m15.781s, 34135 bytes

48m26.859s, 31620 bytes
6x final resolution
1m5.014s, 35360 bytes

9m35.699s, 31778 bytes

108m48.000s, 29655 bytes
8x final resolution
1m55.525s, 33465 bytes

17m3.891s, 30233 bytes
12x final resolution
4m19.605s, 31083 bytes

38m14.984s, 28405 bytes
16x final resolution
7m40.945s, 29470 bytes

67m58.619s, 27108 bytes

Using -ab 3

-ad 4 -ad 16 -ad 64
1x final resolution
3.225s, 45514 bytes

37.916s, 42016 bytes

22m35.180s, 36871 bytes
2x final resolution
12.783s, 42286 bytes

2m29.344s, 38084 bytes

86m37.094s, 34316 bytes
3x final resolution
28.756s, 39643 bytes

5m35.080s, 35639 bytes

193m8.916s, 32686 bytes
4x final resolution
50.875s, 37680 bytes

9m54.410s, 34049 bytes
6x final resolution
1m54.518s, 34981 bytes

22m15.584s, 31666 bytes
8x final resolution
3m23.006s, 33016 bytes

39m33.496s, 30033 bytes

Discussion

As is readily apparent, smooth penumbras require high oversampling. Less oversampling would be required for smoother appearance of both penumbras and normal surfaces, but that would lower the overall level of detail in the image, a comprise we chose not to make.

The effect of changing the ambient bounce setting was somewhat predictable. Noticeable differences exist in the shadow regions between otherwise-equivalent images when the paramters is changed from 1 to 2. Much less difference is seen as the paramter is raised to 3, definitely not enough difference to warrant the increase in render time. This paramter was not the main focus of this test, though. It was mainly used to try to affect the influence of -ad on the images.

The effect of the -ad is surely the most interesting result from this test. At 1x resolution, obviously, the low sampling used for the -ad=4 and 16 cases causes clear speckling of the final image; while -ad 64 and -ad=256 create images with very smooth intensity gradations. Obviously, if penumbras were not called for, one would need no more than 3x oversampling and -ad of 64.

It would be important to note that the PNG file size seems to be a fairly good rating of the overall quality of the image. Any images with file sizes less than 32000 appear to be very high quality, while file sizes under 30000 appear nearly perfect. We shall use this system as a quality paramter later.

Notice that when oversampling is doubled (1x to 2x, or 3x to 6x), four times as many view rays are shot through each pixel window, making the primary contribution of ambient rays equivalent to the next level tested (-ad 4 becomes -ad 16, etc.), but the render time for these "equivalent" renderings strongly favors the one with higher oversampling and less ambient divisions! This is more evident for the cases with more ambient bounces, so let's start with one ambient bounce, and look at the numbers:

-ab 1

Oversampling -ad CPU time file size
1x 256 47.939s 34572
2x 64 1m3.332s 35837
4x 16 45.076s 34042
8x 4 55.623s 33100

As you can see, the render times are roughly equivalent, as would be expected with only one ambient bounce allowed. Additionally, the file sizes decrease slightly, most probably due to the smoother penumbral shadow.

When we look at images rendered with two ambient bounces, we should expect some differences. Whereas the first bounce should shoot an equivalent number of rays into the hemisphere, the second bounce should shoot fewer rays as -ad goes down. Theoretically, this should lead to decreased rendering times and reduced image quality.

-ab 2

Oversampling -ad CPU time file size
1x 256 35m9.725s 35087
2x 64 12m27.719s 34491
4x 16 4m15.781s 34135
8x 4 1m55.525s 33465

Instead, what we see is sublinear decrease in render times (meaning that the reduced weight of the second bounce rays allows more at -ad 64 to be ignored), and a slight increase in image quality (though, again, that could be caused by the smoother penumbras). The effect of this method is to create a system by which we can force more ambient rays per pixel at the first bounce (where their visual effect is greater), and fewer for the second bounce and beyond (where visual effect is calculable, but less important).


Conclusion

For the renderings we desire---with huge geometries, smooth penumbral shadows, and proper ambient lighting---we recommend -ab 2 to capture enough interreflection to be interesting; oversampling of 8 to 12 to smooth the penumbras, and -ad 4 or 8, whichever turns out to provide sufficient smoothness on surfaces for available rendering time.


Mark J. Stock, Aerospace Engineering, The University of Michigan

page created: 2003-08-19, last modified: 2003-08-22