@luma.gl/engine 10.0.0-beta.1 → 10.0.0-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/animation/deform-positions.d.ts +1 -1
- package/dist/animation/deform-positions.d.ts.map +1 -1
- package/dist/animation/skin.cjs +4 -4
- package/dist/animation/skin.d.ts +1 -1
- package/dist/animation/skin.d.ts.map +1 -1
- package/dist/animation/skin.js +1 -1
- package/dist/animation/skin.js.map +1 -1
- package/dist/animation/texture-transform.cjs +7 -7
- package/dist/animation/texture-transform.js +1 -1
- package/dist/animation/texture-transform.js.map +1 -1
- package/dist/arrow/arrow-mesh-types.d.ts +1 -1
- package/dist/arrow/arrow-mesh-types.d.ts.map +1 -1
- package/dist/arrow/index.cjs.map +2 -2
- package/dist/arrow/renderers/path/conversion/arrow-path-storage-gpu-vectors.cjs +2 -2
- package/dist/arrow/renderers/path/conversion/arrow-path-storage-gpu-vectors.d.ts +1 -1
- package/dist/arrow/renderers/path/conversion/arrow-path-storage-gpu-vectors.js +1 -1
- package/dist/arrow/renderers/path/transforms/gpu-path-float64-deltas.cjs +1 -0
- package/dist/arrow/renderers/path/transforms/gpu-path-float64-deltas.d.ts.map +1 -1
- package/dist/arrow/renderers/path/transforms/gpu-path-float64-deltas.js +1 -0
- package/dist/arrow/renderers/path/transforms/gpu-path-float64-deltas.js.map +1 -1
- package/dist/arrow/renderers/splats/conversion/make-gpu-splat-data-from-gltf.cjs +2 -2
- package/dist/arrow/renderers/splats/conversion/make-gpu-splat-data-from-gltf.js +1 -1
- package/dist/arrow/renderers/splats/conversion/make-gpu-splat-data-from-gltf.js.map +1 -1
- package/dist/audio/audio-controller.cjs +6 -6
- package/dist/audio/audio-controller.d.ts +1 -1
- package/dist/audio/audio-controller.d.ts.map +1 -1
- package/dist/audio/audio-controller.js +1 -1
- package/dist/audio/audio-controller.js.map +1 -1
- package/dist/audio/audio-environment.cjs +6 -6
- package/dist/audio/audio-environment.d.ts +1 -1
- package/dist/audio/audio-environment.d.ts.map +1 -1
- package/dist/audio/audio-environment.js +1 -1
- package/dist/audio/audio-environment.js.map +1 -1
- package/dist/compute/computation.d.ts +1 -1
- package/dist/compute/computation.d.ts.map +1 -1
- package/dist/debug/pixel-data-utils.d.ts +1 -1
- package/dist/debug/pixel-data-utils.d.ts.map +1 -1
- package/dist/dist.dev.js +293 -229
- package/dist/dist.min.js +73 -59
- package/dist/effects/index.cjs.map +1 -1
- package/dist/effects/passes/screen-space/camera-reprojection-temporal-antialiasing.d.ts +1 -1
- package/dist/effects/passes/screen-space/camera-reprojection-temporal-antialiasing.d.ts.map +1 -1
- package/dist/effects/passes/screen-space/clustered-volumetric-lighting.d.ts +1 -1
- package/dist/effects/passes/screen-space/clustered-volumetric-lighting.d.ts.map +1 -1
- package/dist/effects/passes/screen-space/gtao.cjs +4 -4
- package/dist/effects/passes/screen-space/gtao.d.ts +1 -1
- package/dist/effects/passes/screen-space/gtao.d.ts.map +1 -1
- package/dist/effects/passes/screen-space/gtao.js +1 -1
- package/dist/effects/passes/screen-space/gtao.js.map +1 -1
- package/dist/effects/passes/screen-space/height-fog.d.ts +1 -1
- package/dist/effects/passes/screen-space/height-fog.d.ts.map +1 -1
- package/dist/effects/passes/screen-space/screen-space-global-illumination.d.ts +1 -1
- package/dist/effects/passes/screen-space/screen-space-global-illumination.d.ts.map +1 -1
- package/dist/effects/passes/screen-space/screen-space-reflections.d.ts +1 -1
- package/dist/effects/passes/screen-space/screen-space-reflections.d.ts.map +1 -1
- package/dist/effects/passes/screen-space/ssr-camera-temporal.d.ts +1 -1
- package/dist/effects/passes/screen-space/ssr-camera-temporal.d.ts.map +1 -1
- package/dist/experimental/controls/index.cjs +0 -3
- package/dist/experimental/controls/index.cjs.map +2 -2
- package/dist/experimental/controls/index.d.ts +0 -2
- package/dist/experimental/controls/index.d.ts.map +1 -1
- package/dist/experimental/controls/index.js +0 -1
- package/dist/experimental/controls/index.js.map +1 -1
- package/dist/experimental/webxr/webxr-input.d.ts +1 -1
- package/dist/experimental/webxr/webxr-input.d.ts.map +1 -1
- package/dist/experimental-controls.cjs +21 -0
- package/dist/experimental-controls.d.ts +2 -0
- package/dist/experimental-controls.d.ts.map +1 -0
- package/dist/experimental-controls.js +5 -0
- package/dist/experimental-controls.js.map +1 -0
- package/dist/experimental-materials.cjs +21 -0
- package/dist/experimental-materials.d.ts +2 -0
- package/dist/experimental-materials.d.ts.map +1 -0
- package/dist/experimental-materials.js +5 -0
- package/dist/experimental-materials.js.map +1 -0
- package/dist/experimental-textures.cjs +21 -0
- package/dist/experimental-textures.d.ts +2 -0
- package/dist/experimental-textures.d.ts.map +1 -0
- package/dist/experimental-textures.js +5 -0
- package/dist/experimental-textures.js.map +1 -0
- package/dist/{experimental/controls/orbit-controls.cjs → experimental-webxr.cjs} +5 -11
- package/dist/experimental-webxr.d.ts +2 -0
- package/dist/experimental-webxr.d.ts.map +1 -0
- package/dist/experimental-webxr.js +5 -0
- package/dist/experimental-webxr.js.map +1 -0
- package/dist/geometry/edge-geometry.d.ts +1 -1
- package/dist/geometry/edge-geometry.d.ts.map +1 -1
- package/dist/geometry/geometry-primitives.cjs +18 -17
- package/dist/geometry/geometry-primitives.d.ts +2 -2
- package/dist/geometry/geometry-primitives.d.ts.map +1 -1
- package/dist/geometry/geometry-primitives.js +3 -2
- package/dist/geometry/geometry-primitives.js.map +1 -1
- package/dist/geometry/geometry-table.d.ts +1 -1
- package/dist/geometry/geometry-table.d.ts.map +1 -1
- package/dist/geometry/geometry-utils.cjs +6 -6
- package/dist/geometry/geometry-utils.d.ts +2 -2
- package/dist/geometry/geometry-utils.d.ts.map +1 -1
- package/dist/geometry/geometry-utils.js +1 -1
- package/dist/geometry/geometry-utils.js.map +1 -1
- package/dist/geometry/geometry.cjs +2 -2
- package/dist/geometry/geometry.d.ts +4 -3
- package/dist/geometry/geometry.d.ts.map +1 -1
- package/dist/geometry/geometry.js +1 -1
- package/dist/geometry/geometry.js.map +1 -1
- package/dist/geometry/gpu-geometry.d.ts +1 -1
- package/dist/geometry/gpu-geometry.d.ts.map +1 -1
- package/dist/geometry/gpu-vector-geometry-adapter.d.ts +1 -1
- package/dist/geometry/gpu-vector-geometry-adapter.d.ts.map +1 -1
- package/dist/geometry/ring-geometry.cjs +6 -6
- package/dist/geometry/ring-geometry.d.ts +1 -1
- package/dist/geometry/ring-geometry.d.ts.map +1 -1
- package/dist/geometry/ring-geometry.js +2 -2
- package/dist/geometry/ring-geometry.js.map +1 -1
- package/dist/gltf/gltf/create-composed-scenegraphs-from-gltf.cjs +80 -0
- package/dist/gltf/gltf/create-composed-scenegraphs-from-gltf.d.ts +28 -0
- package/dist/gltf/gltf/create-composed-scenegraphs-from-gltf.d.ts.map +1 -0
- package/dist/gltf/gltf/create-composed-scenegraphs-from-gltf.js +74 -0
- package/dist/gltf/gltf/create-composed-scenegraphs-from-gltf.js.map +1 -0
- package/dist/gltf/gltf/create-gltf-model.d.ts +1 -1
- package/dist/gltf/gltf/create-gltf-model.d.ts.map +1 -1
- package/dist/gltf/gltf/create-scenegraph-from-gltf.cjs +13 -4
- package/dist/gltf/gltf/create-scenegraph-from-gltf.d.ts.map +1 -1
- package/dist/gltf/gltf/create-scenegraph-from-gltf.js +11 -0
- package/dist/gltf/gltf/create-scenegraph-from-gltf.js.map +1 -1
- package/dist/gltf/gltf/gltf-animated-crowd.d.ts +2 -1
- package/dist/gltf/gltf/gltf-animated-crowd.d.ts.map +1 -1
- package/dist/gltf/gltf/gltf-animated-crowd.js.map +1 -1
- package/dist/gltf/gltf/gltf-instancing.cjs +2 -2
- package/dist/gltf/gltf/gltf-instancing.d.ts +1 -1
- package/dist/gltf/gltf/gltf-instancing.d.ts.map +1 -1
- package/dist/gltf/gltf/gltf-instancing.js +1 -1
- package/dist/gltf/gltf/gltf-instancing.js.map +1 -1
- package/dist/gltf/gltf/gltf-lightmap.cjs +2 -2
- package/dist/gltf/gltf/gltf-lightmap.d.ts +1 -1
- package/dist/gltf/gltf/gltf-lightmap.d.ts.map +1 -1
- package/dist/gltf/gltf/gltf-lightmap.js +1 -1
- package/dist/gltf/gltf/gltf-lightmap.js.map +1 -1
- package/dist/gltf/gltf/gltf-skin.cjs +1 -1
- package/dist/gltf/gltf/gltf-skin.js +2 -2
- package/dist/gltf/gltf/gltf-skin.js.map +1 -1
- package/dist/gltf/index.cjs +3 -0
- package/dist/gltf/index.cjs.map +3 -3
- package/dist/gltf/index.d.ts +1 -0
- package/dist/gltf/index.d.ts.map +1 -1
- package/dist/gltf/index.js +1 -0
- package/dist/gltf/index.js.map +1 -1
- package/dist/gltf/parsers/parse-gltf-lights.cjs +5 -5
- package/dist/gltf/parsers/parse-gltf-lights.js +1 -1
- package/dist/gltf/parsers/parse-gltf-lights.js.map +1 -1
- package/dist/gltf/parsers/parse-gltf-physics-pointer.cjs +1 -1
- package/dist/gltf/parsers/parse-gltf-physics-pointer.js +1 -1
- package/dist/gltf/parsers/parse-gltf-physics-pointer.js.map +1 -1
- package/dist/gltf/parsers/parse-gltf.cjs +2 -1
- package/dist/gltf/parsers/parse-gltf.d.ts +2 -0
- package/dist/gltf/parsers/parse-gltf.d.ts.map +1 -1
- package/dist/gltf/parsers/parse-gltf.js +3 -1
- package/dist/gltf/parsers/parse-gltf.js.map +1 -1
- package/dist/gltf/parsers/parse-pbr-material.cjs +27 -27
- package/dist/gltf/parsers/parse-pbr-material.js +1 -1
- package/dist/gltf/parsers/parse-pbr-material.js.map +1 -1
- package/dist/gltf/physics/export-state.cjs +118 -17
- package/dist/gltf/physics/export-state.d.ts +9 -2
- package/dist/gltf/physics/export-state.d.ts.map +1 -1
- package/dist/gltf/physics/export-state.js +172 -19
- package/dist/gltf/physics/export-state.js.map +1 -1
- package/dist/gltf/physics/index.cjs.map +2 -2
- package/dist/gltf/physics/index.d.ts +1 -1
- package/dist/gltf/physics/index.d.ts.map +1 -1
- package/dist/gltf/physics/index.js.map +1 -1
- package/dist/gltf/physics/mesh-snapshot.cjs +3 -3
- package/dist/gltf/physics/mesh-snapshot.js +1 -1
- package/dist/gltf/physics/mesh-snapshot.js.map +1 -1
- package/dist/gltf/physics/node-collision-geometry.cjs +3 -3
- package/dist/gltf/physics/node-collision-geometry.js +1 -1
- package/dist/gltf/physics/node-collision-geometry.js.map +1 -1
- package/dist/gltf/physics/parse-gltf-physics.cjs +20 -17
- package/dist/gltf/physics/parse-gltf-physics.d.ts.map +1 -1
- package/dist/gltf/physics/parse-gltf-physics.js +7 -3
- package/dist/gltf/physics/parse-gltf-physics.js.map +1 -1
- package/dist/gltf/physics/parse-physics-joints.cjs +3 -3
- package/dist/gltf/physics/parse-physics-joints.d.ts +1 -1
- package/dist/gltf/physics/parse-physics-joints.d.ts.map +1 -1
- package/dist/gltf/physics/parse-physics-joints.js +1 -1
- package/dist/gltf/physics/parse-physics-joints.js.map +1 -1
- package/dist/gltf/physics/physics-types.d.ts +4 -0
- package/dist/gltf/physics/physics-types.d.ts.map +1 -1
- package/dist/gltf/physics/property-bindings.cjs +9 -6
- package/dist/gltf/physics/property-bindings.d.ts.map +1 -1
- package/dist/gltf/physics/property-bindings.js +12 -3
- package/dist/gltf/physics/property-bindings.js.map +1 -1
- package/dist/gltf/types/gltf-postprocessed-schema.d.ts +4 -0
- package/dist/gltf/types/gltf-postprocessed-schema.d.ts.map +1 -1
- package/dist/gltf/types/gltf-types.d.ts +2 -0
- package/dist/gltf/types/gltf-types.d.ts.map +1 -1
- package/dist/graph/models/index.cjs.map +2 -2
- package/dist/graph/models/path/path-storage-model.cjs +8 -8
- package/dist/graph/models/path/path-storage-model.d.ts +1 -1
- package/dist/graph/models/path/path-storage-model.js +2 -2
- package/dist/graph/models/polygon/polygon-attribute-model.cjs +4 -4
- package/dist/graph/models/polygon/polygon-attribute-model.d.ts +1 -1
- package/dist/graph/models/polygon/polygon-attribute-model.js +1 -1
- package/dist/graph/models/polygon/polygon-shaders.d.ts +1 -1
- package/dist/graph/models/polygon/polygon-storage-model.cjs +4 -4
- package/dist/graph/models/polygon/polygon-storage-model.d.ts +1 -1
- package/dist/graph/models/polygon/polygon-storage-model.js +1 -1
- package/dist/graph/physics/index.cjs +3 -0
- package/dist/graph/physics/index.cjs.map +3 -3
- package/dist/graph/physics/index.d.ts +2 -1
- package/dist/graph/physics/index.d.ts.map +1 -1
- package/dist/graph/physics/index.js +1 -0
- package/dist/graph/physics/index.js.map +1 -1
- package/dist/graph/physics/physics-controller-geometry.cjs +8 -8
- package/dist/graph/physics/physics-controller-geometry.js +2 -2
- package/dist/graph/physics/physics-controller-geometry.js.map +1 -1
- package/dist/graph/physics/physics-controller.cjs +95 -31
- package/dist/graph/physics/physics-controller.d.ts +36 -9
- package/dist/graph/physics/physics-controller.d.ts.map +1 -1
- package/dist/graph/physics/physics-controller.js +96 -31
- package/dist/graph/physics/physics-controller.js.map +1 -1
- package/dist/graph/physics/physics-scenegraph.cjs +4 -4
- package/dist/graph/physics/physics-scenegraph.d.ts +1 -1
- package/dist/graph/physics/physics-scenegraph.d.ts.map +1 -1
- package/dist/graph/physics/physics-scenegraph.js +1 -1
- package/dist/graph/physics/physics-scenegraph.js.map +1 -1
- package/dist/graph/physics/scenegraph-instance.cjs +14 -7
- package/dist/graph/physics/scenegraph-instance.d.ts.map +1 -1
- package/dist/graph/physics/scenegraph-instance.js +15 -7
- package/dist/graph/physics/scenegraph-instance.js.map +1 -1
- package/dist/graph/physics/scenegraph-motion.cjs +7 -7
- package/dist/graph/physics/scenegraph-motion.d.ts +1 -1
- package/dist/graph/physics/scenegraph-motion.d.ts.map +1 -1
- package/dist/graph/physics/scenegraph-motion.js +1 -1
- package/dist/graph/physics/scenegraph-motion.js.map +1 -1
- package/dist/graph/physics/scenegraph-properties.cjs +3 -3
- package/dist/graph/physics/scenegraph-properties.js +1 -1
- package/dist/graph/physics/scenegraph-properties.js.map +1 -1
- package/dist/graph/physics/scenegraph-publication.cjs +5 -5
- package/dist/graph/physics/scenegraph-publication.d.ts +1 -1
- package/dist/graph/physics/scenegraph-publication.d.ts.map +1 -1
- package/dist/graph/physics/scenegraph-publication.js +1 -1
- package/dist/graph/physics/scenegraph-publication.js.map +1 -1
- package/dist/graph/physics/scenegraph-ragdoll.cjs +132 -0
- package/dist/graph/physics/scenegraph-ragdoll.d.ts +32 -0
- package/dist/graph/physics/scenegraph-ragdoll.d.ts.map +1 -0
- package/dist/graph/physics/scenegraph-ragdoll.js +117 -0
- package/dist/graph/physics/scenegraph-ragdoll.js.map +1 -0
- package/dist/graph/tables/index.cjs.map +2 -2
- package/dist/index.cjs +3 -0
- package/dist/index.cjs.map +3 -3
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/lighting/ambient-occlusion-pass.cjs +3 -3
- package/dist/lighting/ambient-occlusion-pass.d.ts +2 -1
- package/dist/lighting/ambient-occlusion-pass.d.ts.map +1 -1
- package/dist/lighting/ambient-occlusion-pass.js +1 -1
- package/dist/lighting/ambient-occlusion-pass.js.map +1 -1
- package/dist/lighting/clustered-light-grid.d.ts +1 -1
- package/dist/lighting/clustered-light-grid.d.ts.map +1 -1
- package/dist/lighting/contact-shadow-pass.cjs +2 -2
- package/dist/lighting/contact-shadow-pass.d.ts +2 -1
- package/dist/lighting/contact-shadow-pass.d.ts.map +1 -1
- package/dist/lighting/contact-shadow-pass.js +1 -1
- package/dist/lighting/contact-shadow-pass.js.map +1 -1
- package/dist/lighting/index.cjs.map +2 -2
- package/dist/lighting/lightmap-atlas.cjs +6 -6
- package/dist/lighting/lightmap-atlas.d.ts +1 -1
- package/dist/lighting/lightmap-atlas.d.ts.map +1 -1
- package/dist/lighting/lightmap-atlas.js +1 -1
- package/dist/lighting/lightmap-atlas.js.map +1 -1
- package/dist/lighting/reflection-probe.cjs +4 -4
- package/dist/lighting/reflection-probe.d.ts +2 -1
- package/dist/lighting/reflection-probe.d.ts.map +1 -1
- package/dist/lighting/reflection-probe.js +1 -1
- package/dist/lighting/reflection-probe.js.map +1 -1
- package/dist/lighting/shadow-map-renderer.cjs +13 -13
- package/dist/lighting/shadow-map-renderer.d.ts +2 -2
- package/dist/lighting/shadow-map-renderer.d.ts.map +1 -1
- package/dist/lighting/shadow-map-renderer.js +1 -1
- package/dist/lighting/shadow-map-renderer.js.map +1 -1
- package/dist/model/gpu-vector-model.d.ts +1 -1
- package/dist/model/gpu-vector-model.d.ts.map +1 -1
- package/dist/model/model.d.ts +1 -1
- package/dist/model/model.d.ts.map +1 -1
- package/dist/models/light-model-utils.cjs +2 -2
- package/dist/models/light-model-utils.d.ts +1 -1
- package/dist/models/light-model-utils.d.ts.map +1 -1
- package/dist/models/light-model-utils.js +1 -1
- package/dist/models/light-model-utils.js.map +1 -1
- package/dist/modules/picking/color-picking.d.ts +1 -1
- package/dist/modules/picking/index-color-picking.d.ts +1 -1
- package/dist/modules/picking/index-picking.d.ts +1 -1
- package/dist/modules/picking/legacy-color-picking.d.ts +1 -1
- package/dist/modules/picking/picking-uniforms.d.ts +1 -1
- package/dist/modules/picking/picking-uniforms.d.ts.map +1 -1
- package/dist/modules/picking/picking.d.ts +1 -1
- package/dist/scenegraph/controllers/area-light-controller.cjs +11 -11
- package/dist/scenegraph/controllers/area-light-controller.js +1 -1
- package/dist/scenegraph/controllers/area-light-controller.js.map +1 -1
- package/dist/scenegraph/controllers/billboard-controller.cjs +28 -28
- package/dist/scenegraph/controllers/billboard-controller.d.ts +2 -1
- package/dist/scenegraph/controllers/billboard-controller.d.ts.map +1 -1
- package/dist/scenegraph/controllers/billboard-controller.js +1 -1
- package/dist/scenegraph/controllers/billboard-controller.js.map +1 -1
- package/dist/scenegraph/controllers/joint-controller.cjs +5 -5
- package/dist/scenegraph/controllers/joint-controller.js +1 -1
- package/dist/scenegraph/controllers/joint-controller.js.map +1 -1
- package/dist/scenegraph/controllers/punctual-light-controller.cjs +2 -2
- package/dist/scenegraph/controllers/punctual-light-controller.d.ts +1 -1
- package/dist/scenegraph/controllers/punctual-light-controller.d.ts.map +1 -1
- package/dist/scenegraph/controllers/punctual-light-controller.js +1 -1
- package/dist/scenegraph/controllers/punctual-light-controller.js.map +1 -1
- package/dist/scenegraph/controllers/skin-controller.cjs +22 -3
- package/dist/scenegraph/controllers/skin-controller.d.ts +4 -0
- package/dist/scenegraph/controllers/skin-controller.d.ts.map +1 -1
- package/dist/scenegraph/controllers/skin-controller.js +22 -2
- package/dist/scenegraph/controllers/skin-controller.js.map +1 -1
- package/dist/scenegraph/group-node.cjs +14 -14
- package/dist/scenegraph/group-node.d.ts +2 -2
- package/dist/scenegraph/group-node.d.ts.map +1 -1
- package/dist/scenegraph/group-node.js +1 -1
- package/dist/scenegraph/group-node.js.map +1 -1
- package/dist/scenegraph/model-node.d.ts +1 -1
- package/dist/scenegraph/model-node.d.ts.map +1 -1
- package/dist/scenegraph/physics-transforms.cjs +2 -2
- package/dist/scenegraph/physics-transforms.d.ts +1 -1
- package/dist/scenegraph/physics-transforms.d.ts.map +1 -1
- package/dist/scenegraph/physics-transforms.js +1 -1
- package/dist/scenegraph/physics-transforms.js.map +1 -1
- package/dist/scenegraph/scenegraph-bounds.cjs +3 -3
- package/dist/scenegraph/scenegraph-bounds.d.ts +1 -1
- package/dist/scenegraph/scenegraph-bounds.d.ts.map +1 -1
- package/dist/scenegraph/scenegraph-bounds.js +1 -1
- package/dist/scenegraph/scenegraph-bounds.js.map +1 -1
- package/dist/scenegraph/scenegraph-node.cjs +7 -7
- package/dist/scenegraph/scenegraph-node.d.ts +2 -1
- package/dist/scenegraph/scenegraph-node.d.ts.map +1 -1
- package/dist/scenegraph/scenegraph-node.js +1 -1
- package/dist/scenegraph/scenegraph-node.js.map +1 -1
- package/dist/scenegraph/transform-source.d.ts +1 -1
- package/dist/scenegraph/transform-source.d.ts.map +1 -1
- package/dist/shader-plugins/depth-interval.cjs +60 -0
- package/dist/shader-plugins/depth-interval.d.ts +10 -0
- package/dist/shader-plugins/depth-interval.d.ts.map +1 -0
- package/dist/shader-plugins/depth-interval.js +42 -0
- package/dist/shader-plugins/depth-interval.js.map +1 -0
- package/dist/splats/index.cjs.map +2 -2
- package/dist/splats/index.d.ts +1 -1
- package/dist/splats/index.d.ts.map +1 -1
- package/dist/splats/index.js.map +1 -1
- package/dist/splats/splat-picking.d.ts +2 -2
- package/dist/splats/splat-picking.d.ts.map +1 -1
- package/dist/splats/splat-renderer.cjs +51 -2
- package/dist/splats/splat-renderer.d.ts +15 -1
- package/dist/splats/splat-renderer.d.ts.map +1 -1
- package/dist/splats/splat-renderer.js +61 -2
- package/dist/splats/splat-renderer.js.map +1 -1
- package/dist/splats/splat-shaders.cjs +46 -3
- package/dist/splats/splat-shaders.d.ts +5 -3
- package/dist/splats/splat-shaders.d.ts.map +1 -1
- package/dist/splats/splat-shaders.js +42 -3
- package/dist/splats/splat-shaders.js.map +1 -1
- package/dist/text/text-3d/extrude.cjs +15 -15
- package/dist/text/text-3d/extrude.js +1 -1
- package/dist/text/text-3d/extrude.js.map +1 -1
- package/dist/text/text-3d/index.cjs.map +2 -2
- package/dist/text/text-3d/paths/curves.cjs +5 -5
- package/dist/text/text-3d/paths/curves.d.ts +1 -1
- package/dist/text/text-3d/paths/curves.d.ts.map +1 -1
- package/dist/text/text-3d/paths/curves.js +1 -1
- package/dist/text/text-3d/paths/curves.js.map +1 -1
- package/dist/text/text-3d/paths/path.cjs +5 -5
- package/dist/text/text-3d/paths/path.d.ts +1 -1
- package/dist/text/text-3d/paths/path.d.ts.map +1 -1
- package/dist/text/text-3d/paths/path.js +1 -1
- package/dist/text/text-3d/paths/path.js.map +1 -1
- package/dist/text/text-3d/paths/shape-path.d.ts +1 -1
- package/dist/text/text-3d/paths/shape-path.d.ts.map +1 -1
- package/dist/text/text-3d/paths/shape-utils.cjs +2 -2
- package/dist/text/text-3d/paths/shape-utils.d.ts +1 -1
- package/dist/text/text-3d/paths/shape-utils.d.ts.map +1 -1
- package/dist/text/text-3d/paths/shape-utils.js +1 -1
- package/dist/text/text-3d/paths/shape-utils.js.map +1 -1
- package/package.json +12 -12
- package/src/animation/deform-positions.ts +1 -1
- package/src/animation/skin.ts +2 -1
- package/src/animation/texture-transform.ts +1 -1
- package/src/arrow/arrow-geometry.ts +1 -1
- package/src/arrow/arrow-mesh-types.ts +1 -1
- package/src/arrow/renderers/path/conversion/arrow-path-storage-gpu-vectors.ts +1 -1
- package/src/arrow/renderers/path/transforms/gpu-path-float64-deltas.ts +1 -0
- package/src/arrow/renderers/polygon/renderers/arrow-polygon-renderer.ts +1 -1
- package/src/arrow/renderers/splats/conversion/make-gpu-splat-data-from-gltf.ts +1 -1
- package/src/audio/audio-controller.ts +1 -1
- package/src/audio/audio-environment.ts +1 -1
- package/src/compute/computation.ts +1 -1
- package/src/debug/pixel-data-utils.ts +1 -1
- package/src/effects/passes/screen-space/camera-reprojection-temporal-antialiasing.ts +1 -1
- package/src/effects/passes/screen-space/clustered-volumetric-lighting.ts +1 -1
- package/src/effects/passes/screen-space/gtao.ts +1 -1
- package/src/effects/passes/screen-space/height-fog.ts +1 -1
- package/src/effects/passes/screen-space/screen-space-global-illumination.ts +1 -1
- package/src/effects/passes/screen-space/screen-space-reflections.ts +1 -1
- package/src/effects/passes/screen-space/ssr-camera-temporal.ts +1 -1
- package/src/experimental/controls/index.ts +0 -2
- package/src/experimental/webxr/webxr-input.ts +1 -1
- package/{dist/experimental/controls/orbit-controls.js → src/experimental-controls.ts} +2 -2
- package/src/experimental-materials.ts +5 -0
- package/src/experimental-textures.ts +5 -0
- package/src/experimental-webxr.ts +5 -0
- package/src/geometry/edge-geometry.ts +2 -2
- package/src/geometry/geometry-primitives.ts +6 -3
- package/src/geometry/geometry-table.ts +1 -1
- package/src/geometry/geometry-utils.ts +3 -3
- package/src/geometry/geometry.ts +7 -7
- package/src/geometry/gpu-geometry.ts +1 -1
- package/src/geometry/gpu-vector-geometry-adapter.ts +1 -1
- package/src/geometry/ring-geometry.ts +2 -2
- package/src/gltf/gltf/create-composed-scenegraphs-from-gltf.ts +100 -0
- package/src/gltf/gltf/create-gltf-model.ts +1 -1
- package/src/gltf/gltf/create-scenegraph-from-gltf.ts +12 -0
- package/src/gltf/gltf/gltf-animated-crowd.ts +2 -1
- package/src/gltf/gltf/gltf-instancing.ts +1 -1
- package/src/gltf/gltf/gltf-lightmap.ts +1 -1
- package/src/gltf/gltf/gltf-skin.ts +2 -2
- package/src/gltf/index.ts +5 -0
- package/src/gltf/parsers/parse-gltf-lights.ts +1 -1
- package/src/gltf/parsers/parse-gltf-physics-pointer.ts +1 -1
- package/src/gltf/parsers/parse-gltf.ts +6 -4
- package/src/gltf/parsers/parse-pbr-material.ts +1 -1
- package/src/gltf/physics/README.md +16 -0
- package/src/gltf/physics/export-state.ts +216 -19
- package/src/gltf/physics/index.ts +1 -1
- package/src/gltf/physics/mesh-snapshot.ts +1 -1
- package/src/gltf/physics/node-collision-geometry.ts +1 -1
- package/src/gltf/physics/parse-gltf-physics.ts +6 -3
- package/src/gltf/physics/parse-physics-joints.ts +1 -1
- package/src/gltf/physics/physics-types.ts +4 -0
- package/src/gltf/physics/property-bindings.ts +11 -3
- package/src/gltf/types/gltf-postprocessed-schema.ts +4 -0
- package/src/gltf/types/gltf-types.ts +2 -0
- package/src/graph/models/path/path-storage-model.ts +3 -3
- package/src/graph/models/polygon/polygon-attribute-model.ts +1 -1
- package/src/graph/models/polygon/polygon-storage-model.ts +1 -1
- package/src/graph/physics/index.ts +2 -0
- package/src/graph/physics/physics-controller-geometry.ts +2 -2
- package/src/graph/physics/physics-controller.ts +139 -40
- package/src/graph/physics/physics-scenegraph.ts +1 -1
- package/src/graph/physics/scenegraph-instance.ts +25 -9
- package/src/graph/physics/scenegraph-motion.ts +1 -1
- package/src/graph/physics/scenegraph-properties.ts +1 -1
- package/src/graph/physics/scenegraph-publication.ts +1 -1
- package/src/graph/physics/scenegraph-ragdoll.ts +133 -0
- package/src/index.ts +2 -0
- package/src/lighting/ambient-occlusion-pass.ts +2 -1
- package/src/lighting/clustered-light-grid.ts +1 -1
- package/src/lighting/contact-shadow-pass.ts +2 -1
- package/src/lighting/lightmap-atlas.ts +1 -1
- package/src/lighting/reflection-probe.ts +2 -1
- package/src/lighting/shadow-map-renderer.ts +2 -2
- package/src/model/gpu-vector-model.ts +1 -1
- package/src/model/model.ts +1 -1
- package/src/models/light-model-utils.ts +2 -1
- package/src/modules/picking/legacy-picking-manager.ts +1 -1
- package/src/modules/picking/picking-uniforms.ts +1 -1
- package/src/scenegraph/controllers/area-light-controller.ts +1 -1
- package/src/scenegraph/controllers/billboard-controller.ts +2 -1
- package/src/scenegraph/controllers/joint-controller.ts +1 -1
- package/src/scenegraph/controllers/punctual-light-controller.ts +1 -1
- package/src/scenegraph/controllers/skin-controller.ts +21 -2
- package/src/scenegraph/group-node.ts +2 -2
- package/src/scenegraph/model-node.ts +1 -1
- package/src/scenegraph/physics-transforms.ts +1 -1
- package/src/scenegraph/scenegraph-bounds.ts +2 -2
- package/src/scenegraph/scenegraph-node.ts +2 -1
- package/src/scenegraph/transform-source.ts +1 -1
- package/src/shader-plugins/depth-interval.ts +45 -0
- package/src/splats/README.md +10 -0
- package/src/splats/index.ts +1 -0
- package/src/splats/splat-renderer.ts +82 -2
- package/src/splats/splat-shaders.ts +48 -3
- package/src/text/text-3d/extrude.ts +1 -1
- package/src/text/text-3d/font.ts +1 -1
- package/src/text/text-3d/paths/curves.ts +1 -1
- package/src/text/text-3d/paths/path.ts +1 -1
- package/src/text/text-3d/paths/shape-path.ts +1 -1
- package/src/text/text-3d/paths/shape-utils.ts +2 -2
- package/dist/experimental/controls/orbit-controls.d.ts +0 -3
- package/dist/experimental/controls/orbit-controls.d.ts.map +0 -1
- package/dist/experimental/controls/orbit-controls.js.map +0 -1
- package/src/experimental/controls/orbit-controls.ts +0 -6
|
@@ -157,6 +157,7 @@ export async function convertArrowPathFloat64ToGPUVector(
|
|
|
157
157
|
byteStride: componentCount * Float32Array.BYTES_PER_ELEMENT,
|
|
158
158
|
rowByteLength: componentCount * Float32Array.BYTES_PER_ELEMENT,
|
|
159
159
|
ownsBuffer: true,
|
|
160
|
+
valueOffsets,
|
|
160
161
|
readbackMetadata: {
|
|
161
162
|
kind: 'variable-length-attribute',
|
|
162
163
|
valueOffsets,
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
type PolygonShaderInputs,
|
|
13
13
|
type PolygonStorageModelProps
|
|
14
14
|
} from '@luma.gl/engine/models';
|
|
15
|
-
import {type PolygonBatchProps} from '@luma.gl/graph/experimental
|
|
15
|
+
import {type PolygonBatchProps} from '@luma.gl/graph/experimental-models';
|
|
16
16
|
import {DataType, RecordBatch, Table, Uint8, Vector} from 'apache-arrow';
|
|
17
17
|
import {canConvertColors} from '@luma.gl/graph/arrow';
|
|
18
18
|
import {convertArrowToGPUVector} from '@luma.gl/graph/arrow';
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import type {Device} from '@luma.gl/core';
|
|
6
6
|
import {GroupNode} from '@luma.gl/engine';
|
|
7
|
-
import {Matrix4} from '@math.gl/core';
|
|
7
|
+
import {Matrix4} from '@math.gl/core/matrix';
|
|
8
8
|
import {getGLTFNodeInstancing} from '../../../../gltf/gltf/gltf-instancing';
|
|
9
9
|
import {makeVector} from 'apache-arrow';
|
|
10
10
|
import type {GLTFPostprocessed} from '@luma.gl/engine/gltf';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
|
|
5
5
|
import {assert} from '@luma.gl/core';
|
|
6
|
-
import {Matrix4, Vector3} from '@math.gl/core';
|
|
6
|
+
import {Matrix4, Vector3} from '@math.gl/core/matrix';
|
|
7
7
|
import type {GroupNode} from '../scenegraph/group-node';
|
|
8
8
|
import {AudioGraph, type AudioGraphDefinition} from './audio-graph';
|
|
9
9
|
import {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// SPDX-License-Identifier: MIT
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
|
|
5
|
-
import {Matrix4} from '@math.gl/core';
|
|
5
|
+
import {Matrix4} from '@math.gl/core/matrix';
|
|
6
6
|
import {assert} from '@luma.gl/core';
|
|
7
7
|
|
|
8
8
|
export type AudioEnvironmentZone = {
|
|
@@ -26,7 +26,7 @@ import {
|
|
|
26
26
|
ShaderAssembler
|
|
27
27
|
} from '@luma.gl/shaders';
|
|
28
28
|
import {WGSLShaderAssembler} from '@luma.gl/shaders/wgsl';
|
|
29
|
-
import type {TypedArray} from '@math.gl/core';
|
|
29
|
+
import type {TypedArray} from '@math.gl/core/types';
|
|
30
30
|
import {isUniformValue} from '../model/split-uniforms-and-bindings';
|
|
31
31
|
import {ShaderInputs} from '../shader-inputs';
|
|
32
32
|
import {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// SPDX-License-Identifier: MIT
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
|
|
5
|
-
import {TypedArray} from '@math.gl/core';
|
|
5
|
+
import {TypedArray} from '@math.gl/core/types';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
8
|
* Flip rows (can be used on arrays returned from `Framebuffer.readPixels`)
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import type {Texture} from '@luma.gl/core';
|
|
6
6
|
import type {ShaderPass, CompositeShaderPass} from '@luma.gl/shaders';
|
|
7
|
-
import type {NumberArray16} from '@math.gl/core';
|
|
7
|
+
import type {NumberArray16} from '@math.gl/core/types';
|
|
8
8
|
import {copyPass} from './copy-pass';
|
|
9
9
|
import {temporalHelpers} from './screen-space-shader-helpers';
|
|
10
10
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import type {Buffer, Texture} from '@luma.gl/core';
|
|
6
6
|
import type {ShaderPass, CompositeShaderPass} from '@luma.gl/shaders';
|
|
7
|
-
import type {NumberArray3, NumberArray16} from '@math.gl/core';
|
|
7
|
+
import type {NumberArray3, NumberArray16} from '@math.gl/core/types';
|
|
8
8
|
import {depthAwareBlur} from './depth-aware-blur';
|
|
9
9
|
|
|
10
10
|
/** Construction options for clustered participating-media integration. */
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import type {Texture} from '@luma.gl/core';
|
|
6
6
|
import type {ShaderPass, CompositeShaderPass} from '@luma.gl/shaders';
|
|
7
|
-
import {Matrix4} from '@math.gl/core';
|
|
7
|
+
import {Matrix4} from '@math.gl/core/matrix';
|
|
8
8
|
import {depthAwareBlur} from './depth-aware-blur';
|
|
9
9
|
|
|
10
10
|
/** Construction options for the horizon-based GTAO pipeline. */
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import type {Texture} from '@luma.gl/core';
|
|
6
6
|
import type {ShaderPass, CompositeShaderPass} from '@luma.gl/shaders';
|
|
7
|
-
import type {NumberArray16} from '@math.gl/core';
|
|
7
|
+
import type {NumberArray16} from '@math.gl/core/types';
|
|
8
8
|
|
|
9
9
|
/** Construction options for temporally stabilized diffuse screen-space global illumination. */
|
|
10
10
|
export type SSGICompositeShaderPassOptions = {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import type {Texture} from '@luma.gl/core';
|
|
6
6
|
import type {ShaderPass, CompositeShaderPass} from '@luma.gl/shaders';
|
|
7
|
-
import type {NumberArray16} from '@math.gl/core';
|
|
7
|
+
import type {NumberArray16} from '@math.gl/core/types';
|
|
8
8
|
import {temporalHelpers} from './screen-space-shader-helpers';
|
|
9
9
|
import {
|
|
10
10
|
ssrCameraTemporal,
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import type {Texture} from '@luma.gl/core';
|
|
6
6
|
import type {ShaderPass} from '@luma.gl/shaders';
|
|
7
|
-
import type {NumberArray16} from '@math.gl/core';
|
|
7
|
+
import type {NumberArray16} from '@math.gl/core/types';
|
|
8
8
|
import {temporalHelpers} from './screen-space-shader-helpers';
|
|
9
9
|
|
|
10
10
|
export type SSRCameraTemporalUniforms = {
|
|
@@ -4,8 +4,6 @@
|
|
|
4
4
|
|
|
5
5
|
export type {ComparisonSplitterProps} from './comparison-splitter';
|
|
6
6
|
export {ComparisonSplitter} from './comparison-splitter';
|
|
7
|
-
export type {OrbitControlsProps, OrbitPosition} from './orbit-controls';
|
|
8
|
-
export {OrbitControls} from './orbit-controls';
|
|
9
7
|
export type {
|
|
10
8
|
FlatControllerPick,
|
|
11
9
|
FlatControllerProps,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// SPDX-License-Identifier: MIT
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
|
|
5
|
-
import type {NumberArray3} from '@math.gl/core';
|
|
5
|
+
import type {NumberArray3} from '@math.gl/core/types';
|
|
6
6
|
import type {WebXRInputState} from './webxr-manager';
|
|
7
7
|
|
|
8
8
|
/** Experimental v10 world-space target ray derived from one WebXR input source. */
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
|
|
5
5
|
import {assert} from '@luma.gl/core';
|
|
6
|
-
import type {TypedArray} from '@math.gl/core';
|
|
7
|
-
import type {Geometry as MathGeometry} from '@math.gl/geometry';
|
|
6
|
+
import type {TypedArray} from '@math.gl/core/types';
|
|
7
|
+
import type {Geometry as MathGeometry} from '@math.gl/geometry/primitives';
|
|
8
8
|
import {Geometry, type GeometryAttribute} from './geometry';
|
|
9
9
|
|
|
10
10
|
export type MakeEdgeGeometryOptions = {
|
|
@@ -8,14 +8,17 @@ import {
|
|
|
8
8
|
IcoSphereGeometry as MathIcoSphereGeometry,
|
|
9
9
|
PlaneGeometry as MathPlaneGeometry,
|
|
10
10
|
TruncatedConeGeometry as MathTruncatedConeGeometry,
|
|
11
|
-
unpackIndexedGeometry,
|
|
12
11
|
type Geometry as MathGeometry,
|
|
13
12
|
type GeometryAttributeInput,
|
|
14
13
|
type SphereGeometryProps,
|
|
15
14
|
type IcoSphereGeometryProps,
|
|
16
15
|
type TruncatedConeGeometryProps
|
|
17
|
-
} from '@math.gl/geometry';
|
|
18
|
-
import {
|
|
16
|
+
} from '@math.gl/geometry/primitives';
|
|
17
|
+
import {unpackIndexedGeometry} from '@math.gl/geometry/processing';
|
|
18
|
+
import {
|
|
19
|
+
TorusGeometry as MathTorusGeometry,
|
|
20
|
+
type TorusGeometryProps
|
|
21
|
+
} from '@math.gl/geometry/primitives';
|
|
19
22
|
import {Geometry} from './geometry';
|
|
20
23
|
|
|
21
24
|
export type {TorusGeometryProps};
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// SPDX-License-Identifier: MIT
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
|
|
5
|
-
import type {TypedArray} from '@math.gl/core';
|
|
5
|
+
import type {TypedArray} from '@math.gl/core/types';
|
|
6
6
|
import type {VertexFormat} from '@luma.gl/core';
|
|
7
7
|
|
|
8
8
|
/** Holds one geometry */
|
|
@@ -4,9 +4,9 @@
|
|
|
4
4
|
|
|
5
5
|
import type {BufferLayout, VertexFormat} from '@luma.gl/core';
|
|
6
6
|
import {vertexFormatDecoder} from '@luma.gl/core';
|
|
7
|
-
import type {TypedArray} from '@math.gl/core';
|
|
8
|
-
import type {Geometry as MathGeometry} from '@math.gl/geometry';
|
|
9
|
-
export {unpackIndexedGeometry} from '@math.gl/geometry';
|
|
7
|
+
import type {TypedArray} from '@math.gl/core/types';
|
|
8
|
+
import type {Geometry as MathGeometry} from '@math.gl/geometry/primitives';
|
|
9
|
+
export {unpackIndexedGeometry} from '@math.gl/geometry/processing';
|
|
10
10
|
import {Geometry, getGeometryShaderAttributeName, type GeometryAttribute} from './geometry';
|
|
11
11
|
|
|
12
12
|
type TypedArrayConstructor = {
|
package/src/geometry/geometry.ts
CHANGED
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
// SPDX-License-Identifier: MIT
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
|
|
5
|
-
import {
|
|
5
|
+
import {
|
|
6
|
+
Geometry as MathGeometry,
|
|
7
|
+
type GeometryProps as MathGeometryProps
|
|
8
|
+
} from '@math.gl/geometry/primitives';
|
|
6
9
|
import type {BufferLayout} from '@luma.gl/core';
|
|
7
10
|
import {vertexFormatDecoder} from '@luma.gl/core';
|
|
8
|
-
import type {GeometryAttribute} from '@math.gl/geometry';
|
|
11
|
+
import type {GeometryAttribute} from '@math.gl/geometry/primitives';
|
|
9
12
|
|
|
10
|
-
export type {
|
|
11
|
-
|
|
12
|
-
GeometryAttributeInput,
|
|
13
|
-
GeometryAttributes
|
|
14
|
-
} from '@math.gl/geometry';
|
|
13
|
+
export type {GeometryAttribute} from '@math.gl/geometry/primitives';
|
|
14
|
+
export type {GeometryAttributeInput, GeometryAttributes} from '@math.gl/geometry/primitives';
|
|
15
15
|
|
|
16
16
|
/** Legacy engine geometry properties, including caller-owned shader layout metadata. */
|
|
17
17
|
export type GeometryProps = MathGeometryProps & {bufferLayout?: BufferLayout[]};
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import type {PrimitiveTopology, BufferLayout} from '@luma.gl/core';
|
|
6
6
|
import {Device, Buffer} from '@luma.gl/core';
|
|
7
|
-
import type {Geometry} from '@math.gl/geometry';
|
|
7
|
+
import type {Geometry} from '@math.gl/geometry/primitives';
|
|
8
8
|
import {getBufferLayoutFromGeometryAttributes, getGeometryShaderAttributeName} from './geometry';
|
|
9
9
|
import {makeInterleavedGeometry} from './geometry-utils';
|
|
10
10
|
import {uid} from '../utils/uid';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
|
|
5
5
|
import type {Device} from '@luma.gl/core';
|
|
6
|
-
import type {Geometry} from '@math.gl/geometry';
|
|
6
|
+
import type {Geometry} from '@math.gl/geometry/primitives';
|
|
7
7
|
import {vertexFormatDecoder} from '@luma.gl/core';
|
|
8
8
|
import type {GPUVectorModelInput} from '../model/gpu-vector-model-batches';
|
|
9
9
|
import {GPUGeometry, makeGPUGeometry} from './gpu-geometry';
|
|
@@ -6,8 +6,8 @@ import {
|
|
|
6
6
|
PlaneGeometry as MathPlaneGeometry,
|
|
7
7
|
type Geometry as MathGeometry,
|
|
8
8
|
type GeometryAttributeInput
|
|
9
|
-
} from '@math.gl/geometry';
|
|
10
|
-
import {LatheGeometry} from '@math.gl/geometry';
|
|
9
|
+
} from '@math.gl/geometry/primitives';
|
|
10
|
+
import {LatheGeometry} from '@math.gl/geometry/primitives';
|
|
11
11
|
import {Geometry} from './geometry';
|
|
12
12
|
|
|
13
13
|
export type RingGeometryProps = {
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
// luma.gl
|
|
2
|
+
// SPDX-License-Identifier: MIT
|
|
3
|
+
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
|
+
|
|
5
|
+
import type {Device} from '@luma.gl/core';
|
|
6
|
+
import type {GroupNode} from '../../scenegraph/group-node';
|
|
7
|
+
import type {GLTFWithBuffers} from '../types/gltf-types';
|
|
8
|
+
import {postProcessGLTF} from '../parsers/post-process-gltf';
|
|
9
|
+
import type {ParseGLTFOptions} from '../parsers/parse-gltf';
|
|
10
|
+
import {createScenegraphsFromGLTF, type GLTFScenegraphs} from './create-scenegraph-from-gltf';
|
|
11
|
+
|
|
12
|
+
/** One independently instantiated glTF document in the composed tree. */
|
|
13
|
+
export type GLTFSceneInstance = {
|
|
14
|
+
/** The document's own scenegraph, animation, joint and skin controllers. */
|
|
15
|
+
readonly scenegraphs: GLTFScenegraphs;
|
|
16
|
+
/** Decoded source with original document-local indices. */
|
|
17
|
+
readonly source: GLTFWithBuffers;
|
|
18
|
+
/** Selected scene container; its root nodes are mounted under the referencing node. */
|
|
19
|
+
readonly scene: GroupNode;
|
|
20
|
+
/** The node that references this instance, or null for the root document. */
|
|
21
|
+
readonly mount: GroupNode | null;
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
/** An owned scene composition with independent document-local runtime instances. */
|
|
25
|
+
export type GLTFSceneComposition = {
|
|
26
|
+
/** Root scene and its source document. */
|
|
27
|
+
readonly root: GLTFSceneInstance;
|
|
28
|
+
/** Runtime instances in the order their mounts were resolved. */
|
|
29
|
+
readonly instances: readonly GLTFSceneInstance[];
|
|
30
|
+
/** Detach and dispose all scenegraph instances exactly once. */
|
|
31
|
+
destroy(): void;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
/** Instantiate decoded glTF 2.1 external assets using the normal scenegraph parser. */
|
|
35
|
+
export function createComposedScenegraphsFromGLTF(
|
|
36
|
+
device: Device,
|
|
37
|
+
source: GLTFWithBuffers,
|
|
38
|
+
options?: ParseGLTFOptions
|
|
39
|
+
): GLTFSceneComposition {
|
|
40
|
+
/** Own each runtime instance once, even when decoded resources are shared. */
|
|
41
|
+
const instances: GLTFSceneInstance[] = [];
|
|
42
|
+
/** Reuse postprocessing for repeated references while keeping their runtime state separate. */
|
|
43
|
+
const documents = new Map<GLTFWithBuffers, ReturnType<typeof postProcessGLTF>>();
|
|
44
|
+
/** Protect callers that supply a manually linked document graph. */
|
|
45
|
+
const ancestors = new Set<GLTFWithBuffers>();
|
|
46
|
+
|
|
47
|
+
/** Detach each nested scene before destroying the render resources it owns. */
|
|
48
|
+
const destroy = () => {
|
|
49
|
+
for (const {mount, scene, scenegraphs} of instances.splice(0).reverse()) {
|
|
50
|
+
if (mount) for (const node of scene.children) mount.remove(node);
|
|
51
|
+
scenegraphs.destroy();
|
|
52
|
+
}
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
/** Select each asset's scene and mount separate runtime instances for references in that scene. */
|
|
56
|
+
const instantiate = (asset: GLTFWithBuffers, mount: GroupNode | null): GLTFSceneInstance => {
|
|
57
|
+
if (ancestors.has(asset)) throw new Error('glTF external asset cycle');
|
|
58
|
+
if (ancestors.size >= 64) throw new Error('glTF external asset nesting exceeds 64 documents');
|
|
59
|
+
ancestors.add(asset);
|
|
60
|
+
/** Retain original source indices for physics, animation pointers and nested asset references. */
|
|
61
|
+
const document = documents.get(asset) ?? postProcessGLTF(asset);
|
|
62
|
+
documents.set(asset, document);
|
|
63
|
+
/** Only mount an asset's default scene, or its first scene if none is named. */
|
|
64
|
+
const sceneIndex = asset.json.scene ?? 0;
|
|
65
|
+
if (!document.scenes[sceneIndex]) throw new Error('glTF external asset has no selected scene');
|
|
66
|
+
/** Keep document-local physics and animation binding scope for each instance. */
|
|
67
|
+
const scenegraphs = createScenegraphsFromGLTF(device, document, options);
|
|
68
|
+
/** The selected scene can be linked only after parsing its independent runtime bundle. */
|
|
69
|
+
const scene = scenegraphs.scenes[sceneIndex];
|
|
70
|
+
/** Track ownership before mounting so failure can always dispose this instance. */
|
|
71
|
+
const instance = {scenegraphs, source: asset, scene, mount};
|
|
72
|
+
instances.push(instance);
|
|
73
|
+
mount?.add(scene.children);
|
|
74
|
+
|
|
75
|
+
/** Snapshot reachable nodes before external scenes are attached. */
|
|
76
|
+
const reachable = new Set<object>();
|
|
77
|
+
scene.preorderTraversal(node => reachable.add(node));
|
|
78
|
+
for (const [index, node] of scenegraphs.gltfNodeIndexToNodeMap) {
|
|
79
|
+
/** External-asset indices are scoped to the referencing document. */
|
|
80
|
+
const externalIndex = asset.json.nodes?.[index]?.externalAsset;
|
|
81
|
+
if (externalIndex === undefined || !reachable.has(node)) continue;
|
|
82
|
+
/** Decoding belongs to the loader, including URI alias and embedded buffer handling. */
|
|
83
|
+
const external = asset.externalAssets?.[externalIndex];
|
|
84
|
+
if (!external) throw new Error(`glTF external asset ${externalIndex} is unresolved`);
|
|
85
|
+
// The draft defines a scene-less or default-less reference as having no children to attach.
|
|
86
|
+
if (external.json.scene !== undefined) instantiate(external, node);
|
|
87
|
+
}
|
|
88
|
+
ancestors.delete(asset);
|
|
89
|
+
return instance;
|
|
90
|
+
};
|
|
91
|
+
|
|
92
|
+
try {
|
|
93
|
+
/** Establish one disposal boundary for the root and all nested instances. */
|
|
94
|
+
const root = instantiate(source, null);
|
|
95
|
+
return {root, instances, destroy};
|
|
96
|
+
} catch (error) {
|
|
97
|
+
destroy();
|
|
98
|
+
throw error;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
@@ -26,7 +26,7 @@ import {
|
|
|
26
26
|
} from '@luma.gl/engine';
|
|
27
27
|
import {DynamicTexture} from '@luma.gl/core/dynamic';
|
|
28
28
|
import {gpuAnimation, pbrMaterial, skin} from '@luma.gl/shaders';
|
|
29
|
-
import type {NumericArray} from '@math.gl/core';
|
|
29
|
+
import type {NumericArray} from '@math.gl/core/types';
|
|
30
30
|
import {type ParsedPBRMaterial} from '../pbr/pbr-material';
|
|
31
31
|
import type {GLTFCrowdGPUAnimationLayout} from './gltf-gpu-animation';
|
|
32
32
|
|
|
@@ -106,6 +106,11 @@ export function createScenegraphsFromGLTF(
|
|
|
106
106
|
assertSupportedGLTFExtensions(gltf, device);
|
|
107
107
|
}
|
|
108
108
|
|
|
109
|
+
for (const node of gltf.nodes) {
|
|
110
|
+
if (node.boundingVolume && !gltf.shapes?.[node.boundingVolume.shape])
|
|
111
|
+
throw new Error('glTF boundingVolume refers to a missing shape');
|
|
112
|
+
}
|
|
113
|
+
|
|
109
114
|
// Validate the optional profile before parseGLTF allocates models, textures, or buffers.
|
|
110
115
|
if (options?.billboards) {
|
|
111
116
|
const validationNodes = new Map<number, GroupNode>();
|
|
@@ -160,6 +165,13 @@ export function createScenegraphsFromGLTF(
|
|
|
160
165
|
gltfNodeIndexToNodeMap.forEach((node, index) => {
|
|
161
166
|
const packet = metadata.get('node', index);
|
|
162
167
|
if (packet) node.metadata['xmp'] = packet;
|
|
168
|
+
/** Bounds are source metadata; they never create a collider implicitly. */
|
|
169
|
+
const volume = gltf.nodes[index]?.boundingVolume;
|
|
170
|
+
if (volume) {
|
|
171
|
+
/** Resolve the same source shape index that can be referenced by physics. */
|
|
172
|
+
const shape = gltf.shapes![volume.shape];
|
|
173
|
+
node.metadata['boundingVolume'] = structuredClone({volume, shape});
|
|
174
|
+
}
|
|
163
175
|
if (!meshPackets.size) return;
|
|
164
176
|
const sourceMesh = gltf.nodes[index]?.mesh;
|
|
165
177
|
const meshPacket = sourceMesh && meshPackets.get(sourceMesh.id);
|
|
@@ -12,7 +12,8 @@ import {
|
|
|
12
12
|
ModelNode,
|
|
13
13
|
updateSkinJointMatrices
|
|
14
14
|
} from '@luma.gl/engine';
|
|
15
|
-
import {Matrix4
|
|
15
|
+
import {Matrix4} from '@math.gl/core/matrix';
|
|
16
|
+
import {type NumericArray} from '@math.gl/core/types';
|
|
16
17
|
import type {ParseGLTFOptions} from '../parsers/parse-gltf';
|
|
17
18
|
import type {GLTFCrowdModelConfiguration, GLTFCrowdModelResources} from './create-gltf-model';
|
|
18
19
|
import {createScenegraphsFromGLTF, type GLTFScenegraphs} from './create-scenegraph-from-gltf';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
|
|
5
5
|
import type {GLTFNodePostprocessed, GLTFPostprocessed} from '../types/gltf-postprocessed-schema';
|
|
6
|
-
import {Matrix4} from '@math.gl/core';
|
|
6
|
+
import {Matrix4} from '@math.gl/core/matrix';
|
|
7
7
|
|
|
8
8
|
/** Accessor values authored on an `EXT_mesh_gpu_instancing` node. */
|
|
9
9
|
export type GLTFInstanceAttribute = {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
|
|
5
5
|
import {assert} from '@luma.gl/core';
|
|
6
|
-
import {Matrix3} from '@math.gl/core';
|
|
6
|
+
import {Matrix3} from '@math.gl/core/matrix';
|
|
7
7
|
import type {GLTFGPUInstancing} from './gltf-instancing';
|
|
8
8
|
import {
|
|
9
9
|
getTextureTransformMatrix,
|
|
@@ -79,8 +79,8 @@ function makeSkinBindings(props: ParseGLTFSkinsProps): SkinBinding[] {
|
|
|
79
79
|
const inverseBindMatrices = sourceSkin.inverseBindMatrices?.value;
|
|
80
80
|
const jointMatrices = new Float32Array(joints.length * 16);
|
|
81
81
|
const usesLargeSkinPalette =
|
|
82
|
-
|
|
83
|
-
|
|
82
|
+
models.some(modelNode => modelNode.userData['gltfLargeSkinPalette'] === true) &&
|
|
83
|
+
(props.device.type === 'webgpu' || joints.length > SKIN_MAX_JOINTS);
|
|
84
84
|
let skinJointMatrices: Buffer | Texture | undefined;
|
|
85
85
|
if (usesLargeSkinPalette) {
|
|
86
86
|
skinJointMatrices = createSkinJointPaletteResource(props.device, node.id, jointMatrices);
|
package/src/gltf/index.ts
CHANGED
|
@@ -18,6 +18,11 @@ export {
|
|
|
18
18
|
type GLTFScenegraphBounds,
|
|
19
19
|
type GLTFScenegraphs
|
|
20
20
|
} from './gltf/create-scenegraph-from-gltf';
|
|
21
|
+
export {
|
|
22
|
+
createComposedScenegraphsFromGLTF,
|
|
23
|
+
type GLTFSceneComposition,
|
|
24
|
+
type GLTFSceneInstance
|
|
25
|
+
} from './gltf/create-composed-scenegraphs-from-gltf';
|
|
21
26
|
export {
|
|
22
27
|
GLTFAnimationClip,
|
|
23
28
|
type GLTFAnimationClipProps,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// SPDX-License-Identifier: MIT
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
|
|
5
|
-
import {Matrix4} from '@math.gl/core';
|
|
5
|
+
import {Matrix4} from '@math.gl/core/matrix';
|
|
6
6
|
import type {GLTFNodePostprocessed, GLTFPostprocessed} from '../types/gltf-postprocessed-schema';
|
|
7
7
|
import type {Light} from '@luma.gl/shaders';
|
|
8
8
|
import {
|
|
@@ -16,7 +16,7 @@ export function isGLTFPhysicsPropertyPointer(pointer: string): boolean {
|
|
|
16
16
|
if (Number(component[2]) < size) return isGLTFPhysicsPropertyPointer(component[1]);
|
|
17
17
|
}
|
|
18
18
|
return (
|
|
19
|
-
|
|
19
|
+
/^(?:\/extensions\/KHR_implicit_shapes)?\/shapes\/\d+\/(sphere\/radius|box\/size|(?:capsule|cylinder)\/(height|radiusBottom|radiusTop)|plane\/(sizeX|sizeZ|doubleSided))$/.test(
|
|
20
20
|
pointer
|
|
21
21
|
) ||
|
|
22
22
|
/^\/nodes\/\d+\/extensions\/KHR_physics_rigid_bodies\/(motion\/(isKinematic|mass|centerOfMass|inertiaDiagonal|inertiaOrientation|linearVelocity|angularVelocity|gravityFactor)|joint\/enableCollision)$/.test(
|
|
@@ -48,6 +48,8 @@ export type ParseGLTFOptions = {
|
|
|
48
48
|
properties?: import('@luma.gl/engine').InteractivityPropertyAdapter | null;
|
|
49
49
|
/** Borrowed rigid GPU matrices. The renderer selects a body and local transform per draw. */
|
|
50
50
|
publishedTransforms?: Buffer | null;
|
|
51
|
+
/** Compile skinned meshes for a storage palette, including small WebGPU rigs. */
|
|
52
|
+
storageSkinPalettes?: boolean;
|
|
51
53
|
/** Additional model props applied to each generated primitive model. */
|
|
52
54
|
modelOptions?: Partial<ModelProps>;
|
|
53
55
|
/** Enables shader-level PBR debug output. */
|
|
@@ -83,6 +85,7 @@ const defaultOptions: Required<ParseGLTFOptions> = {
|
|
|
83
85
|
properties: null,
|
|
84
86
|
billboards: null,
|
|
85
87
|
publishedTransforms: null,
|
|
88
|
+
storageSkinPalettes: false,
|
|
86
89
|
modelOptions: {},
|
|
87
90
|
pbrDebug: false,
|
|
88
91
|
imageBasedLightingEnvironment: undefined!,
|
|
@@ -459,10 +462,9 @@ function createNodeForGLTFPrimitive({
|
|
|
459
462
|
vertexCount,
|
|
460
463
|
bounds: [gltfPrimitive.attributes.POSITION.min, gltfPrimitive.attributes.POSITION.max],
|
|
461
464
|
instanceMatrices: instancing?.matrices,
|
|
462
|
-
usesLargeSkinPalette:
|
|
463
|
-
|
|
464
|
-
gltfPrimitive.attributes.JOINTS_1
|
|
465
|
-
),
|
|
465
|
+
usesLargeSkinPalette:
|
|
466
|
+
(options.storageSkinPalettes && device.type === 'webgpu') ||
|
|
467
|
+
usesLargeSkinPalette(gltfPrimitive.attributes.JOINTS_0, gltfPrimitive.attributes.JOINTS_1),
|
|
466
468
|
morphTargets: morphTargetState?.targets
|
|
467
469
|
});
|
|
468
470
|
|
|
@@ -15,7 +15,7 @@ export type {
|
|
|
15
15
|
CompressedImageMipmapArray,
|
|
16
16
|
CompressedMipLevel
|
|
17
17
|
} from '../types/gltf-types';
|
|
18
|
-
import {Matrix3} from '@math.gl/core';
|
|
18
|
+
import {Matrix3} from '@math.gl/core/matrix';
|
|
19
19
|
import type {Device, ExternalImage, SamplerProps, TextureFormat} from '@luma.gl/core';
|
|
20
20
|
import {assert, log, Texture, textureFormatDecoder} from '@luma.gl/core';
|
|
21
21
|
import {type PBRMaterialBindings} from '@luma.gl/shaders';
|
|
@@ -162,3 +162,19 @@ Collision snapshots reject repeated subtree references and cap the flattened out
|
|
|
162
162
|
at one million vertices and three million indices. Accessor counts obey the same
|
|
163
163
|
bounds before allocating decoded arrays. Indexed snapshots discard unused vertices
|
|
164
164
|
before convex-hull cooking, including snapshots supplied by custom resolvers.
|
|
165
|
+
|
|
166
|
+
|
|
167
|
+
### Export a settled authored revision
|
|
168
|
+
|
|
169
|
+
Use `exportGLTFPhysicsState(source, description, world, {sceneNodes})` with the
|
|
170
|
+
same node map used to create the live scene session. Use `session.withWorld`
|
|
171
|
+
to serialize export against simulation, reset, and rebuild. The exporter
|
|
172
|
+
takes body poses and velocities from the accepted GPU state, restores the
|
|
173
|
+
world origin, and retains the current authored collider frames and sizes.
|
|
174
|
+
Shared analytic shapes remain shared. Animated nodes retain TRS fields so
|
|
175
|
+
existing channels still work.
|
|
176
|
+
|
|
177
|
+
Keep the source description and node map from the same session revision.
|
|
178
|
+
The exporter rejects a mismatch between the authored transforms and the live
|
|
179
|
+
collider frames. Recook mesh deformation and topology edits before exporting.
|
|
180
|
+
Export performs an explicit readback outside the normal render and simulation loop.
|