1 / 58

Solid Modeling

This guide explores Constructive Solid Geometry (CSG) techniques like Union, Subtraction, and Intersection operations, Octrees, Boundary Representations, Ray Tracing CSG Trees, and more. Learn to combine simple primitives intuitively and calculate volume efficiently using Monte Carlo methods. Understand the advantages and disadvantages of CSG trees and octrees in solid modeling. Dive into the details of Boundary Representations and Implicit Representations for shaping complex structures.

ptroxel
Download Presentation

Solid Modeling

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. Solid Modeling Dr. Scott Schaefer

  2. Solid Modeling Representations • Constructive Solid Geometry • Octrees • Boundary Representations • Implicit Representations

  3. Constructive Solid Geometry • Combine simple primitives together using set operations • Union, subtraction, intersection • Intuitive operations for building more complex shapes

  4. Constructive Solid Geometry • Combine simple primitives together using set operations • Union, subtraction, intersection • Intuitive operations for building more complex shapes Image taken from “Feature-Sensitive Subdivision and Isosurface Reconstruction”

  5. Constructive Solid Geometry • Typically represented as binary tree • Leaves store solids (sphere, cylinder, …) • Interior nodes are operations (union, subtraction, …) or transformations union subtraction rotation cylinder sphere cylinder

  6. Ray Tracing CSG Trees • Assume we have a ray R and a CSG tree T • If T is a solid, • compute all intersections of R with T • return parameter values and normals • If T is a transformation • apply inverse transformation to R and recur • apply inverse transpose of transformation to normals • return parameter values • Otherwise T is a boolean operation • recur on two children to obtain two sets of intervals • apply operation in T to intervals • return parameter values. • Display closest intersection point

  7. Inside/Outside Test for CSG Trees • Given a point p and a tree T, determine if p is inside/outside the solid defined by T • If T is a solid • Determine if p is inside T and return • If T is a transformation • Apply the inverse transformation to p and recur • Otherwise T is a boolean operation • Recur to determine inside/outside of left/right children • If T is Union • If either child is inside, return inside, else outside • If T is Intersection • If both children are inside, return inside, else outside • If T is Subtraction • If p is inside left child and outside right child, return inside, else outside

  8. Application: Computing Volume • Monte Carlo method • Put bounding box around object • Pick n random points inside the box • Determine if each point is inside/outside the CSG Tree • Volume

  9. Octrees • Models space as a tree with 8 children • Nodes can be 3 types • Interior Nodes • Solid • Empty

  10. Octrees • Models space as a tree with 8 children • Nodes can be 3 types • Interior Nodes • Solid • Empty

  11. Building Octrees • If cube completely inside, return solid node • If cube completely outside, return empty node • Otherwise recur until maximum depth reached

  12. Octrees • Advantages • Storage space proportional to surface area • Inside/Outside trivial • Volume trivial • CSG relatively simple • Can approximate any shape • Disadvantages • Blocky appearance

  13. Octrees • Advantages • Storage space proportional to surface area • Inside/Outside trivial • Volume trivial • CSG relatively simple • Can approximate any shape • Disadvantages • Blocky appearance

  14. Boundary Representations • Stores the boundary of a solid • Geometry: vertex locations • Topology: connectivity information • Vertices • Edges • Faces

  15. Boundary Representations • Constant time adjacency information • For each vertex, • Find edges/faces touching vertex • For each edge, • Find vertices/faces touching edge • For each face, • Find vertices/edges touching face

  16. Half Edge Data Structure face

  17. Half Edge Data Structure HalfEdge { HalfEdge next, prev, flip; Face face; Vertex origin; Edge edge; } Face { HalfEdge edge; // part of this face } face Vertex { HalfEdge edge; // points away } Edge { HalfEdge he; }

  18. Half Edge Data Structure • Given a face, find all vertices touching that face • Given a vertex, find all edge-adjacent vertices • Given a face, find all adjacent faces face

  19. Building a Topological Data Structure • Must connect adjacent edges/faces/vertices • Edges are critical in most data structures • Use a hash table indexed by two vertices face

  20. Boundary Representations • Advantages • Explicitly stores neighbor information • Easy to render • Easy to calculate volume • Nice looking surface • Disadvantages • CSG very difficult • Inside/Outside test hard

  21. Implicit Representations of Shape • Shape described by solution to f(x)=c

  22. Implicit Representations of Shape • Shape described by solution to f(x)=c

  23. - - - - - - - - Implicit Representations of Shape • Shape described by solution to f(x)=c

  24. - - - - - - - - Implicit Representations of Shape • Shape described by solution to f(x)=c + + + + + + + +

  25. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations

  26. - - - - - - - - Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations + + + + + + + +

  27. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations

  28. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations • Union

  29. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations • Union

  30. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations • Union + + - - + - + - - + +

  31. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations • Union + + - - + - + - - + +

  32. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations • Union + + - - + + - + + - - - - + + - + + - - + +

  33. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations • Union + - - - - + - + - - - - - - - - - - + + +

  34. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations • Union • Intersection + + - - + + - + + - - - - + + - + + - - + +

  35. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations • Union • Intersection + + - - + +

  36. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations • Union • Intersection • Subtraction + + - - + + - + + - - - - + + - + + - - + +

  37. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations • Union • Intersection • Subtraction - - + - + + + - + - - + + + + - + - - - + +

  38. Advantages • No topology to maintain • Always defines a closed surface! • Inside/Outside test • CSG operations • Union • Intersection • Subtraction + - + + - - + +

  39. Disadvantages • Hard to render - no polygons • Creating polygons amounts to root finding • Arbitrary shapes hard to represent as a function

  40. Non-Analytic Implicit Functions • Sample functions over grids

  41. Non-Analytic Implicit Functions • Sample functions over grids

  42. Data Sources

  43. Data Sources

  44. Data Sources

  45. Data Sources

  46. Data Sources

  47. Data Sources

  48. 2D Polygon Generation

  49. 2D Polygon Generation

  50. 2D Polygon Generation

More Related