Download presentation
Presentation is loading. Please wait.
1
Adaptively Sampled Distance Fields (ADFs) A General Representation of Shape for Computer Graphics S. Frisken, R. Perry, A. Rockwood, T. Jones Richard Keiser
2
2 Contents u Introduction l What are ADFs u Motivation l Why is it a hard problem u Idea and Methods l Distance fields l Octree-based ADFs l Algorithms l Applications u Results u Personal statement
3
3 Introduction... or what it‘s all about
4
4 What are ADFs ? u A unifying data structure l Represents shapes u More than just the 3D geometry of physical objects u Shape can have arbitrary dimension and be derived from simulated or measured data. l Represents sharp edges, organic surfaces, semi-transparent substances l Can store auxiliary data in cells l Fundamental graphical data structure
5
5 Carving of Fine Detail
6
6 Artistic Carving of Fine Detail
7
7 Rendering Volume Data u Example : Cocaine molecule volume rendered in a haze of turbulent mist l Color function of mist is based on the distance from the molecule surface l Modulated by a noise function
8
8 Shape Representations u Parametric surfaces l Polygons, spline patches, trimmed NURBs l Need associated data structures (B-reps) l Do not represent object interiors or exteriors u Subdivision surfaces l The same disadvantages as parametric surfaces u Implicit surfaces l Defined by an implicit function f(x) = c l Distinguish between interior and exterior l Difficult to define for an arbitrary object
9
9 Motivation... or why it‘s worth listening
10
10 Why is it a Hard Problem ? u Resolution limited by the sampling rate u Large volume size (memory) u Efficiency u Interpolation of the normals of surface points from the sampled data l Expensive and with limited accuracy This limitations and problems are addressed by ADFs
11
11 Advantages of ADFs u Representing a broad class of forms u Efficient rendering u Efficient and easy use of operations l Locating surface points, performing inside/outside and proximity tests, Boolean operations, blending, closest points,... u Adaptive sampling -> accuracy u Efficient memory usage
12
12 Idea and Methods... or how it works
13
13 Distance Fields u Scalar field that specifies the minimum distance to a shape u At each sample point, store the signed distance to the nearest surface point u Sign indicates inside vs. outside u This sampled distance field is a distance map u Effective representation of shape
14
14 Examples u Unit sphere S in R 3 l Euclidean signed distance from S : h(x) = 1 - (x 2 +y 2 +z 2 ) 1/2 l Algebraic signed distance from S : h(x) = 1 - (x 2 +y 2 +z 2 ) z P1 h < 0 P2 h > 0 r=1 x y
15
15 Examples u Implicit form of an object u Euclidean dist. to a parametric surface distance field computed for a 32 bicubic Bezier patch of the Utah Teapot Determined by solving the 7th order Bezier equations using the Bezier clipping algorithm
16
16 Distance Maps u Vary smoothly across surfaces u Are defined throughout space u Can be reconstructed as the zero-value iso-surface of the distance map u Can locally estimate the surface normal by the gradient of the distance map
17
17 Gradient Vectors The distance field varies smoothly across the edge The gradient of the distance field accurately estimates the edge normal
18
18 Regularly vs. Adaptiv u Regularly sampled distance fields l Large volume size because fine detail requires dense sampling u Adaptively sampled distance fields l Use adaptive, detail-directed sampling u High sampling rates in regions containing fine detail l Store the sampled data in a hierarchy for fast localization
19
19 Octree-based ADFs u One possibility for a hierarchy in 3D u Demonstrate the concepts in 2D (with quadtrees) u Quadtree cell l Contains the sampled distance values of the cell‘s 4 corners l Pointers to parent and child cells
20
20 Example of a Quadtree c0c0 c2c2 c 10 c 11 c 30 c 32 c 33 c 31 c0c0 c2c2 c 32 c 11 c 33 c 31 c 30 c 12 NE NWSE SW c 12 c 13 c 10 c 13
21
21 3-color Quadtree vs. ADFs u 3-color quadtree l 3 types of cells: interior, exterior, boundary l Subdivide all boundary cells to a predetermined highest resolution level u ADFs quadtree l Subdivision of boundary cells depends on the distance field u Subdivide only when the distance field within a cell is not well approximated by bilinear interpolation of its corner values
22
22 3-color Quadtree vs. ADFs 3-color quadtreeADFs quadtree 1‘713 cells23‘573 cells
23
23 2D Spatial Data Structure u Wavelet
24
24 Generating ADFs u Function to produce the distance function, h(x) l Continuity, differentiablility and bounded growth advantageous, but not necessary u Many ways to generate an ADFs l E.g. bottom-up approach l E.g. top-down approach
25
25 Bottom-up Algorithm u Start with a regularly sampled distance field of finite resolution u Construct a fully populated octree (3D) u Repeat (start with the smallest cells) l Coalesce a group of 8 neighbour cells iff u None of the cells has any child cells u sampled distances of all 8 cells reconstructed from the sample values of their parent l Next level Until no cells are coalesced
26
26 Example Buttom-up
27
27 Example Buttom-up
28
28 Example Buttom-up
29
29 Top-down Algorithm u Compute the distance values for the root node u Subdivide ADFs cells recursively according to a subdivision rule l e.g. for representing the iso-surface stop if u the cell is guaranteed to not contain the surface u a specified maximum level is reached u the cell contains the surface but can be interpolated to a specified error tolerance
30
30 Top-down Generation Recursively subdivideInitialize root cell
31
31 Reconstructing ADFs u Distance values within a cell are reconstructed from the stored 8 corner distance values using trilinear interpolation u Surface normal is equal to the normalized gradient of the distance field
32
32 Application: Ray Casting u Determine surface points l Intersection between a ray and the zero- value iso-surface of the ADFs u Linear approximation
33
33 Application: Ray Casting u Determine the distance values where the ray enters and exits the cell u Compute the crossing if the two values have different signs
34
34 Application: Level of Detail u Truncate the ADF-octree at fixed levels: l During rendering, generation, or to an existing high resolution l Can be used for progressive representation u Truncate cells with little errors l Error stored during top-down generation l Consistent degradation for both smooth and highly curved portions of the surface l Can be used for local refinement
35
35 Application: Level of Detail Four LOD models with varying amounts of error rendered from an ADFs octree
36
36 Application: Collisions u Collision avoidance in robotics l Using distance fields u Penetration forces in haptics u Accelerate collision detection l Using octrees l LOD
37
37 Results...or what we have reached
38
38 Conclusions u Adaptively sampling of the distance field l Efficient use of memory l High frequency components are reconstructed accurately u Storing sampled values in a spatial hierarchy l Efficient reconstruction/localization
39
39 Triangles vs. ADFs ADF Sample Count ADF Cell Count Triangle Count Error Tolerance 6.25E-5 3.13E-5 1.56E-5 32‘768 131‘072 2‘097‘152 16‘201 44‘681 131‘913 24‘809 67‘405 165‘847 Comparison of triangle count for a sphere (r=0.4) to ADF size
40
40 Conclusions u Distance fields embody considerable information about a shape l Inside vs. outside, gradient and proximity information l Operations on a shape often achieved by operations on its distance field -> more efficient
41
41 Conclusions u Separate generation of shapes l Preprocessing : complex and time- consuming methods l Runtime : fast graphical operations u Complex shapes can be processed as quickly as much simpler shapes l Fractals, mathematically sophisticated or carved shapes
42
42 Conclusions u ADFs integrate numerous concepts in computer graphics l Representation of geometry and volume data l Broad range of processing operations such as rendering, carving, LOD management, surface offsetting, and proximity testing
43
43 Conclusion u 2D editing with boolean difference
44
44 Personal Statement...or the paper under my loup
45
45 Last Thoughts u ADFs combine known concepts u Advantages l Distance fields -> flexibility l Octrees -> fast location l Adaptation -> accuracy, memory efficiency
46
46 Last Thoughts u Disadvantages l Finding a distance function can be difficult l Bottom-up algorithm requires excessive amount of memory l Top-down algorithm performs expensive octree neighbour searches u Main application area l Complex shapes, shapes with fine details
47
47 Last Thoughts u Convincing pictures and comparisons u Idea of ADFs and implementation rather easy u Many advantages u Useful for many fundamental graphical operations Ô propose ADFs as a fundamental graphical data structure
48
48 The End...or are there any questions ?
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.