190 likes | 303 Views
TecGraf. Ray Path Categorization. Diego Nehab and Marcelo Gattass {diego,gattass}@tecgraf.puc-rio.br. PUC-Rio. About this work. 1996 “Introduction to Computer Graphics” final project Adaptive antialiasing for simple scenes to impress the professor Adaptive progressive image refinement
E N D
TecGraf Ray Path Categorization Diego Nehab and Marcelo Gattass {diego,gattass}@tecgraf.puc-rio.br PUC-Rio
About this work • 1996 “Introduction to Computer Graphics” final project • Adaptive antialiasing for simple scenes to impress the professor • Adaptive progressive image refinement • Use scene geometry, instead of computed pixel colors • SIBGRAPI’96 published an image created by the program • A new implementation was created for this paper
Input: Scene description Camera position Lighting equation Projection plane Output Image as seen by the camera 1-Slide Introduction
Describing Rays • From the illumination equation, the path followed by a ray can be described by: • The object the ray hits • The light sources that are visible at the intersection points • The reflection child ray • The refraction child ray • We want to partition rays into equivalence classes, each class being called a category
Each intersection of a ray with an object is a tree node Left and right subtrees represent refraction and reflection child rays Intersections are annotated with object lable and light source visibility Each pixel starts one ray Each ray starts reflection and refraction child rays at intersections Light source visibility is computed Rays as trees
Ray path categorization • Two rays have the same category if their trees are equal • Each tree describes all geometric information considered by one pixel • Pixels with the same category define regions with similar geometry • Categories segment the image and can be used to detect geometric edges
Ids are distinct prime numbers Category is the product of all ids in ray tree Original implementation Product commutativity ignores order Ocasional errors Primes product
Objects have distinct ids Category is a string with all ids in tree, depth-first ordered Transpose trees fall in the same category ABLC Rare errors String method
Objects have distinct ids Category is a string with ids found in the tree, along with their positions in tree Transposes hash to different categories 4A2BL1C and 7A3BL1C Binary heap
Adjacent pixels with different trees correspond to discontinuities in the image Each pixel has its category compared with those of its 4-neighbors If any difference is found, the pixel is marked as an edge pixel Detecting Edges
Detected edges include: Boundaries Reflection Shadows Reflection
Edges created by refractive objects are also captured Refraction
Set operations can also be handled Intersections should report the id of the primitive object hit Constructive Solid Geometry
Light visibility information is also optional Levels of Detail • Choosing the depth up to which categories are tracked one can control the kind of edges that are detected
Generated edges can be used to understand what goes on with refraction “Seeing” Refraction
Methods were created to analyse ray paths and classify them into similar categories This geometric information was used to segment the rendered scene The segmentation was used to generate geometric edges Edges were used to create linearts, study geometric properties and to perform adaptive antialiasing Conclusions
Design other forms of edge visualization, showing edge types Improve category information to consider depth cues and texture information Use precomputed category information to speed ray tracing and compress image storage Future works
Questions? Questions? Questions? Questions? Questions? Questions? Questions? Questions? Questions? Questions? Questions? Questions? Questions? Questions? Questions?