Changed spec to move split data before the symbol data.

This addresses a comment in https://github.com/KhronosGroup/glTF/issues/1114
This commit is contained in:
Frank Galligan 2017-10-06 11:03:34 -07:00
parent 71d0b9abe2
commit c9d9cc4b26
5 changed files with 23 additions and 21 deletions

View File

@ -5,7 +5,10 @@
* All Draco encoded mesh files are comprised of four main sections. This first
section is the header. The second section contains the metadata. This section is optional. The third section contains the connectivity data. The fourth section contains the attribute data.
![Draco_file](images/draco_file.png)
<figure>
<img alt="" src="images/draco_file.png">
<figcaption>Figure 1. Draco file format.</figcaption>
</figure>
* The header must be decoded first, then the metadata section (if present), then the connectivity section, and then the attribute section.
@ -14,32 +17,37 @@ section is the header. The second section contains the metadata. This section is
* The sequential connectivity is comprised of two sections. The first section is the connectivity header. The second section is the indices data.
![sequential_connectivity](images/sequential_connectivity.png)
<figure>
<img alt="" src="images/sequential_connectivity.png">
<figcaption>Figure 2. Sequential connectivity format.</figcaption>
</figure>
#### EdgeBreaker Connectivity
* The EdgeBreaker connectivity section is composed of five sections. The first section is the connectivity header. The second section is the encoded EdgeBreaker symbol data. The third section is the encoded start face configuration data. The fourth section is the attribute connectivity data. The fifth section is the encoded split data.
![edgebreaker_connectivity](images/edgebreaker_connectivity.png)
* The encoded split data must be decoded before the EdgeBreaker symbols are decoded. The offset to the split data is contained in the connectivity header.
* The EdgeBreaker connectivity section is composed of five sections. The first section is the connectivity header. The second section is the encoded split data. The third section is the encoded EdgeBreaker symbol data. The fourth section is the encoded start face configuration data. The fifth section is the attribute connectivity data.
<figure>
<img alt="" src="images/edgebreaker_connectivity.png">
<figcaption>Figure 3. EdgeBreaker connectivity format.</figcaption>
</figure>
#### Valence EdgeBreaker Connectivity
* The valence EdgeBreaker connectivity inserts two sections in between the attribute connectivity data and the split data. The first section is the EdgeBreaker valence header. The second section is the context data for the valence prediction.
![edgebreaker_valence_connectivity](images/edgebreaker_valence_connectivity.png)
* The valence EdgeBreaker connectivity adds two sections after the attribute connectivity data. The first aditional section is the EdgeBreaker valence header. The second aditional section is the context data for the valence prediction.
<figure>
<img alt="" src="images/edgebreaker_valence_connectivity.png">
<figcaption>Figure 4. Valence EdgeBreaker connectivity format.</figcaption>
</figure>
#### Attributes
* The attributes data contains two sections. The first section is the attribute header. The second section is comprised of one or more attribute types, such as positions, texture coordinates, normals… Each attribute type section is comprised of one or more unique attributes.
![attributes](images/attributes.png)
<figure>
<img alt="" src="images/attributes.png">
<figcaption>Figure 5. Attribute data format.</figcaption>
</figure>
### Draco Conventions

View File

@ -40,13 +40,7 @@ void ParseTopologySplitEvents() {
~~~~~
void DecodeEdgebreakerConnectivityData() {
ParseEdgebreakerConnectivityData();
// file pointer must be set to current position
// + encoded_connectivity_size
DecodeTopologySplitEvents();
// file pointer must be saved, as it points to the attribute data
// file pointer must be set to old current position
EdgebreakerTraversalStart();
DecodeEdgeBreakerConnectivity();
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.6 KiB

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.3 KiB

After

Width:  |  Height:  |  Size: 8.1 KiB

View File

@ -1,7 +1,7 @@
---
layout: spec-page
title: Draco Bitstream Specification
version: Version 2,1
version: Version 2,2 (pending)
version_date: Released 2017-10-02
---