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 JS bindings for clusterizer API #738

Merged
merged 4 commits into from
Aug 21, 2024

Commits on Aug 21, 2024

  1. js: add clusterizer API - implementation

    Adds WASM bindings and a new JS API for the clusterizer API.
    The JS API consists of
     - buildMeshlets: generates mehslet data and implicitly optimizes the generated meshlets. Returns packed buffers containing raw meshlet data.
     - extractMeshlet: given buffers as returned by buildMeshlets and a meshlet index, returns a meshlet object containing a triangles and vertices array.
     - computeClusterBounds: computes bounds for cluster data not generated by buildMeshlets. Returns an object containing the computed bounding data, except for s8 compressed data.
     - computeMeshletBounds: given buffers as returned by buildMeshlets, computes bounds for all meshlets and returns the computed bounding data, except for s8 compressed data.
    Bumps the stack size of WASM modules to 36 kb because computeMeshletBounds and computeClusterBounds require more than the previously allocated 24kb
    JolifantoBambla committed Aug 21, 2024
    Configuration menu
    Copy the full SHA
    97fff82 View commit details
    Browse the repository at this point in the history
  2. js: add clusterizer API - tests

    Adds tests for the new JS clusterizer API.
    All tests work on a cube with normal data for which 6 clusters - one for each face - are created.
    Bounds are validated by comparing each cube face's normal to the computed normal cone's axis.
    JolifantoBambla committed Aug 21, 2024
    Configuration menu
    Copy the full SHA
    09d8f09 View commit details
    Browse the repository at this point in the history
  3. js: add clusterizer API - github actions changes

    Adds automated ES5 validation for the new JS clusterizer API.
    Adds automated tests for the new JS clusterizer API.
    JolifantoBambla committed Aug 21, 2024
    Configuration menu
    Copy the full SHA
    874d201 View commit details
    Browse the repository at this point in the history
  4. js: add clusterizer API - documentation

    Documents the new JS clusterizer API in the JS readme.
    JolifantoBambla committed Aug 21, 2024
    Configuration menu
    Copy the full SHA
    8bc3573 View commit details
    Browse the repository at this point in the history