This thesis tests several methods and measures in pathtracing for selecting either the Line Space or the Bounding Volume Hierarchy data structure to make use of the advantages of both. The structures are defined locally around each object and each Line Space shaft contains one candidate ID each. All implementation is done as a C++ and OpenGL framework with compute shaders handling the pathtracing and Line Space generation. The measures include the probability distribution, the effect dependency, as well as a distance threshold and are tested against several different scenes. In most situations, the results show a noticeable increase in performance, partly only with minor visual differences, with the probability measure producing the highest quality images for a given performance. The fundamental problems of the Line Space concering the high memory consumption and a long generation time compared to the BVH still persist, despite the object local structure, a minimal amount of data per shaft and the compute shader implementation.
This thesis presents a novel technique in computer graphics to simulate realtime
global illumination using path tracing. Path tracing is done with compute shaders on the graphics card (GPU) to perform rendering in a highly parallelized manner. To improve the overall performance of tracing rays, the Line Space is used as an acceleration data structure in different variations, resulting in better
empty space skipping. The Line Space saves scene information based on a previous voxelization in direction-dependent shafts and is generated and traversed on the GPU. With this procedure, indirect lighting and soft shadows can be computed in a physically correct way. Furthermore, using the Line Space, path tracing can be performed mostly independent of the complexity of the scene geometry with over 100 frames per second, which is truly real-time and much faster than using a comparable voxel grid. The image quality is not affected negatively by this technique and the shadow quality is in most cases much better compared to shadow-mapping.
This thesis presents two methods for the computation of global illumination. The first is an extension of Reflective Shadow Maps with an additional shadow test in order to handle occlusion. The second method is a novel, bidirectional Light-Injection approach. Rays originating from the light source are traced through the scene and stored inside the shafts of the Linespace datastructure. These shafts are a discretization of the possible spatial directions. The Linespaces are embedded in a Uniform Grid. When retrieving this pre-calculated lightning information no traversal of datastructures and no additional indirection is necessary in the best-case scenario. This reduces computation time and variance compared to Pathtracing. Areas that are mostly lit indirectly and glas profit the most from this. However, the result is only approximative in nature and produces visible artifacts.
The following thesis analyses the functionality and programming capabilitiesrnof compute shaders. For this purpose, chapter 2 gives an introductionrnto compute shaders by showing how they work and how they can be programmed. In addition, the interaction of compute shaders and OpenGL 4.3 is shown through two introductory examples. Chapter 3 describes an NBodyrnsimulation that has been implemented in order to show the computational power of compute shaders and the use of shared memory. Then it is shown in chapter 4 how compute shaders can be used for physical simulationsrnand where problems may arise. In chapter 5 a specially conceived and implemented algorithm for detecting lines in images is described and then compared with the Hough transform. Lastly, a final conclusion is drawn in chapter 6.