| Stochastic ray tracing is a global illumination algorithm based on the Monte Carlomethod and provides a full solution to the rendering equation. However, the renderingtime of stochastic ray tracing is so long that it can only be implemented offline ratherthan online. With the development of the general-purpose computing technique ofgraphics processors, and especially of the OpenCL parallel computing technique, itbecomes possible to accelerate the rendering process of the stochastic ray tracing withhelps of the general-purpose computing technique.This paper presents a novel contents as listed below after deep researches in thestochastic ray tracing, the Monte Carlo method and the OpenCL parallel computingtechnique.1) Presents an object modeling method, which simulates object geometry attribute byindex-array triangle mesh, simulates object material attribute and lighting attributeby bidirectional scattering distribution function and emission distribution functionbased on a local coordinate system, and organizes those attributes into a “threelevel abstraction†data structure.2) Presents a ray beam-scene intersection method, which gives CPU serial, CPUparallel, and OpenCL parallel implementations.3) Presents a “two component division†method and “three steps computing†methodfor illumination estimators such as direct illumination estimator and indirectillumination estimator. This “two component division†method divides theillumination estimators into intersection-related component and intersection- unrelated component. This “three steps computing†method partitions illuminationestimators computing into three phases, namely preparation phase, intersectionphase and completion phase. Especially, the computing of the intersection-relatedcomponent asks the ray beam-scene intersection for help and the formulation ofprobability distribution function in the intersection-unrelated component asks theimportance sampling method for reference.By combination both the contents as described above and the object-orientedprogramming methodology, this paper designs and implements a stochastic ray tracersystem. This system utilizes the multi-thread rendering based on OpenCL parallel raybeam-scene intersection whose execution time decreases over80%compared to thesingle-thread rendering based on CPU serial ray beam-scene intersection. |