Our acceleration structure was not quite complete at the time of the assignment 5 submission. However, the ray tracer now uses a kd-tree of axis-aligned bounding boxes. The performance is dramatically improved through the use of this algorithmic acceleration for complex geometries, which is enabled by running the program with the “-accel” flag.
Usage of ray tracer:
./hw5 -accel input.test
Single-thread performance: 4.55 sec for hw5 dragon at VGA
Eight-thread performance: 9.811 sec for hw5 dragon at VGA , 5x AA (782800 rays/sec)
In addition to very fast rendering times for the standard VGA-resolution images, one benefit of the acceleration is the ability to render complex geometries at higher resolutions. With 4x uniform antialiasing, XGA (1024×768) images of the Stanford dragon can be finished in reasonable times. This corresponds to rendering over 12.5 megapixels.
A further performance improvement came from selectively antialiasing pixel with an associated value of the Sobel operator above a parametrizable threshold (see https://raytracing2012.wordpress.com/edge-detection/). This drastically cuts the number of samples required for achieving the desired smoothed appearance. Dragons rendered at XGA resolution with 4x antialiasing for pixels with high Sobel operator values completed three times faster than with uniform antialiasing.