Real-time path-based surface detail

Carles Bosch, Gustavo Patow
2010 Computers & graphics  
We present a GPU algorithm to render in real-time surface detail features based on paths, such as scratches and grooves. Our method efficiently models these features using a continuous representation that is stored in two textures. The first texture is a grid that specifies the positions of the features and provides pointers to the second texture containing the paths, profiles and material information. This data is evaluated by a fragment shader on the GPU, resulting in an accurate and fast
more » ... ering of the surface detail. Such kind of detail is rendered without using additional geometry, thus considerably reducing the size of the geometry to be processed, allowing real-time computations. Intersections between features and other special cases are robustly handled by a CSG analogy. Antialiasing, non-height field features, and visibility computations are also taken into account. This method allows application of path-based features onto general surfaces just like traditional textures. Up to now, real-time visualization of surface detail has been limited to the generation and usage of geometry or sampled data structures as in bump mapping [Bli78], displacement mapping [WWT + 03], or relief mapping [POC05, Tat06], which show aliasing problems for close views and do not provide a correct solution for filtering in far-views. On the other hand, vector textures are gaining popularity [QMK08, NH08], but are limited to flat 2D representations without encoding other 3D information besides normal map perturbation techniques [PRZ05] . Visibility and occlusion issues in these representations have never been treated in the context of vector-based representations. This paper presents a feature-based per-pixel displacement mapping technique. It builds upon previous vector texture representations and per-pixel displacement mapping techniques, and makes a step forward to achieve a robust and flexible real-time vector based displacement mapping algorithm. The presented method is able to visualize geometry details like scratches, cracks, grooves and extremely sharp edged features like bricks or edges on manufactured objects. Also, our method allows accurate visualization of these path-based features in a single pass algorithm by performing a single write per pixel. Approach: In this paper, we describe a new real-time method to compute geometric detail like scratches and grooves in texture-space by using a continuous representation that is stored in two textures, without relying on additional geometry (albeit with an increase in computational cost). We use techniques derived from the usage of vector textures in the GPU to store the geometry and properties of path profiles, and evaluate them in real-time. The first texture is a grid providing pointers to the second texture which contains the feature paths, profiles and material information. A fragment shader at the GPU evaluates this data, and generates an accurate and fast rendering by using a Constructive Solid Geometry (CSG) analogy. Contributions: We show that the CSG analogy is a very flexible and powerful one, and that the method presented here allows accurate visualization of path-based features. This is done in a single pass and by performing only one write per pixel. As a consequence, we have a low-bandwidth coherent memory access, which is advantageous for many-core architectures. Also, it has efficient approximate anti-aliasing which allows the rendering of the features from close to distant views. We use two main approximate filtering techniques, called line-sampling and supersampling. Both techniques are used in combination to solve both visibility and shadowing anti-aliasing issues. Moreover, the shader can spatially adapt the number of samples needed according to the local geometric complexity. Limitations: Our path-based feature representation shares a few limitations with other vectorbased representations [NH08]. For example, it assumes a static layout of features, as a dynamic situation would require re-encoding features at each time step, which is very fast but is not capable of real-time results. Also, a feature segment can be replicated in many cells it overlaps, but in our experience there is almost no storage overhead. Also, each cell may have a different number of features, thus requiring an indirection scheme to avoid data sparseness. Our representation is limited to path-based features only, not allowing generic detail to be added. Also, we require the features and the object surface where they are applied to have low curvature.
doi:10.1016/j.cag.2010.04.001 fatcat:bz67nk2plrf3fjmv3nxpefvziq