1 / 1

Final Gathering on GPU

Layer 0. Layer 1. Layer 2. Layer 3. Far. Near. Cornell Box. Buddha. Teapot. Global ray direction. Each sampling points takes nearest depth layer. Global ray direction. Photon Map (first pass solution) is directly visualized by radiance estimation.

adonica
Download Presentation

Final Gathering on GPU

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Layer 0 Layer 1 Layer 2 Layer 3 Far Near Cornell Box Buddha Teapot Global ray direction Each sampling points takes nearest depth layer Global ray direction Photon Map (first pass solution) is directly visualized by radiance estimation Photon Map (first pass solution) is indirectly used by Final Gathering (second pass) Sampling point Global illumination test Stanford’s Set of rays in original Final Gathering Set of rays in proposed method Final Gathering on GPU Demo application is available at http://www.bee-www.com/parthenon/ Toshiya Hachisuka (toshiya@bee-www.com) The University of Tokyo Introduction However, Final Gathering typically needs thousands of samplings to achieve noiseless result. For this reason, Final Gathering casts many more rays compared to other rendering process (i.e. photon tracing) using ray-casting and it often becomes a bottleneck of all rendering process. Irradiance Cache applies Final Gathering to sparsely sampled pixels and interpolates this data to produce entire illumination data. Irradiance Cache can greatly reduce number of sampling rays, but its parameter is not intuitive (e.g. a maximum valid distance : current cache points can be used for interpolation within this distance), so it is difficult to control rendering time and the error due to interpolation. Proposed method uses inverse of Depth Peeling which stacks each depth layer, whereas original process strips away each depth layer. Sampling point along ray direction on depth layer is projected to screen space pixel during successive pass. If sampling point on depth layer is behind a ray origin, it is culled by a KILL operation. Since common graphics hardware is based on Z buffer algorithm, parallel projection in Depth Peeling is straightforward process and it can be computed quite efficiently. Although Ray tracing on GPU can be used to cast these rays, its performance is not sufficient for per-pixel Final Gathering. Producing global illumination image without any noise is still difficult because it requires a large number of samplings. Some approaches, such as Photon Mapping [Jensen 1996], can render noiseless image but often results in biased image. To produce highquality image, most of current global illumination renderer uses additional process called “Final Gathering”. Final Gathering uses rough global illumination solution such as Photon Map or Radiosity, and gathers this data by casting rays to obtain definitive incident radiance distribution. Since Final Gathering requires a large number of rays for producing noise-free result, it is very costly to process all visible pixels. Irradiance Gradients [Wald and Heckbert 1992] can reduce number of processing pixels by interpolation, but its behavior is difficult to control. Instead of reducing number of processing pixels by interpolation, I propose an accelerated method of the process itself by using a common graphics hardware. Two-Pass Method Most of existing global illumination renderer implements two-pass method. The first pass is making rough global illumination data, and the second pass is actual rendering using this solution. Rough global illumination solution can be obtained by any method that can solve some part (or all) of rendering equation. One of popular and robust method for this first pass is Photon Mapping. Since the resulting data of a first pass itself is complete global illumination solution, one can render a image by directly visualizing this data. However, first pass result is only approximated solution and its quality is not sufficient for a final image, so second pass is usually applied by using first pass result indirectly. Whereas first pass result can be used as a approximated probability density function for Path-tracing, the most popular second pass process is separated indirect illumination computation by Final Gathering. Successive Pass Inverse process of Depth Peeling Theoretical ray number of typical scenes Result Note that Final Gathering process casts many more number of rays compared to other process. I implemented global illumination renderer using the proposed method using DirectX 9.0 on WindowsXP. These images were rendered by this program on Pentium4 2.8GHz and Radeon 9700 Pro (Video memory is 128MB). Note that in spite of processing all pixels, rendering time is still in practical range. Proposed Method Proposed method uses a randomly sampled global ray direction and regards ray-casting as a multiple parallel projection. By choosing global ray direction, many sampling rays of Final Gathering can be viewed as a number of sets of rays with same direction and different origin. Rather than using ray casting, using parallel projection is suitable for a common graphics hardware based on Z buffering algorithm. Multiple parallel projections are effectively done by Depth Peeling using programmable shader. Since proposed method simply samples all visible points, it doesn't have non-intuitive parameters like Irradiance Cache. Current performance of proposed method is comparable to efficient implementation of Final Gathering with Irradiance Cache on CPU. However, by considering growing speed of GPU, this method has potential to outperform the CPU based methods. Performance of sample application using proposed method Note that the object in directly visualized image seems like floating from floor due to insufficient accuracy of global illumination solution in Photon Map. Conceptual diagram of proposed method Final Gathering Final Gathering can be done by iterate this process for random global ray direction. Conclusion Ray Cast by Parallel Projection To get N times reflected illumination, Final Gathering gathers illumination data which is N-1 times reflected illumination and generates Nth reflected illumination. Final Gathering process is essentially the same for casting a large number rays on upper hemisphere of visible points. It can produce high quality result form rough first pass illumination data by reusing this solution all over the visible pixels. Final Gathering can be effectively done by using multiple parallel projection on GPU. Visual quality is nearly equivalent of per-pixel Final Gathering by ray casing. Current performance is comparable to interpolation method (e.g. Irradiance Cache) but it doesn’t have non-intuitive parameters like maximum distance of Irradiance Cache. Since proposed method is per-pixel method, it can be used to deal with any set of points including ray-traced pixels for image rendering, vertex data for pre-computed radiance transfer, textures for light maps. Whereas original Final Gathering processes a set of rays with same origin, the proposed method uses a set of rays with same direction (i.e. global ray direction). Thinking from this viewpoint, ray casting is the same as sampling a point on the nearest depth layer from the ray origin along global ray direction. Each depth layer can be extracted by using inverse of Depth Peeling [Everitt 2001]. Reference Jensen, H. W. 1996. Global illumination using photon maps. Rendering Techniques ’96 (Proceedings of the Seventh EurographicsWorkshop on Rendering), pages 21–30. Everitt, C. 2001. Interactive order-independent transparency. Technical report, NVIDIA Corporation. Szirmay-Kalos, L. 1998. Global Ray-bundle Tracing. Technical Report/TR-186-2-98-18. Ward, G. and Heckbert, P. 1992. Irradiance gradients. Eurographics Rendering Workshop 92, 85-98. Ray distribution of Final Gathering Final Gathering casts many rays on upper hemisphere to gather the illumination data obtained by fist pass. Same color rays are in same set of rays.

More Related