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

Add NGA_gpm_local validation #316

Merged
merged 8 commits into from
Nov 21, 2024
Merged

Add NGA_gpm_local validation #316

merged 8 commits into from
Nov 21, 2024

Conversation

javagl
Copy link
Contributor

@javagl javagl commented Oct 19, 2024

The document "The Generic Point-cloud Model (GPM): Implementation and Exploitation, Version 1.2, 2024-02-29" from the National Geospatial-Intelligence Agency (NGA) is published at https://nsgreg.nga.mil/csmwg.jsp . It defines two extensions:

  • NGA_gpm: A 3D Tiles extension which stores tileset-level GPM metadata
  • NGA_gpm_local: A glTF extension that stores local GPM metadata

This PR adds support for the validation of NGA_gpm_local.
(Support for the validation of NGA_gpm will be added soon - probably, in a dedicated PR)

Even though this is a glTF extension, the support is implemented here, and not in the glTF-Validator. There have been considerations to add this to the glTF-Validator, but implementing it here allows for faster iterations (independent of the glTF-Validator releases), it does not have the "language barrier" (the glTF Validator is implemented in Dart), and the validation for the other Cesium glTF extensions (like EXT_structural_metadata and EXT_mesh_features) have also been implemented as part of the 3D Tiles Validator. Technically, the validation of the glTF extensions in the context of the 3D Tiles validator is implemented by using the glTF validator to perform the "main" validation of the glTF, and - when the glTF is valid in general - diving into the extension-specific validation steps.

For reviewers:

There is one commit that splits the existing glTF extension validation classes into several subdirectories. But basically all the functionality here is added with a single commit, a61e50b , which adds the NgaGpmLocalValidator.ts. This receives the glTF data and performs the validation. (Subsequent PRs add the specs, which mainly consist of list of glTFs that contain the extension, and that are 'invalid' in one way or another).

The validation currently covers only the JSON-level. There are a few ways in which certain aspects could be made more strict. For example: The extension may contain "correlation matrices", and one could add checks whether these matrices are always
positive semi-definite. The matrices are usually given as "upper triangles", meaning that they are always symmetric. An additional check could be whether the lengths of these "upper triangles" indeed are triangular numbers (1, 3, 6, 10, 15, 21...). Some of the details here are still being discussed internally.

@javagl javagl mentioned this pull request Nov 9, 2024
@lilleyse lilleyse merged commit a7c8c52 into main Nov 21, 2024
2 checks passed
@lilleyse lilleyse deleted the gpm-support branch November 21, 2024 14:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants