Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create binary storage format #41

Open
onox opened this issue Jun 17, 2019 · 0 comments
Open

Create binary storage format #41

onox opened this issue Jun 17, 2019 · 0 comments
Milestone

Comments

@onox
Copy link
Owner

onox commented Jun 17, 2019

glTF has several problems because it was designed for WebGL instead of OpenGL 4.x:

  • Requires PNG and JPG support (needs to be decoded and do not use GPU compression) but does not support KTX textures
  • Requires parsing a JSON file, which slows down loading models
  • Each mesh in a model's scene may use a different vertex format. Although in practice the format of the attributes is the same for all meshes, their index type (uint16 or uint32) may differ
  • No SPDX license identifier for meshes

Create a binary storage format:

  • Based on document container files using the dcf-ada library (already used for locations in Add implementation of interface Location that can read .zip files #35)
  • Require all files stored in the container to use the "store" compression format
    • Vertex data may be compressed with Draco
  • Optimized for OpenGL 4.3 or later and Vulkan
  • Any software supporting this format must ignore any unknown files in the container
  • TODO Add that assets can be assumed/required to be on SSDs? (No slow storage)
  • TODO Support cameras, lights and speakers?
  • Textures must be stored in one or more KTX files in the container
  • TODO Specify PBR requirements for materials
    • TODO Specify transparency, refraction, and clear coat requirements
  • Vertex attributes must not be interleaved
    • TODO Allow quantization parameters?
  • Vertex buffers and the index buffer are stored in separate files in the container
  • Must contain an index buffer
  • Contains a file describing the vertex format
    • Index type must be unsigned short or unsigned int
    • A vertex format has a single specific index type
  • Contains a file describing the bounding boxes of meshes
  • Contains a file with an array of draw commands (GL.Types.Indirect.Elements_Indirect_Command_Array)
    • TODO Multiple arrays for different pipeline state? (Opaque and transparent meshes) (in that case there may be multiple vertex formats as well)
  • Contains a file describing the scene tree
    • TODO Specify how the tree must be stored (a single array of the levels or multiple levels)
  • Contains a file with copyright and SPDX license identifiers of the meshes
    • TODO Contain matrices (or euler or quaternions) and/or visibility flags?
    • TODO Support multiple LoDs?
  • TODO Support skinning and animation?
@onox onox added this to the 1.1 milestone Jun 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant