1 2 surface representation data structures
play

1.2 Surface Representation & Data Structures Hao Li - PowerPoint PPT Presentation

Spring 2015 CSCI 599: Digital Geometry Processing 1.2 Surface Representation & Data Structures Hao Li http://cs599.hao-li.com 1 Administrative No class next Tuesday, due to Siggraph deadline Introduction to first programming


  1. Spring 2015 CSCI 599: Digital Geometry Processing 1.2 Surface Representation � & Data Structures Hao Li http://cs599.hao-li.com 1

  2. Administrative • No class next Tuesday, due to Siggraph deadline � • Introduction to first programming exercise next Thursday Siggraph Deadline 2013@ILM, Ewww! 2

  3. After Siggraph Deadline @ILM 3

  4. Last Time Geometry Processing Reconstruction Rendering Capture Analysis Reproduction Manipulation 4

  5. Geometric Representations point based quad mesh triangle mesh implicit surfaces / particles volumetric tetrahedrons 5

  6. Geometric Representations point based quad mesh triangle mesh Surface Representations implicit surfaces / particles volumetric tetrahedrons 6

  7. High Resolution 7

  8. Large scenes 8

  9. Outline • Parametric Approximations • Polygonal Meshes • Data Structures 9

  10. Parametric Representation Surface is the range of a function f : Ω ⊂ IR 2 → IR 3 , S Ω = f ( Ω ) 2D example: A Circle f : [0 , 2 π ] → IR 2 � ⇥ r cos( t ) r f ( t ) = r sin( t ) 10

  11. Parametric Representation Surface is the range of a function f : Ω ⊂ IR 2 → IR 3 , S Ω = f ( Ω ) 2D example: Island coast line f : [0 , 2 π ] → IR 2 � ⇥ ? r cos( t ) f ( t ) = r sin( t ) ? 11

  12. Piecewise Approximation Surface is the range of a function f : Ω ⊂ IR 2 → IR 3 , S Ω = f ( Ω ) 2D example: Island coast line f : [0 , 2 π ] → IR 2 � ⇥ ? r cos( t ) f ( t ) = r sin( t ) ? 12

  13. Polynomial Approximation Polynomials are computable functions p p c i t i = � � f ( t ) = c i φ i ( t ) ˜ i =0 i =0 Taylor expansion up to degree p p 1 i ! g ( i ) (0) h i + O ⇤ h p +1 ⇥ � g ( h ) = i =0 Error for approximation by polynomial f g f ( t i ) = g ( t i ) , 0 ≤ t 0 < · · · < t p ≤ h p 1 � h ( p +1) ⇥ ⇤ ( p + 1)! max f ( p +1) | f ( t ) − g ( t ) | ≤ ( t − t i ) = O i =0 13

  14. Polynomial Approximation Approximation error is O ( h p +1 ) Improve approximation quality by � • increasing … higher order polynomials p • decreasing … shorter / more segments h Issues � f ( p +1) ( t ) max • smoothness of the target data ( ) t • smothness condition between segments 14

  15. Polygonal Meshes Polygonal meshes are a good compromise � • Piecewise linear approximation → error is O ( h 2 ) 3 6 12 24 25% 6.5% 1.7% 0.4% 15

  16. Polygonal Meshes Polygonal meshes are a good compromise � O ( h 2 ) • Piecewise linear approximation → error is • Error inversely proportional to #faces 16

  17. Polygonal Meshes Polygonal meshes are a good compromise � O ( h 2 ) • Piecewise linear approximation → error is • Error inversely proportional to #faces • Arbitrary topology surfaces 17

  18. Polygonal Meshes Polygonal meshes are a good compromise � O ( h 2 ) • Piecewise linear approximation → error is • Error inversely proportional to #faces • Arbitrary topology surfaces • Piecewise smooth surfaces 18

  19. Polygonal Meshes Polygonal meshes are a good compromise � O ( h 2 ) • Piecewise linear approximation → error is • Error inversely proportional to #faces • Arbitrary topology surfaces • Piecewise smooth surfaces • Adaptive sampling 19

  20. Polygonal Meshes Polygonal meshes are a good compromise � O ( h 2 ) • Piecewise linear approximation → error is • Error inversely proportional to #faces • Arbitrary topology surfaces • Piecewise smooth surfaces • Adaptive sampling • Efficient GPU-based rendering/processing 20

  21. Outline • Parametric Approximations • Polygonal Meshes • Data Structures 21

  22. Graph Definitions B A • Graph { V , E } E F D C I H G K J 22

  23. Graph Definitions B A • Graph { V , E } E F • Vertices V = {A,B,C,…,K} D C I H G K J 23

  24. Graph Definitions B A • Graph { V , E } E F • Vertices V = {A,B,C,…,K} D C • Edges E = {(AB),(AE),(CD),…} I H G K J 24

  25. Graph Definitions B A • Graph { V , E } E F • Vertices V = {A,B,C,…,K} D C • Edges E = {(AB),(AE),(CD),…} I H • Faces F = {(ABE),(EBF),(EFIH),…} G K J 25

  26. Graph Definitions B A Vertex degree or valence: � E F D number of incident edges � C • deg(A) = 4 I H • deg(E) = 5 G K J 26

  27. Connectivity Connected: � B Path of edges connecting A every two vertices E F D C I H G K J 27

  28. Connectivity Connected: � Path of edges connecting B A every two vertices E � F D Subgraph: � C Graph { V’,E’ } is a subgraph of graph I H { V,E } if V’ is a subset of V and E’ is a G subset of E incident on V’ . K J 28

  29. Connectivity Connected: � Path of edges connecting B A every two vertices E � F D Subgraph: � C Graph { V’,E’ } is a subgraph of graph I H { V,E } if V’ is a subset of V and E’ is a G subset of E incident on V’ . K J 29

  30. Connectivity Connected: � Path of edges connecting B A every two vertices E � F D Subgraph: � C Graph { V’,E’ } is a subgraph of graph I H { V,E } if V’ is a subset of V and E’ is a G subset of E incident on V’ . � K J Connected Components: � Maximally connected subgraph 30

  31. Connectivity Connected: � Path of edges connecting B A every two vertices E � F D Subgraph: � C Graph { V’,E’ } is a subgraph of graph I H { V,E } if V’ is a subset of V and E’ is a G subset of E incident on V’ . � K J Connected Components: � Maximally connected subgraph 31

  32. Graph Embedding R d Embedding: Graph is embedded in , if R d each vertex is assigned a position in . R 2 R 3 Embedding in Embedding in 32

  33. Graph Embedding R d Embedding: Graph is embedded in , if R d each vertex is assigned a position in . Embedding in R 3 33

  34. Planar Graph Planar Graph � Graph whose vertices and edges can be R 2 embedded in such that its edges do not intersect Straight Line � Planar Graph Plane Graph Plane Graph 34

  35. Triangulation Triangulation: � Straight line plane graph where every B A face is a triangle E F D Why? � C • simple homogenous data structure I H • efficient rendering G • simplifies algorithms • by definition, triangle is planar K J • any polygon can be triangulated 35

  36. Mesh • Mesh : straight-line graph R 3 embedded in • Boundary edge: adjacent to exactly 1 face • Regular edge: adjacent to exactly 2 faces • Singular edge: adjacent to more than 2 faces • Closed mesh: mesh with no boundary edges 36

  37. Polygon Q = ( V, E ) A geometric graph R d d ≥ 2 V = { p 0 , p 1 , . . . , p n − 1 } with in , E = { ( p 0 , p 1 ) . . . ( p n − 2 , p n − 1 ) } and is called a polygon � � � � A polygon is called • flat, if all edges are on a plane • closed, if p 0 = p n − 1 37

  38. While digital artists call it Wireframe, … 38

  39. Polygonal Mesh A set of finite number of closed polygons if: � Q i M • Intersection of inner polygonal areas is empty p ∈ P • Intersection of 2 polygons from is either empty, a point M e ∈ E or an edge • Every edge belongs to at least one polygon e ∈ E • The set of all edges which belong only to one polygon are called edges of the polygonal mesh and are either empty or form a single closed polygon 39

  40. Polygonal Mesh Notation M = ( { v i } , { e j } , { f k } ) v i ∈ R 3 geometry 40

  41. Polygonal Mesh Notation M = ( { v i } , { e j } , { f k } ) v i ∈ R 3 geometry e i , f i ⊂ R 3 topology 41

  42. Global Topology: Genus • Genus: Maximal number of closed simple cutting curves that do not disconnect the graph into multiple components. • Or half the maximal number of closed paths that do no disconnect the mesh • Informally, the number of holes or handles Genus 0 Genus 1 Genus 2 Genus 3 42

  43. Euler Poincaré Formula • For a closed polygonal mesh of genus , the relation g of the number of vertices, of edges, and of faces V E F is given by Euler’s formula: � � � V − E + F = 2(1 − g ) � � • The term is called the Euler characteristic 2(1 − g ) χ 43

  44. Euler Poincaré Formula V − E + F = 2(1 − g ) 4 − 6 + 4 = 2(1 − 0) 44

  45. Euler Poincaré Formula V − E + F = 2(1 − g ) 16 − 32 + 16 = 2(1 − 1) 45

  46. Average Valence of Closed Triangle Mesh Theorem: Average vertex degree in a closed manifold triangle mesh is ~6 Proof: Each face has 3 edges and each edge is counted twice: 3F = 2E � � by Euler’s formula: V+F-E = V+2E/3-E = 2-2g � Thus E = 3(V-2+2g) � � So average degree = 2E/V = 6(V-2+2g) ~6 for large V 46

  47. Euler Consequences Triangle mesh statistics � • F ≈ 2 V E ≈ 3 V • • Average valence = 6 Quad mesh statistics � • F ≈ V • E ≈ 2 V • Average valence = 4 47

  48. Euler Characteristic Sphere Torus Moebius Strip Klein Bottle χ = 2 χ = 0 χ = 0 χ = 0 48

  49. How many pentagons? 49

  50. How many pentagons? Any closed surface of genus 0 consisting only of hexagons and pentagons and where every vertex has valence 3 must have exactly 12 pentagons 50

Recommend


More recommend