edgebreaker
play

Edgebreaker Connectivity Compression for Triangle Meshes Jarek - PowerPoint PPT Presentation

Edgebreaker Connectivity Compression for Triangle Meshes Jarek Rossignac, TVCG 1999 Contribution Lossless compression for a triangle mesh, using 2 bits per triangle for simple meshes Only a slight increase for meshes with holes and


  1. Edgebreaker Connectivity Compression for Triangle Meshes Jarek Rossignac, TVCG 1999

  2. Contribution ● Lossless compression for a triangle mesh, using ≈ 2 bits per triangle for simple meshes – Only a slight increase for meshes with holes and handles ● Linear encoding size O(|T|) – Improves upon O(|T| log |T|) for many previous approaches – The constant is better than for previous approaches

  3. Basic Idea ● Destroy triangles of the mesh one-by-one, starting from the boundary and spiralling inwards ● For each destruction operation, store an opcode indicating the type of the operation – Sequence of opcodes is called “history” – Length of history == number of triangles, hence linear size encoding

  4. Edgebreaker in action C

  5. Edgebreaker in action C

  6. Edgebreaker in action R

  7. Edgebreaker in action R

  8. Edgebreaker in action R

  9. Edgebreaker in action S

  10. Edgebreaker in action L

  11. Edgebreaker in action E

  12. Edgebreaker in action L

  13. Edgebreaker in action C

  14. Edgebreaker in action R

  15. Edgebreaker in action R

  16. Edgebreaker in action C

  17. Edgebreaker in action R

  18. Edgebreaker in action R

  19. Edgebreaker in action R

  20. Edgebreaker in action E

  21. Terminology ● Simple triangle mesh – Edge-connected collection of triangles with one or zero bounding loops ● Piecewise linear surface homeomorphic to a disk or a sphere ● Hole: Interior triangles missing – Like holes in a sheet of paper ● Handle: The surface has genus > 0 – Doughnuts, teacups etc.

  22. Basics ● Simple triangle mesh T ● “Gate” g := some half-edge on bounding loop ● X := triangle incident on g, v := third vertex of X v X g

  23. Types of Triangles ● The g-X-v combo can be one of the 5 types C L E R S ● Compression scheme: remove X, store the operation (C, L, E, R or S), update the bounding loop and advance the gate

  24. Data Structures ● Mesh: (pseudo) winged-edge structure ● History H: stores CLERS opcodes ● List P: stores vertex positions ● Stack: stores “deferred” loops

  25. Operation C (central) ● v == internal vertex before the op == boundary vertex after the op ● Position of v is appended to list P

  26. Operation L (left)

  27. Operation R (right)

  28. Operation S (split) ● Two loops created. ● Push gate of one loop onto the stack and continue with the other loop

  29. Operation E (end) ● Loop shrinks to zero ● Pop the gate of the next loop to be processed from the stack

  30. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 P 10 P 3 Stack P 1 P 2 P 11 (initial) History = (null)

  31. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 P 10 P 3 P 12 C Stack P 1 P 2 P 11 (before op) History = C

  32. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 P 13 P 10 P 3 C P 12 Stack P 1 P 2 P 11 (before op) History = CC

  33. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 P 13 P 10 P 3 P 12 R Stack P 1 P 2 P 11 (before op) History = CCR

  34. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 P 13 P 10 P 3 P 12 R Stack P 1 P 2 P 11 (before op) History = CCRR

  35. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 R P 13 P 10 P 3 P 12 Stack P 1 P 2 P 11 (before op) History = CCRRR

  36. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 S g' P 13 P 10 P 3 P 12 Stack P 1 P 2 P 11 (before op) History = CCRRRS

  37. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 L P 4 g' P 13 P 10 P 3 P 12 g' Stack P 1 P 2 P 11 (before op) History = CCRRRSL

  38. Edgebreaker in action P 6 P 5 P 8 P 9 E P 7 P 4 g' P 13 P 10 P 3 P 12 g' Stack P 1 P 2 P 11 (before op) History = CCRRRSLE

  39. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 L P 13 P 10 P 3 P 12 Stack P 1 P 2 P 11 (before op) History = CCRRRSLEL

  40. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 P 14 C P 13 P 10 P 3 P 12 Stack P 1 P 2 P 11 (before op) History = CCRRRSLELC

  41. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 R P 4 P 14 P 13 P 10 P 3 P 12 Stack P 1 P 2 P 11 (before op) History = CCRRRSLELCR

  42. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 R P 4 P 14 P 13 P 10 P 3 P 12 Stack P 1 P 2 P 11 (before op) History = CCRRRSLELCRR

  43. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 P 14 C P 13 P 10 P 3 P 12 P 15 Stack P 1 P 2 P 11 (before op) History = CCRRRSLELCRRC

  44. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 P 14 R P 13 P 10 P 3 P 12 P 15 Stack P 1 P 2 P 11 (before op) History = CCRRRSLELCRRCR

  45. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 P 14 P 13 P 10 P 3 P 12 P 15 R Stack P 1 P 2 P 11 (before op) History = CCRRRSLELCRRCRR

  46. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 P 14 P 13 P 10 P 3 P 12 P 15 R Stack P 1 P 2 P 11 (before op) History = CCRRRSLELCRRCRRR

  47. Edgebreaker in action P 6 P 5 P 8 P 9 P 7 P 4 P 14 E P 13 P 10 P 3 P 12 P 15 Stack P 1 P 2 P 11 (before op) History = CCRRRSLELCRRCRRRE

  48. Crux Observations ● Different graphs have different histories. – Allows reconstruction of topology. ● There is a bijection between C operations and interior vertices of the triangulation. – Allows reconstruction of embedding.

  49. Compression ● The history H can be encoded as follows: – Write 0 for C – Write 100 for S – Write 101 for R – Write 110 for L – Write 111 for E ● (The resulting binary string may be further compressed using any good compression algorithm.)

  50. Compression ● Number of bits required = b = |C| + 3(|S| + |L| + |R| + |E|) ● Denote boundary vertices V E and interior vertices V I . ● |T| = |C| + |S| + |L| + |R| + |E| (each op destroys one triangle) ● |C| = |V I | (observe from algorithm) ● |T| = 2|V I | + |V E | - 2 (property of triangulations) ● Hence b = 2|T| + |V E | - 2 ≤ 3|T|

  51. Compression ● Assume mesh has small boundary. – e.g., a closed genus 0 surface can be “opened up” by “cutting along” one of its edges; the resulting surface has a boundary of length 2. ● Then b ≈ 2|T|, i.e. 2 bits per triangle. – Compact repr. of any planar triangulated graph! ● Since CL and CE sequences are impossible, encoding can be made even shorter. ● In other situations, different coding schemes may be used, all of which guarantee b ≈ 2|T|.

  52. Compression ● Improvement in guarantees: [King-Rossignac '99] show coding schemes which guarantee 1.84|T| length for the encoded history of closed genus 0 meshes. ● In practice: [Rossignac-Szymczak '99] show that entropy codes “usually” give 0.91|T| to 1.26|T| lengths.

  53. Decompression ● [Rossignac '99] proposes (somewhat convoluted) O(|T| 2 ) algorithm. – Traverses history in compression order, uses preprocessing pass to compute constants + offsets and generation pass to actually recreate the graph. ● [Rossignac-Szymczak '99] propose O(|T|) “Wrap&Zip” algorithm. ● [Isenburg-Snoeyink '01] propose single-pass O(|T|) algorithm. – Traverses history in reverse order (why did it take two years to devise this “obvious” scheme???)

  54. Spirale Reversi in action E Stack (after op) History = CCRRRSLELCRRCRRRE

  55. Spirale Reversi in action R Stack (after op) History = CCRRRSLELCRRCRRR

  56. Spirale Reversi in action R Stack (after op) History = CCRRRSLELCRRCRR

  57. Spirale Reversi in action R Stack (after op) History = CCRRRSLELCRRCR

  58. Spirale Reversi in action C P 15 Stack (after op) History = CCRRRSLELCRRC

  59. Spirale Reversi in action R P 15 Stack (after op) History = CCRRRSLELCRR

  60. Spirale Reversi in action R P 15 Stack (after op) History = CCRRRSLELCR

  61. Spirale Reversi in action P 14 C P 15 Stack (after op) History = CCRRRSLELC

  62. Spirale Reversi in action P 14 L P 15 Stack (after op) History = CCRRRSLEL

  63. Spirale Reversi in action E P 14 g' P 15 g' Stack (after op) History = CCRRRSLE

  64. Spirale Reversi in action L P 14 g' P 15 g' Stack (after op) History = CCRRRSL

  65. Spirale Reversi in action P 14 S P 15 Stack (after op) History = CCRRRS

  66. Spirale Reversi in action P 14 R P 15 Stack (after op) History = CCRRR

  67. Spirale Reversi in action P 14 R P 15 Stack (after op) History = CCRR

  68. Spirale Reversi in action P 14 P 15 R Stack (after op) History = CCR

  69. Spirale Reversi in action P 14 P 13 C P 15 Stack (after op) History = CC

  70. Spirale Reversi in action P 14 P 13 P 12 P 15 C Stack (after op) History = C

  71. Spirale Reversi in action P 6 P 5 P 8 P 9 P 7 P 4 P 14 P 13 P 10 P 3 P 12 P 15 C Stack P 1 P 2 P 11 (final) History = (null)

  72. Patching holes ● While processing a loop, the third vertex v might lie on the boundary of a hole. ● Solution: Introduce M operation which merges the current loop with the hole.

  73. Handling handles ● While processing one loop, we might run into situation where the third vertex v is on some other loop created by a previous split operation. ● Solution: – Modify split operation S to mark and push additional information about the deferred loop. – When we reach a vertex marked as above, execute an M' operation, which merges the two loops.

Recommend


More recommend