Title: Coding with ASCII: compact, yet textbased 3D content
1Coding with ASCIIcompact, yet text-based 3D
content
- Martin Isenburg Jack Snoeyink
- University of North Carolina at Chapel
HillandINRIA Sophia-Antipolis
2Overview
- Motivation
- Polygon Meshes
- Coding of Indices
- Position Indices TexCoord Indices
- Quantizing Coding of Coordinates
- Positions Texture Coordinates
- Example
- Results, Demos Conclusion
3Motivation
4Why ASCII?
- authors like text-based 3D formats
- wide acceptance
- read modify scene with any text editor
- Web3D Developer survey very important
- ? many Web3D APIs only support ASCII(rather than
supporting two formats) - ? no binary VRML specification
5Why Compression?
- authors want compressed 3D content
- faster download
- Web3D Developer survey very important
- data-heavy nodes
- audio
- images
- video
- geometry
- interpolators
6Approaches
- readable text-based format
- support only ASCII content
- exception standard binary data
- VRML and its variants
- binary format
- one (or more) binary files
- automatically protects the content
- proprietary (Cult, Shockwave, Viewpoint ...)
7Compression Standards (1)
- binary compression standards
- image data JPEG, GIF
- audio data MP3
- movie data MPEG
- geometry data ? (MPEG-4/7 ??)
- interpolator data ? (MPEG-4/7 ??)
- read edit write software is plentiful
8Compression Standards (2)
- the structure of 3D data is more complex
- audio sequence of numbers
- image block of numbers
- video sequence of blocks of numbers
- geometry positions triangles (or
polygons ?) texcoords (1, 2, 3, or 8 layers
?) normals or smoothing groups (?)
colors (per-face or per-vertex ?) bones (1,
2 or 3 attachments ?)
9Download on Demand
- java-based browsers
- Shout3D, Blaxxun3D, CortonaJet, Hotmedia
- provide decoder with the model.
- light-weight important
- it has to be downloaded also
- download less was motivation to compress
- proposed decoder gtgt 5381 bytes ltlt
10Polygon Meshes
11Polygon Meshes
- Polygon Mesh Indexed Face Set (IFS)
- minimally
- p positions float 3p
- f faces with c corners int f c
- optionally
- t texCoords float 2t
- f faces with c corners int f c
12Example a box
- IndexedFaceSet
- coord Coordinate
- point -1.0 1.0 -1.0 , -1.0 -1.0 -1.0 ,
1.0-1.0 -1.0 , 1.0 1.0 -1.0 , -1.0 -1.0 1.0 ,
1.0 -1.0 1.0, -1.0 1.0 1.0, 1.0 1.0 1.0 -
- coordIndex 0 1 2 3 -1 3 2 5 7 -1 1 4 5 2 -1 6
0 3 7 -1 6 4 1 0 -1 6 7 5 4 -1
13coord (Geometry)
14coordIndex (Connectivity)
5
3
face0 0 1 2 3
face1 3 2 5 7
0
4
1
face2 1 4 5 2
face3 6 0 3 7
2
face4 6 4 1 0
face5 6 7 5 4
15Example a textured box
- IndexedFaceSet
- . . . . . .
- texCoord Coordinate
- point 0.4 0.5 , 0.4 0.3 , 0.6 0.3 , 0.6 0.5,
0.8 0.3 , 0.8 0.5 , 0.4 0.1 , 0.6 0.1 , 0.2 0.5 ,
0.2 0.3 , 0.4 0.7 , 0.6 0.7 , 0.4 0.9 , 0.6 0.9 -
- texCoordIndex 0 1 2 3 -1 3 2 4 5 -1 1 6 7 2-1
10 0 3 11 -1 8 9 1 0 -1 10 11 13 12 -1
16texCoord (Property Values)
17texCoordIndex (Property Mapping)
5
10
11
10
11
3
8
5
face0 0 1 2 3
0
3
3
face1 3 2 4 5
0
0
3
0
4
1
face2 1 6 7 2
1
2
1
2
face3 10 0 3 11
1
2
2
4
9
face4 8 9 1 0
6
7
13
12
face5 10 11 13 12
18Coding of Indices (1)Position Indices
19Coding Position Indices
- gt dont code indices directly lt
- Assumption
- order of position doesnt matter
- Approach
- change order of positions
- code connectivity graph
- enumerate positions based on traversal order
- re-order accordingly
- gt code indices implicitly lt
20Connectivity Coders
- ? for Triangle Meshes
- Topological Surgery, Taubin et al., 97
- Triangle Mesh Compression, Touma Gotsman, 98
- Cut-Border-Machine, Gumhold Strasser, 98
- Edgebreaker, Rossignac, 99
- ? for Polygon Meshes
- Face Fixer, Isenburg Snoeyink, 00
- Degree Duality Coder, Isenburg, 02
- Near-Optimal Connectivity Encoding, Khodakovsky,
Alliez, Desbrun Schröder, 02
21Face Fixer
- region growing
- encodes connectivity graph as a sequence of
labels - one label . . . . per
face - one label per hole
- one label per handle
- labels and fix it all
together - number of labels number of edges
- reverse decoding
22Face Fixer
23Encoding
29
0
6
91
27
14
68
5
72
98
53
86
31
67
77
9
22
11
25
43
2
78
24Encoding
29
0
6
91
27
14
68
5
72
98
53
86
31
67
77
9
22
11
25
43
2
78
25Encoding
29
0
6
91
27
14
68
5
72
98
53
86
31
67
77
9
22
11
25
43
2
78
26Encoding
29
0
6
91
27
14
68
5
72
98
53
86
31
67
77
9
22
11
25
43
2
78
27Encoding
29
0
6
91
27
14
68
5
72
98
53
86
31
67
77
9
22
11
25
43
2
78
28Encoding
29
0
6
91
27
14
68
5
72
98
53
86
31
67
77
9
22
11
25
43
2
78
29Encoding
29
0
6
91
27
14
68
5
72
98
53
86
31
67
77
9
22
11
25
43
2
78
30Encoding
29
0
6
91
27
14
68
5
72
98
53
86
31
67
77
9
22
11
25
43
2
78
31Mapping Labels to ASCII
. . .
. . .
. . .
. . .
32Decoding
14
12
23
11
13
47
24
26
26
46
27
25
44
43
42
45
61
33Decoding
14
12
23
11
13
47
24
26
26
46
27
25
44
43
42
45
61
62
34Decoding
14
12
23
11
13
47
24
26
26
46
27
25
44
43
42
45
63
61
62
35Decoding
14
12
23
11
13
47
24
26
26
46
27
25
44
43
42
45
63
61
62
36Decoding
14
12
23
11
13
47
24
26
26
46
27
25
44
43
42
45
63
61
62
37Decoding
14
12
23
11
13
47
24
26
26
46
27
25
44
43
42
45
63
61
64
62
38Decoding
14
12
23
11
13
47
24
26
26
46
27
25
44
43
42
45
63
61
64
62
39Decoding
14
12
23
11
13
47
24
26
26
46
27
25
44
43
42
45
63
61
64
62
40Non-Manifold Meshes
41Coding ofIndices (2)TexCoord Indices
42Coding TexCoord Indices
- gt dont code indices directly lt
- Assumption
- order of texCoords doesnt matter
- Approach
- change order of texCoords
- code on top of connectivity graph
- enumerate texCoords based on traversal order
- re-order accordingly
- gt code indices implicitly lt
43Per-Corner Mappings
- edge bits, Gumhold StrasserReal-time
compression of triangle mesh connectivity,
SIGGRAPH 98 - discontinuity bits, Taubin et al.Geometry
coding and VRML, Proceedings of the IEEE 98 - vertex and corner bits, Isenburg Snoeyink
Face Fixer Compressing Polygon Meshes with
Properties, SIGGRAPH 00
44Vertex and Corner Bits (1)
45Vertex and Corner Bits (2)
46Vertex and Corner Bits (3)
47Encoding
1
48Encoding
1
0
0
49Encoding
1
0
0
1
50Encoding
1
0
0
0
1
51Encoding
1
1
0
0
0
1
52Encoding
1
0
1
1
0
0
0
1
53Encoding
1
0
0
1
1
0
0
0
1
54Encoding
1
0
0
0
1
1
0
0
0
1
55Encoding
1
0
1
0
0
1
1
0
0
0
1
56Encoding
0
1
0
1
0
0
1
1
0
0
0
1
57Encoding
0
0
1
0
1
0
0
1
1
0
0
0
1
58Encoding
0
0
1
0
1
0
0
0
1
1
1
0
0
0
1
59Encoding
0
0
1
0
1
0
0
0
1
1
1
1
0
0
0
1
60Encoding
0
0
1
0
1
0
0
1
0
1
1
1
1
0
0
0
1
61Encoding
0
0
1
0
1
0
0
0
1
0
1
1
1
1
0
0
0
1
62Encoding
0
0
1
0
1
0
0
0
1
0
1
1
1
0
1
1
0
0
0
1
63Encoding
0
0
1
0
1
0
0
0
1
0
1
1
1
0
0
1
1
0
0
0
1
64Encoding
0
0
1
0
1
0
0
0
1
0
1
1
1
1
0
0
1
1
0
0
0
1
65Encoding
0
0
1
0
1
0
0
0
1
0
1
1
0
1
1
0
0
1
1
0
0
0
1
66Encoding
1
0
0
1
0
1
0
0
0
1
0
1
1
0
1
1
0
0
1
1
0
0
0
1
67Encoding
1
0
0
1
0
1
0
0
0
1
0
1
1
0
1
1
0
0
1
1
0
0
0
1
68Quantizing Coding of Coordinates
69Quantize
- calculate bounding box
- (minx, miny, minz) and (maxx, maxy maxz)
- calculate extends of bounding box
- rangex maxx minx
- rangey maxy miny
-
- quantize with longest extend getting n bits
70Delta Code
- coordinates are integer numbers
- only write difference to last
- resulting sequence has lower dispersion
- there are much better schemes !!!
- why delta-coding ???
- simple, light-weight implementation
- submission deadline was close
71Decoding Example
72code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
0
1
indices
texindices
73code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
2
0
1
indices
texindices
74code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
3
2
0
1
indices
texindices
75code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
3
0
2
1
3
0
2
1
indices
-1
1
0
3
2
texindices
-1
76code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
3
0
4
2
1
3
0
2
1
indices
-1
1
0
3
2
texindices
-1
77code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
3
0
4
2
1
3
0
2
1
5
indices
-1
1
0
3
2
texindices
-1
78code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
3
0
7
4
2
1
6
3
8
0
2
1
5
5
indices
-1
1
0
3
2
4
3
5
0
-1
texindices
-1
-1
79code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
3
0
7
4
2
1
6
3
8
0
2
1
5
5
6
indices
-1
1
0
3
2
4
3
5
0
-1
texindices
-1
-1
80code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
3
0
7
4
2
1
6
3
8
0
2
1
5
5
7
6
indices
-1
1
0
3
2
4
3
5
0
-1
texindices
-1
-1
81code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
3
0
7
4
2
1
6
1
0
3
8
0
2
1
5
5
hole
7
6
indices
-1
1
0
3
2
4
3
5
0
-1
texindices
-1
-1
1
0
82code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
3
0
7
4
2
1
6
1
0
0
2
1
5
5
hole
4
7
6
indices
-1
1
0
3
2
4
3
5
0
-1
texindices
-1
-1
1
0
83code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
3
0
7
4
2
1
6
1
0
0
2
1
5
5
12
hole
4
10
11
7
6
indices
4
-1
1
0
3
2
4
3
5
0
-1
1
-1
7
texindices
-1
-1
1
0
-1
84code_words
438 3 0 0 6 0 0 6 0 0 7 -1 6 0
-1 4 5 5 0
3
7
0
4
2
6
1
1
0
16
2
0
0
2
1
1
2
15
5
2
5
12
14
hole
4
10
11
7
6
indices
4
4
1
2
-1
4
3
-1
5
1
0
3
2
1
-1
7
0
-1
texindices
2
-1
-1
2
1
2
-1
0
-1
85Results
86fish scene
- Shape appearance Appearance material
Material modulateTextureWithDiffuse
true diffuseColor 1 1 1 texture
ImageTexture url fish.jpg geometry
IndexedFaceSet coord Coordinate point
-0.0715 4.7609 6.3930 -0.0715 ... -0.4479 -4.5153
4.5304 coordIndex 7 6 209 204 -1 4 217
210 4577 -1 4577 4223 4222 -1 texCoord
TextureCoordinate point 0.3735 0.9441
0.3289 0.9315 0.2666 0.4990 0.1082
texCoordIndex 0 1 2 3 -1 4 5 6 7 -1 8
4311 -1 4311 4293 4683 -1
87fish scene
- Shape appearance Appearance material
Material modulateTextureWithDiffuse
true diffuseColor 1 1 1 texture
ImageTexture url fish.jpg geometry
IndexedFaceSet coord Coordinate point
-0.0715 4.7609 6.3930 -0.0715 ... -0.4479 -4.5153
4.5304 coordIndex 7 6 209 204 -1 4 217
210 4577 -1 4577 4223 4222 -1 texCoord
TextureCoordinate point 0.3735 0.9441
0.3289 0.9315 0.2666 0.4990 0.1082
texCoordIndex 0 1 2 3 -1 4 5 6 7 -1 8
4311 -1 4311 4293 4683 -1
88lossless-coded fish scene
- Shape appearance Appearance material
Material modulateTextureWithDiffuse
true diffuseColor 1 1 1 texture
ImageTexture url fish.jpg geometry
CodedIndexedFaceSet coord Coordinate point
-0.1195 -2.0148 ... -4.5153 4.5304 -0.4689
-4.4092 4.4136 texCoord TextureCoordinate
point 0.0150 0.5031 0.2549 0.3889 0.2581
0.3825 0.2520 code 24045 3 0 3 1 1 2 0 0
0 0 0 0 3 5 0 5 0 5 0 5 0 6 0 0 0 0 2
89lossy-coded fish scene
- Shape appearance Appearance material
Material modulateTextureWithDiffuse
true diffuseColor 1 1 1 texture
ImageTexture url fish.jpg geometry
CodedIndexedFaceSet coord Coordinate point
-2 -4 -1 -3 -3 0 -4 -47 ... 37 4 -21 24 -0.4689
-4.4092 4.4136 texCoord TextureCoordinate
point 0 0 0 0 0 -4 0 1 -1 -1 0 0 0 -1 5 3
-4 0 2 2 0.3825 0.2520 code 24045 3 0 3 1
1 2 0 0 0 0 0 0 3 5 0 5 0 5 0 5 0 6 0 0 0 0 2
pos 4.884e-3 tex 3.8234e-3
90Results Dense Scenes
model
plain
coded
quantized
lion 441.6 201.6 46 66.2 15
wolf 183.1 84.5 46 29.4 16
raptor 199.8 100.7 50 34.9 17
fish 122.9 55.4 45 22.8 19
snake 312.3 138.1 44 34.8 11
horse 266.4 124.3 47 40.9 15
cat 267.3 128.4 48 39.9 15
dog 186.2 87.3 47 34.6 19
91Results Sparse Scene
33 indexed face sets 5 position interpolators 27
orientation interpolators
66
31
file size of swing.wrl.gz in bytes
--- 29895 IFS 18364 61
92Demos
93Demos
- Shout3D ASCII coder gt local web lt
- Various Scenes
- Swing (static) gt local web lt
- Swing (animated) gt local web lt
- Fish gt local web lt
- Lion gt local web lt
- Snake gt local web lt
http//www.cs.unc.edu/isenburg/asciicoder/
94Conclusion
- geometry coding for ASCII formats
- compressed, but not binary
- authors not forced to change habits
- VRML / X3D geometry compression
- long wanted feature (96)
- VRML-CBF proposal refused (98)
- BF call for proposals unanswered (00)
- Conformance ASCII BINARY
95Current Work
- Arithmetic ASCII
- (nearly) as compact as a compressed binary
format - straight-forward mapping to binary
- no compromise on binary compression rates
- same decoding algorithm for binary and ASCII
version of a node - good for rapid prototyping / proof-of-concept
96Acknowledgements
- Paul Isaacs for telling me
- no, we dont have
geometrycompression because the Shout3D API does
not support binary input - Curious Labs Shout3D for the models
- ARC TéléGeo of INRIA Sophia-Antipolis for partial
funding
97Thank You.http//www.cs.unc.edu/isenburg/ascii
coder/