@nova-lab/core 1.0.0-dev.19 → 1.1.1-dev.229
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/README.md +1035 -10
- package/THIRD_PARTY_NOTICES.md +26 -0
- package/dist/2d/accessibility.d.ts +2 -0
- package/dist/2d/accessibility.js +171 -0
- package/dist/2d/commands.d.ts +2 -0
- package/dist/2d/commands.js +80 -0
- package/dist/2d/effects.d.ts +10 -0
- package/dist/2d/effects.js +566 -0
- package/dist/2d/ktx2.d.ts +5 -0
- package/dist/2d/ktx2.js +542 -0
- package/dist/2d/lighting.d.ts +3 -0
- package/dist/2d/lighting.js +495 -0
- package/dist/2d/lottie.d.ts +3 -0
- package/dist/2d/lottie.js +254 -0
- package/dist/2d/meshes.d.ts +4 -0
- package/dist/2d/meshes.js +451 -0
- package/dist/2d/primitives.d.ts +3 -0
- package/dist/2d/primitives.js +85 -0
- package/dist/2d/render-textures.d.ts +3 -0
- package/dist/2d/render-textures.js +539 -0
- package/dist/2d/svg/documents.d.ts +5 -0
- package/dist/2d/svg/documents.js +7 -0
- package/dist/2d/svg/renderer.d.ts +3 -0
- package/dist/2d/svg/renderer.js +222 -0
- package/dist/2d/svg.d.ts +3 -0
- package/dist/2d/svg.js +4 -0
- package/dist/2d/tools.d.ts +2 -0
- package/dist/2d/tools.js +100 -0
- package/dist/2d/video.d.ts +5 -0
- package/dist/2d/video.js +90 -0
- package/dist/2d.d.ts +2 -0
- package/dist/2d.js +220 -0
- package/dist/3d/animation.d.ts +8 -0
- package/dist/3d/animation.js +1396 -0
- package/dist/3d/area-lights.d.ts +2 -0
- package/dist/3d/area-lights.js +19 -0
- package/dist/3d/audio.d.ts +4 -0
- package/dist/3d/audio.js +500 -0
- package/dist/3d/character.d.ts +2 -0
- package/dist/3d/character.js +136 -0
- package/dist/3d/collision.d.ts +3 -0
- package/dist/3d/collision.js +387 -0
- package/dist/3d/commands.d.ts +2 -0
- package/dist/3d/commands.js +108 -0
- package/dist/3d/controls.d.ts +8 -0
- package/dist/3d/controls.js +1041 -0
- package/dist/3d/documents.d.ts +5 -0
- package/dist/3d/documents.js +227 -0
- package/dist/3d/effects.d.ts +5 -0
- package/dist/3d/effects.js +1986 -0
- package/dist/3d/export.d.ts +4 -0
- package/dist/3d/export.js +347 -0
- package/dist/3d/fbx.d.ts +2 -0
- package/dist/3d/fbx.js +784 -0
- package/dist/3d/gltf.d.ts +2 -0
- package/dist/3d/gltf.js +5 -0
- package/dist/3d/helpers.d.ts +5 -0
- package/dist/3d/helpers.js +191 -0
- package/dist/3d/ik.d.ts +9 -0
- package/dist/3d/ik.js +777 -0
- package/dist/3d/loaders.d.ts +17 -0
- package/dist/3d/loaders.js +1406 -0
- package/dist/3d/nodes.d.ts +8 -0
- package/dist/3d/nodes.js +49 -0
- package/dist/3d/particles.d.ts +5 -0
- package/dist/3d/particles.js +1574 -0
- package/dist/3d/physics/backend.d.ts +7 -0
- package/dist/3d/physics/backend.js +1 -0
- package/dist/3d/physics/rapier.d.ts +3 -0
- package/dist/3d/physics/rapier.js +765 -0
- package/dist/3d/physics.d.ts +5 -0
- package/dist/3d/physics.js +3346 -0
- package/dist/3d/splats.d.ts +7 -0
- package/dist/3d/splats.js +862 -0
- package/dist/3d/text.d.ts +5 -0
- package/dist/3d/text.js +1043 -0
- package/dist/3d/tiles.d.ts +24 -0
- package/dist/3d/tiles.js +1705 -0
- package/dist/3d/tools.d.ts +12 -0
- package/dist/3d/tools.js +338 -0
- package/dist/3d/usdz.d.ts +2 -0
- package/dist/3d/usdz.js +634 -0
- package/dist/3d/xr.d.ts +2 -0
- package/dist/3d/xr.js +202 -0
- package/dist/3d-B4jWF8Qb.js +5591 -0
- package/dist/3d.d.ts +40 -0
- package/dist/3d.js +44 -0
- package/dist/Capsule-BFVpZfvc.js +44 -0
- package/dist/Clip-CAN7t03k.js +204 -0
- package/dist/Color-vuv9UnoY.js +34 -0
- package/dist/DeformedMesh-CPi0P_vc.js +280 -0
- package/dist/Document-DCVEZSvM.js +415 -0
- package/dist/Errors-B2ekO9bZ.js +30 -0
- package/dist/Features-BsjmePtc.js +557 -0
- package/dist/GLTFResourceIO-CYJyCUTt.js +124 -0
- package/dist/GPUParticleState-CQlNpoDa.js +545 -0
- package/dist/Geometry-DytO490z.js +227 -0
- package/dist/Inflate-DWw0V-Up.js +42 -0
- package/dist/InstancedMesh-DPrgrw5z.js +527 -0
- package/dist/Limits-Bw5XQdFr.js +20 -0
- package/dist/LineHelper-Ad0z9uDi.js +131 -0
- package/dist/LoaderIO-BwrM84OM.js +114 -0
- package/dist/Material-BpfLPmK9.js +777 -0
- package/dist/Mesh-BaRxAAJq.js +209 -0
- package/dist/Node-QfgAE2_v.js +877 -0
- package/dist/NovaAssetRegistry-p2QlCwvT.js +1168 -0
- package/dist/NovaNode-CBZ-Ol-W.js +2016 -0
- package/dist/NovaRenderCommandWriter-CWQRa42y.js +1949 -0
- package/dist/NovaTextSelectionService-CipuujCT.js +18526 -0
- package/dist/NovaWebGLProgram-BO250QNF.js +97 -0
- package/dist/Options-CajE7LLJ.js +15 -0
- package/dist/PolygonMesh-D4PnnfIo.js +657 -0
- package/dist/Ready-BzyhRtjD.js +21 -0
- package/dist/Scene-CDfNgf9I.js +911 -0
- package/dist/Shader-b6_HDndT.js +48 -0
- package/dist/SplatShader-wJ6GJ3vo.js +130 -0
- package/dist/Texture-dTKMlTpK.js +267 -0
- package/dist/TextureLoader-CfDzdy2m.js +411 -0
- package/dist/Textures-CGL4Kf-8.js +651 -0
- package/dist/ToneMapping-D9IWvN0u.js +46 -0
- package/dist/WebGPURenderer-DjD0IxVC.js +4921 -0
- package/dist/ZipReader-C-MSEsSr.js +84 -0
- package/dist/core.js +218 -24024
- package/dist/domain/types/base.types.d.ts +18 -9
- package/dist/domain/types/component.types.d.ts +5 -5
- package/dist/domain/types/cursor.types.d.ts +1 -1
- package/dist/domain/types/diagnostics.types.d.ts +2 -0
- package/dist/domain/types/export.types.d.ts +2 -2
- package/dist/domain/types/hit-test.types.d.ts +1 -1
- package/dist/domain/types/motion.types.d.ts +2 -2
- package/dist/domain/types/renderer.types.d.ts +88 -4
- package/dist/domain/types/rendering/index.d.ts +29 -4
- package/dist/domain/types/sound.types.d.ts +1 -1
- package/dist/domain/types/theme.types.d.ts +1 -1
- package/dist/domain/utils/bounds.d.ts +1 -1
- package/dist/domain/utils/nova-text.d.ts +9 -0
- package/dist/domain/utils/schemaBounds.d.ts +2 -2
- package/dist/export-svg-document-ChaNXMaG.js +668 -0
- package/dist/features/3d/Errors.d.ts +57 -0
- package/dist/features/3d/Nova3DApp.d.ts +429 -0
- package/dist/features/3d/animation/Animator.d.ts +260 -0
- package/dist/features/3d/animation/Clip.d.ts +74 -0
- package/dist/features/3d/animation/Graph.d.ts +158 -0
- package/dist/features/3d/animation/Mask.d.ts +40 -0
- package/dist/features/3d/audio/Audio.d.ts +114 -0
- package/dist/features/3d/audio/Sound.d.ts +133 -0
- package/dist/features/3d/character/CharacterController.d.ts +61 -0
- package/dist/features/3d/collision/Capsule.d.ts +25 -0
- package/dist/features/3d/collision/Octree.d.ts +94 -0
- package/dist/features/3d/controls/CameraMotionControls.d.ts +154 -0
- package/dist/features/3d/controls/CameraOrientation.d.ts +47 -0
- package/dist/features/3d/controls/OrbitControls.d.ts +73 -0
- package/dist/features/3d/controls/PointerGesture.d.ts +25 -0
- package/dist/features/3d/controls/PointerLock.d.ts +36 -0
- package/dist/features/3d/controls/Snapping.d.ts +32 -0
- package/dist/features/3d/controls/TransformGizmo.d.ts +79 -0
- package/dist/features/3d/deformation/DeformationGPU.d.ts +52 -0
- package/dist/features/3d/deformation/DeformationShader.d.ts +2 -0
- package/dist/features/3d/deformation/DeformedMesh.d.ts +36 -0
- package/dist/features/3d/deformation/GeometryDeformation.d.ts +25 -0
- package/dist/features/3d/documents/Document.d.ts +59 -0
- package/dist/features/3d/documents/DocumentCommands.d.ts +45 -0
- package/dist/features/3d/documents/DocumentSchema.d.ts +18 -0
- package/dist/features/3d/documents/DocumentTransform.d.ts +4 -0
- package/dist/features/3d/documents/DocumentTypes.d.ts +182 -0
- package/dist/features/3d/documents/DocumentValidation.d.ts +18 -0
- package/dist/features/3d/documents/Projection.d.ts +65 -0
- package/dist/features/3d/effects/CubeLUT.d.ts +24 -0
- package/dist/features/3d/effects/Effects.d.ts +32 -0
- package/dist/features/3d/effects/EffectsGPU.d.ts +80 -0
- package/dist/features/3d/effects/EffectsPlan.d.ts +268 -0
- package/dist/features/3d/effects/EffectsShaders.d.ts +35 -0
- package/dist/features/3d/export/GLTFExporter.d.ts +49 -0
- package/dist/features/3d/export/ThreeMFExporter.d.ts +19 -0
- package/dist/features/3d/export/ZipWriter.d.ts +9 -0
- package/dist/features/3d/fbx/FBXLoader.d.ts +26 -0
- package/dist/features/3d/fbx/FBXParser.d.ts +35 -0
- package/dist/features/3d/fbx/FBXScene.d.ts +20 -0
- package/dist/features/3d/gltf/GLTFLoader.d.ts +16 -0
- package/dist/features/3d/gltf/GLTFTypes.d.ts +64 -0
- package/dist/features/3d/gltf/services/GLTFBinary.d.ts +21 -0
- package/dist/features/3d/gltf/services/GLTFGeometry.d.ts +14 -0
- package/dist/features/3d/gltf/services/GLTFResourceIO.d.ts +64 -0
- package/dist/features/3d/helpers/LineHelper.d.ts +51 -0
- package/dist/features/3d/helpers/StaticHelpers.d.ts +47 -0
- package/dist/features/3d/helpers/TrackedHelpers.d.ts +84 -0
- package/dist/features/3d/ik/ChainIK.d.ts +44 -0
- package/dist/features/3d/ik/IKChain.d.ts +92 -0
- package/dist/features/3d/ik/IKMath.d.ts +49 -0
- package/dist/features/3d/ik/IKSolver.d.ts +97 -0
- package/dist/features/3d/ik/LookAtIK.d.ts +58 -0
- package/dist/features/3d/ik/TwoBoneIK.d.ts +57 -0
- package/dist/features/3d/import/ImportAnimation.d.ts +20 -0
- package/dist/features/3d/import/ImportMath.d.ts +42 -0
- package/dist/features/3d/import/ImportedModel.d.ts +135 -0
- package/dist/features/3d/import/Inflate.d.ts +5 -0
- package/dist/features/3d/import/ModelAsset.d.ts +149 -0
- package/dist/features/3d/import/PolygonMesh.d.ts +54 -0
- package/dist/features/3d/lights/AreaLightTables.d.ts +8 -0
- package/dist/features/3d/lights/AreaLights.d.ts +11 -0
- package/dist/features/3d/loaders/EXRCompression.d.ts +13 -0
- package/dist/features/3d/loaders/EXRLoader.d.ts +39 -0
- package/dist/features/3d/loaders/HDRLoader.d.ts +26 -0
- package/dist/features/3d/loaders/Limits.d.ts +70 -0
- package/dist/features/3d/loaders/LoaderBuffers.d.ts +42 -0
- package/dist/features/3d/loaders/LoaderIO.d.ts +81 -0
- package/dist/features/3d/loaders/LoaderModel.d.ts +80 -0
- package/dist/features/3d/loaders/LoaderText.d.ts +27 -0
- package/dist/features/3d/loaders/MTLLoader.d.ts +105 -0
- package/dist/features/3d/loaders/OBJLoader.d.ts +70 -0
- package/dist/features/3d/loaders/PLYLoader.d.ts +47 -0
- package/dist/features/3d/loaders/STLLoader.d.ts +27 -0
- package/dist/features/3d/model/Camera.d.ts +33 -0
- package/dist/features/3d/model/Environment.d.ts +31 -0
- package/dist/features/3d/model/Geometry.d.ts +59 -0
- package/dist/features/3d/model/InstancedMesh.d.ts +134 -0
- package/dist/features/3d/model/LOD.d.ts +31 -0
- package/dist/features/3d/model/Light.d.ts +200 -0
- package/dist/features/3d/model/Material.d.ts +308 -0
- package/dist/features/3d/model/MaterialExtensions.d.ts +200 -0
- package/dist/features/3d/model/Mesh.d.ts +92 -0
- package/dist/features/3d/model/Node.d.ts +87 -0
- package/dist/features/3d/model/ReflectionProbe.d.ts +45 -0
- package/dist/features/3d/model/RenderTarget.d.ts +41 -0
- package/dist/features/3d/model/Scene.d.ts +173 -0
- package/dist/features/3d/model/Texture.d.ts +143 -0
- package/dist/features/3d/nodes/Nodes.d.ts +8 -0
- package/dist/features/3d/nodes/ShaderNode.d.ts +240 -0
- package/dist/features/3d/particles/GPUParticleSchedule.d.ts +67 -0
- package/dist/features/3d/particles/GPUParticleShaders.d.ts +19 -0
- package/dist/features/3d/particles/GPUParticleState.d.ts +106 -0
- package/dist/features/3d/particles/GPUParticleSystem.d.ts +192 -0
- package/dist/features/3d/particles/ParticleCurves.d.ts +34 -0
- package/dist/features/3d/particles/ParticleOptions.d.ts +78 -0
- package/dist/features/3d/particles/ParticleSystem.d.ts +368 -0
- package/dist/features/3d/physics/PhysicsBackend.d.ts +352 -0
- package/dist/features/3d/physics/PhysicsDebug.d.ts +24 -0
- package/dist/features/3d/physics/PhysicsWorld.d.ts +352 -0
- package/dist/features/3d/physics/basic/BasicCollision.d.ts +75 -0
- package/dist/features/3d/physics/basic/BasicPhysics.d.ts +24 -0
- package/dist/features/3d/physics/basic/BasicShapes.d.ts +103 -0
- package/dist/features/3d/physics/rapier/ContactBuffer.d.ts +32 -0
- package/dist/features/3d/physics/rapier/RapierBackend.d.ts +17 -0
- package/dist/features/3d/physics/rapier/RapierShapes.d.ts +4 -0
- package/dist/features/3d/physics/rapier/RapierWorld.d.ts +198 -0
- package/dist/features/3d/physics/rapier/Validation.d.ts +8 -0
- package/dist/features/3d/services/Background.d.ts +22 -0
- package/dist/features/3d/services/BasicShader.d.ts +55 -0
- package/dist/features/3d/services/ClusteredLights.d.ts +69 -0
- package/dist/features/3d/services/DrawOrder.d.ts +37 -0
- package/dist/features/3d/services/EffectsProcessor.d.ts +38 -0
- package/dist/features/3d/services/EnvironmentBRDF.d.ts +35 -0
- package/dist/features/3d/services/EnvironmentMaps.d.ts +55 -0
- package/dist/features/3d/services/FogShader.d.ts +6 -0
- package/dist/features/3d/services/Frustum.d.ts +7 -0
- package/dist/features/3d/services/GLState.d.ts +86 -0
- package/dist/features/3d/services/GPUPicker.d.ts +31 -0
- package/dist/features/3d/services/InstanceShader.d.ts +3 -0
- package/dist/features/3d/services/LineProgram.d.ts +32 -0
- package/dist/features/3d/services/PBRProgram.d.ts +115 -0
- package/dist/features/3d/services/Renderer.d.ts +50 -0
- package/dist/features/3d/services/Shader.d.ts +22 -0
- package/dist/features/3d/services/ShaderProgram.d.ts +38 -0
- package/dist/features/3d/services/ShadowMaps.d.ts +97 -0
- package/dist/features/3d/services/SpatialIndex.d.ts +16 -0
- package/dist/features/3d/services/TextureLoader.d.ts +40 -0
- package/dist/features/3d/services/TextureMipmaps.d.ts +42 -0
- package/dist/features/3d/services/ToneMapping.d.ts +12 -0
- package/dist/features/3d/services/WebGLRenderer.d.ts +261 -0
- package/dist/features/3d/splats/SplatData.d.ts +136 -0
- package/dist/features/3d/splats/SplatLoaders.d.ts +64 -0
- package/dist/features/3d/splats/SplatShader.d.ts +14 -0
- package/dist/features/3d/splats/SplatSort.d.ts +69 -0
- package/dist/features/3d/splats/Splats.d.ts +116 -0
- package/dist/features/3d/text/FontAtlas.d.ts +246 -0
- package/dist/features/3d/text/SDF.d.ts +28 -0
- package/dist/features/3d/text/Text.d.ts +179 -0
- package/dist/features/3d/text/TextLayout.d.ts +73 -0
- package/dist/features/3d/text/TextShader.d.ts +12 -0
- package/dist/features/3d/tiles/BoundingVolume.d.ts +43 -0
- package/dist/features/3d/tiles/Geodesy.d.ts +106 -0
- package/dist/features/3d/tiles/GlobeControls.d.ts +147 -0
- package/dist/features/3d/tiles/TileContent.d.ts +35 -0
- package/dist/features/3d/tiles/TileFormats.d.ts +77 -0
- package/dist/features/3d/tiles/Tiles3D.d.ts +236 -0
- package/dist/features/3d/tiles/Tileset.d.ts +81 -0
- package/dist/features/3d/tools/BatchedMesh.d.ts +74 -0
- package/dist/features/3d/tools/CanvasSurface.d.ts +81 -0
- package/dist/features/3d/tools/Color.d.ts +11 -0
- package/dist/features/3d/tools/MergeGeometries.d.ts +22 -0
- package/dist/features/3d/tools/Options.d.ts +15 -0
- package/dist/features/3d/tools/Polyhedra.d.ts +30 -0
- package/dist/features/3d/tools/PrimitiveBuffers.d.ts +42 -0
- package/dist/features/3d/tools/Primitives.d.ts +164 -0
- package/dist/features/3d/tools/Ready.d.ts +12 -0
- package/dist/features/3d/tools/SpatialMath.d.ts +57 -0
- package/dist/features/3d/tools/SphericalHarmonics.d.ts +9 -0
- package/dist/features/3d/tools/math/mat3.d.ts +7 -0
- package/dist/features/3d/tools/math/mat4.d.ts +19 -0
- package/dist/features/3d/tools/math/quat.d.ts +6 -0
- package/dist/features/3d/tools/math/vec3.d.ts +16 -0
- package/dist/features/3d/tools/math/vec4.d.ts +5 -0
- package/dist/features/3d/types.d.ts +359 -0
- package/dist/features/3d/usdz/USDAParser.d.ts +50 -0
- package/dist/features/3d/usdz/USDScene.d.ts +20 -0
- package/dist/features/3d/usdz/USDZLoader.d.ts +27 -0
- package/dist/features/3d/usdz/ZipReader.d.ts +16 -0
- package/dist/features/3d/webgpu/Backend.d.ts +40 -0
- package/dist/features/3d/webgpu/BasicShader.d.ts +10 -0
- package/dist/features/3d/webgpu/Constants.d.ts +32 -0
- package/dist/features/3d/webgpu/Deformation.d.ts +71 -0
- package/dist/features/3d/webgpu/Environment.d.ts +66 -0
- package/dist/features/3d/webgpu/Features.d.ts +68 -0
- package/dist/features/3d/webgpu/Layouts.d.ts +27 -0
- package/dist/features/3d/webgpu/Lines.d.ts +40 -0
- package/dist/features/3d/webgpu/LitExtras.d.ts +46 -0
- package/dist/features/3d/webgpu/LitFeatures.d.ts +41 -0
- package/dist/features/3d/webgpu/LitScene.d.ts +60 -0
- package/dist/features/3d/webgpu/LitShader.d.ts +68 -0
- package/dist/features/3d/webgpu/Particles.d.ts +114 -0
- package/dist/features/3d/webgpu/Picking.d.ts +59 -0
- package/dist/features/3d/webgpu/PipelineKey.d.ts +33 -0
- package/dist/features/3d/webgpu/Points.d.ts +41 -0
- package/dist/features/3d/webgpu/Probes.d.ts +45 -0
- package/dist/features/3d/webgpu/ShaderChunks.d.ts +18 -0
- package/dist/features/3d/webgpu/ShaderMaterial.d.ts +57 -0
- package/dist/features/3d/webgpu/ShaderMaterialSource.d.ts +5 -0
- package/dist/features/3d/webgpu/Shadows.d.ts +49 -0
- package/dist/features/3d/webgpu/Splats.d.ts +47 -0
- package/dist/features/3d/webgpu/Textures.d.ts +52 -0
- package/dist/features/3d/webgpu/Transmission.d.ts +30 -0
- package/dist/features/3d/webgpu/UniformLayout.d.ts +30 -0
- package/dist/features/3d/webgpu/UtilityShaders.d.ts +38 -0
- package/dist/features/3d/webgpu/WebGPURenderer.d.ts +327 -0
- package/dist/features/3d/webgpu/effects/EffectsShaders.d.ts +74 -0
- package/dist/features/3d/webgpu/effects/WebGPUEffects.d.ts +140 -0
- package/dist/features/3d/xr/XR.d.ts +100 -0
- package/dist/gltf-By-n0qEg.js +960 -0
- package/dist/index.d.ts +86 -81
- package/dist/model/document-actions/document-commands.d.ts +18 -0
- package/dist/model/documents/svg/create-svg-document-renderer.d.ts +32 -0
- package/dist/model/documents/svg/export-svg-document.d.ts +5 -0
- package/dist/model/documents/svg/import-svg-document.d.ts +6 -0
- package/dist/model/documents/svg/svg-document.types.d.ts +111 -0
- package/dist/model/documents/svg/svg-values.d.ts +16 -0
- package/dist/model/documents/svg/svg-xml.d.ts +18 -0
- package/dist/model/input/NovaInputProxy_Adapter.d.ts +2 -1
- package/dist/model/input/NovaInputValidationController.d.ts +1 -1
- package/dist/model/input/NovaTextInputController.d.ts +1 -1
- package/dist/model/input/NovaTextLayoutEngine.d.ts +2 -6
- package/dist/model/input/index.d.ts +7 -7
- package/dist/model/input/nova-input.types.d.ts +1 -1
- package/dist/model/lighting/LightingRenderer2D.d.ts +58 -0
- package/dist/model/lighting/NovaLighting2D.d.ts +56 -0
- package/dist/model/lighting/lighting-shaders.d.ts +3 -0
- package/dist/model/lighting/lighting-state.d.ts +27 -0
- package/dist/model/lighting/lighting.types.d.ts +107 -0
- package/dist/model/lottie/LottieNode.d.ts +4 -0
- package/dist/model/lottie/lottie.types.d.ts +83 -0
- package/dist/model/lottie/prepare-lottie.d.ts +3 -0
- package/dist/model/lottie/sample-position.d.ts +9 -0
- package/dist/model/motion/NovaMotionEngine.d.ts +3 -3
- package/dist/model/motion/nova-motion-easing.d.ts +1 -1
- package/dist/model/motion/nova-motion-interpolation.d.ts +1 -1
- package/dist/model/motion/nova-motion-presets.d.ts +2 -2
- package/dist/model/motion/nova-motion-timeline.d.ts +1 -1
- package/dist/model/platform/NovaCanvas.d.ts +7 -6
- package/dist/model/primitives/NovaPrimitiveUnsupportedError.d.ts +13 -0
- package/dist/model/primitives/definePrimitive.d.ts +5 -0
- package/dist/model/primitives/primitive.types.d.ts +28 -0
- package/dist/model/render/backends/canvas2d/NovaCanvas2DTargetManager.d.ts +3 -3
- package/dist/model/render/backends/canvas2d/NovaRenderer2D.d.ts +61 -15
- package/dist/model/render/backends/canvas2d/nova-canvas-blend.d.ts +5 -0
- package/dist/model/render/backends/nova-render-backend-factory.d.ts +6 -6
- package/dist/model/render/backends/nova-render-backend.d.ts +8 -2
- package/dist/model/render/backends/webgl/NovaRendererWebGL.d.ts +32 -11
- package/dist/model/render/backends/webgl/NovaStreamCacheIdleLedger.d.ts +12 -1
- package/dist/model/render/backends/webgl/NovaWebGLBatcher.d.ts +1 -1
- package/dist/model/render/backends/webgl/NovaWebGLCircleImagePass.d.ts +23 -0
- package/dist/model/render/backends/webgl/NovaWebGLCompositionPass.d.ts +9 -0
- package/dist/model/render/backends/webgl/NovaWebGLDevice.d.ts +3 -1
- package/dist/model/render/backends/webgl/NovaWebGLDiagnostics.d.ts +1 -1
- package/dist/model/render/backends/webgl/NovaWebGLFrameRenderer.d.ts +162 -53
- package/dist/model/render/backends/webgl/NovaWebGLPathClipPass.d.ts +13 -0
- package/dist/model/render/backends/webgl/NovaWebGLPathUnion.d.ts +23 -0
- package/dist/model/render/compiler/NovaRenderBuilder.d.ts +24 -10
- package/dist/model/render/compiler/NovaRenderCommandWriter.d.ts +10 -5
- package/dist/model/render/compiler/NovaRenderCompiler.d.ts +7 -6
- package/dist/model/render/compiler/NovaRenderFrameBuilder.d.ts +4 -3
- package/dist/model/render/effects/blur.d.ts +8 -0
- package/dist/model/render/effects/color-matrix.d.ts +8 -0
- package/dist/model/render/effects/drop-shadow.d.ts +18 -0
- package/dist/model/render/effects/nova-effect-registry.d.ts +66 -0
- package/dist/model/render/effects/nova-gaussian-kernel.d.ts +7 -0
- package/dist/model/render/effects/nova-gaussian-textures.d.ts +11 -0
- package/dist/model/render/effects/shader-effect.d.ts +64 -0
- package/dist/model/render/geometry/nova-alpha-mask.d.ts +5 -0
- package/dist/model/render/geometry/nova-composition.d.ts +9 -0
- package/dist/model/render/geometry/nova-node-clip.d.ts +17 -0
- package/dist/model/render/geometry/nova-path-geometry.d.ts +24 -0
- package/dist/model/render/geometry/nova-path-tessellation.d.ts +7 -0
- package/dist/model/render/geometry/nova-polygon-triangulation.d.ts +1 -1
- package/dist/model/render/graph/NovaRectBatchBuffer.d.ts +58 -0
- package/dist/model/render/graph/NovaRenderGraph.d.ts +40 -6
- package/dist/model/render/graph/NovaRenderHitIndex.d.ts +1 -1
- package/dist/model/render/graph/nova-auto-rect.d.ts +1 -1
- package/dist/model/render/graph/nova-linear-rect-repack.d.ts +4 -4
- package/dist/model/render/graph/nova-linear-rect-transition.d.ts +2 -2
- package/dist/model/render/graph/nova-render-culling.d.ts +2 -2
- package/dist/model/render/graph/nova-render-dirty-items.d.ts +1 -1
- package/dist/model/render/graph/nova-render-group.d.ts +1 -1
- package/dist/model/render/graph/nova-render-item.d.ts +2 -2
- package/dist/model/render/graph/nova-render-layer.d.ts +1 -1
- package/dist/model/render/graph/nova-render-payload-snapshot.d.ts +3 -1
- package/dist/model/render/graph/nova-render-program.d.ts +5 -3
- package/dist/model/render/graph/nova-render-sequence.d.ts +1 -1
- package/dist/model/render/graph/nova-render-stream.d.ts +2 -2
- package/dist/model/render/ktx2/BasisSession.d.ts +45 -0
- package/dist/model/render/ktx2/KTX2Container.d.ts +26 -0
- package/dist/model/render/ktx2/KTX2Loader.d.ts +55 -0
- package/dist/model/render/meshes/MeshNode.d.ts +13 -0
- package/dist/model/render/meshes/NovaMeshWebGLDevice.d.ts +27 -0
- package/dist/model/render/meshes/geometry.d.ts +7 -0
- package/dist/model/render/meshes/mesh.d.ts +3 -0
- package/dist/model/render/meshes/mesh.types.d.ts +116 -0
- package/dist/model/render/meshes/nova-mesh-registry.d.ts +55 -0
- package/dist/model/render/orchestration/NovaRenderOrchestrator.d.ts +25 -3
- package/dist/model/render/policy/nova-render-policy.d.ts +1 -1
- package/dist/model/render/resources/NovaGlyphAtlasManager.d.ts +2 -2
- package/dist/model/render/resources/NovaTextAtlasManager.d.ts +3 -3
- package/dist/model/render/resources/NovaTextLayoutEngine.d.ts +1 -1
- package/dist/model/render/resources/nova-bitmap-upload.d.ts +10 -0
- package/dist/model/render/schema/NovaRenderContext.d.ts +6 -4
- package/dist/model/render/schema/nova-style-compiler.d.ts +5 -2
- package/dist/model/render/targets/NovaNodeRenderTextureSource.d.ts +29 -0
- package/dist/model/render/targets/NovaRenderTargetManager.d.ts +1 -1
- package/dist/model/render/targets/NovaRenderTexture.d.ts +57 -0
- package/dist/model/render/targets/nova-render-target-refs.d.ts +5 -0
- package/dist/model/render/targets/nova-render-target-resource.d.ts +1 -1
- package/dist/model/render/targets/nova-render-texture-runtime.d.ts +71 -0
- package/dist/model/render/textures/nova-compressed-image.d.ts +20 -0
- package/dist/model/render/utils/nova-icon-rendering.d.ts +3 -1
- package/dist/model/render/utils/nova-image-geometry.d.ts +11 -0
- package/dist/model/render/utils/nova-markdown-layout.d.ts +19 -0
- package/dist/model/render/utils/nova-text-paint.d.ts +26 -0
- package/dist/model/render/utils/nova-wrapped-text-layout.d.ts +19 -0
- package/dist/model/runtime/app/Nova.d.ts +35 -35
- package/dist/model/runtime/app/NovaApp.d.ts +58 -30
- package/dist/model/runtime/app/NovaRaphRuntime.d.ts +2 -2
- package/dist/model/runtime/app/createNovaRaphRuntime.d.ts +3 -3
- package/dist/model/runtime/assets/NovaAssetRegistry.d.ts +89 -2
- package/dist/model/runtime/assets/NovaVideoTexture.d.ts +38 -0
- package/dist/model/runtime/assets/nova-render-texture-image-identity.d.ts +4 -0
- package/dist/model/runtime/commands/NovaCommandBus.d.ts +1 -1
- package/dist/model/runtime/components/NovaComponentNode.d.ts +6 -6
- package/dist/model/runtime/components/NovaComponentRegistry.d.ts +1 -1
- package/dist/model/runtime/components/NovaSchemaRegistry.d.ts +7 -6
- package/dist/model/runtime/components/nova-component-metadata.d.ts +1 -1
- package/dist/model/runtime/components/nova-component.decorator.d.ts +2 -2
- package/dist/model/runtime/components/nova-defined-component.d.ts +3 -3
- package/dist/model/runtime/context/nova-context.d.ts +1 -1
- package/dist/model/runtime/cursor/NovaCursorManager.d.ts +3 -3
- package/dist/model/runtime/diagnostics/NovaDiagnostics_Module.d.ts +3 -3
- package/dist/model/runtime/interaction/NovaEvents.d.ts +16 -6
- package/dist/model/runtime/interaction/NovaHitIndex.d.ts +1 -1
- package/dist/model/runtime/interaction/NovaSpatialIndex.d.ts +2 -2
- package/dist/model/runtime/scene/NovaScene.d.ts +3 -3
- package/dist/model/runtime/scene/nova-scene-components.d.ts +6 -6
- package/dist/model/runtime/state/nova-store-decorators.d.ts +1 -1
- package/dist/model/runtime/state/nova-store-runtime.d.ts +1 -1
- package/dist/model/runtime/state/nova-store-tracking.d.ts +7 -3
- package/dist/model/runtime/sync/NovaSyncScope.d.ts +11 -2
- package/dist/model/runtime/sync/nova-sync-context.d.ts +2 -2
- package/dist/model/runtime/sync/nova-sync-ports.d.ts +2 -2
- package/dist/model/runtime/sync/nova-sync.types.d.ts +15 -3
- package/dist/model/runtime/template/NovaTemplateRuntime.d.ts +6 -6
- package/dist/model/runtime/tree/NovaContainer.d.ts +4 -4
- package/dist/model/runtime/tree/NovaNode.d.ts +58 -18
- package/dist/model/runtime/tree/NovaRaphNode.d.ts +8 -2
- package/dist/model/runtime/tree/NovaSurface.d.ts +32 -10
- package/dist/model/runtime/tree/nova-node-capture-invalidation.d.ts +11 -0
- package/dist/model/semantic/NovaSemanticService.d.ts +1 -1
- package/dist/model/semantic/browser/createAccessibilityBridge.d.ts +29 -0
- package/dist/model/sound/NovaSoundEngine.d.ts +3 -2
- package/dist/model/text-selection/NovaTextSelectionService.d.ts +2 -2
- package/dist/model/text-selection/index.d.ts +2 -2
- package/dist/model/text-selection/nova-text-selection.types.d.ts +1 -1
- package/dist/model/theme/NovaGlobalThemeRegistry.d.ts +2 -2
- package/dist/model/theme/NovaThemeService.d.ts +5 -3
- package/dist/model/theme/createTokenTheme.d.ts +15 -0
- package/dist/model/tools/transform-tools.d.ts +43 -0
- package/dist/nodes--Ds4IS2h.js +621 -0
- package/dist/nova-color-parser-BCN_rFRN.js +250 -0
- package/dist/nova-compressed-image-CE2Ya9Xa.js +46 -0
- package/dist/nova-mesh-registry-B7Xz5mhU.js +24 -0
- package/dist/nova-render-texture-image-identity-DQ09XFKs.js +15 -0
- package/dist/nova-text-paint-CcntsRjI.js +48 -0
- package/dist/tokens.d.ts +2 -0
- package/dist/tokens.js +50 -0
- package/dist/vec4-BTNv1fUp.js +20 -0
- package/package.json +229 -4
package/dist/2d/ktx2.js
ADDED
|
@@ -0,0 +1,542 @@
|
|
|
1
|
+
import { n as ce, b as le } from "../nova-compressed-image-CE2Ya9Xa.js";
|
|
2
|
+
import { n as he } from "../NovaAssetRegistry-p2QlCwvT.js";
|
|
3
|
+
class u extends Error {
|
|
4
|
+
constructor(r, t) {
|
|
5
|
+
super(`[Nova KTX2] ${t}`), this.code = r, this.name = "NovaKTX2Error";
|
|
6
|
+
}
|
|
7
|
+
}
|
|
8
|
+
const fe = [171, 75, 84, 88, 32, 50, 48, 187, 13, 10, 26, 10];
|
|
9
|
+
function ue(i, r) {
|
|
10
|
+
const t = (n) => {
|
|
11
|
+
throw new u("invalid", n);
|
|
12
|
+
};
|
|
13
|
+
if (i.byteLength > r.maxSourceBytes)
|
|
14
|
+
throw new u("limit", "Source byte budget exceeded");
|
|
15
|
+
(i.byteLength < 80 || fe.some((n, p) => i[p] !== n)) && t("Missing or truncated KTX2 header");
|
|
16
|
+
const s = new DataView(i.buffer, i.byteOffset, i.byteLength), e = (n) => s.getUint32(n, !0), a = (n) => {
|
|
17
|
+
const p = e(n) + e(n + 4) * 4294967296;
|
|
18
|
+
return Number.isSafeInteger(p) || t("Unsafe 64-bit offset or length"), p;
|
|
19
|
+
}, d = e(12), l = e(16), c = e(20), o = e(24), h = e(28), g = e(32), f = e(36), y = e(40), x = e(44);
|
|
20
|
+
if ((!c || !o || ![1, 6].includes(f) || !l || ![1, 2, 4, 8].includes(l)) && t("Invalid dimensions, face count or type size"), c > r.maxDimension || o > r.maxDimension || h > r.maxDimension)
|
|
21
|
+
throw new u("limit", "Dimension budget exceeded");
|
|
22
|
+
const A = 1 + Math.floor(Math.log2(Math.max(c, o, h)));
|
|
23
|
+
(y > A || y > 32) && t("Mip count exceeds dimensions");
|
|
24
|
+
const D = Math.max(1, y), b = 80 + 24 * D;
|
|
25
|
+
b > i.byteLength && t("Truncated level index");
|
|
26
|
+
const v = [{ start: 0, end: b, name: "header" }], T = (n, p, _, m = 1) => {
|
|
27
|
+
(!p || n < b || n % m || n > i.byteLength || p > i.byteLength - n) && t(`Invalid ${_} range`), v.push({ start: n, end: n + p, name: _ });
|
|
28
|
+
}, w = e(48), O = e(52), P = e(56), z = e(60), I = a(64), X = a(72);
|
|
29
|
+
T(w, O, "DFD", 4), z ? T(P, z, "KVD", 4) : P && t("Empty KVD has a nonzero offset"), X ? T(I, X, "SGD", 8) : I && t("Empty SGD has a nonzero offset");
|
|
30
|
+
const ee = [];
|
|
31
|
+
let H = 0;
|
|
32
|
+
for (let n = 0; n < D; n++) {
|
|
33
|
+
const p = a(80 + n * 24), _ = a(88 + n * 24), m = a(96 + n * 24);
|
|
34
|
+
T(p, _, `level ${n}`), (x === 1 && m !== 0 || x === 0 && m !== _) && t("Invalid uncompressed level length"), ee.push({ offset: p, length: _ }), H += Math.ceil(Math.max(1, c >> n) / 4) * Math.ceil(Math.max(1, o >> n) / 4) * 16;
|
|
35
|
+
}
|
|
36
|
+
if (H > r.maxBlockBytes)
|
|
37
|
+
throw new u("limit", "Transcoded block byte budget exceeded");
|
|
38
|
+
v.sort((n, p) => n.start - p.start);
|
|
39
|
+
for (let n = 1; n < v.length; n++)
|
|
40
|
+
v[n].start < v[n - 1].end && t(`Overlapping ${v[n - 1].name} and ${v[n].name}`);
|
|
41
|
+
(O < 28 || e(w) !== O) && t("Invalid DFD length");
|
|
42
|
+
const j = s.getUint16(w + 10, !0);
|
|
43
|
+
(j < 24 || j + 4 !== O || (j - 24) % 16) && t("Invalid or multiple DFD blocks");
|
|
44
|
+
const oe = e(w + 4), ae = s.getUint16(w + 8, !0), G = i[w + 12], de = i[w + 13], W = i[w + 14], Z = i[w + 15];
|
|
45
|
+
Z & -2 && t("Reserved DFD alpha flags");
|
|
46
|
+
const K = (j - 24) / 16, Q = [];
|
|
47
|
+
for (let n = 0; n < K; n++)
|
|
48
|
+
Q.push(i[w + 28 + n * 16 + 3] & 15);
|
|
49
|
+
let te;
|
|
50
|
+
const E = (n) => {
|
|
51
|
+
te ??= n;
|
|
52
|
+
};
|
|
53
|
+
(d !== 0 || l !== 1 || x !== 1 || G !== 163) && E("Only ETC1S/BasisLZ is supported"), (h || g || f !== 1) && E("Only non-array single-face 2D images are supported"), (!y || y !== 1 && y !== A) && E("Provide level0 only or a complete mip chain"), (oe || ae !== 2 || ![0, 1].includes(de) || ![1, 2].includes(W)) && E("Unsupported DFD color description");
|
|
54
|
+
const re = d === 0 && x === 1 && G === 163, N = K === 2 && Q[1] === 15;
|
|
55
|
+
if (x === 1 && (d !== 0 || G !== 163 || l !== 1) && t("BasisLZ requires undefined vkFormat, ETC1S DFD and typeSize 1"), re) {
|
|
56
|
+
(K < 1 || K > 2) && t("Invalid ETC1S sample count"), (Q[0] !== 0 || K === 2 && !N) && E("Unsupported ETC1S channel layout");
|
|
57
|
+
const n = i.subarray(w + 20, w + 28), p = n.every((m) => m === 0), _ = n[0] === 8 && n[1] === (K === 2 ? 8 : 0) && n.subarray(2).every((m) => m === 0);
|
|
58
|
+
(i[w + 16] !== 3 || i[w + 17] !== 3 || i[w + 18] || i[w + 19] || !p && !_) && t("Invalid ETC1S block dimensions or planes");
|
|
59
|
+
for (let m = 0; m < K; m++) {
|
|
60
|
+
const B = w + 28 + m * 16;
|
|
61
|
+
(s.getUint16(B, !0) !== m * 64 || i[B + 2] !== 63 || i.subarray(B + 4, B + 8).some((L) => L !== 0)) && t("Invalid ETC1S sample descriptor"), (i[B + 3] & 224 || e(B + 8) !== 0 || e(B + 12) !== 4294967295) && E("Only unsigned normalized LDR ETC1S samples are supported");
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
N && !(Z & 1) && E("Straight alpha requires the explicit PNG/WebP fallback");
|
|
65
|
+
const ie = new TextDecoder("utf-8", { fatal: !0 }), se = /* @__PURE__ */ new Set();
|
|
66
|
+
for (let n = P; n < P + z; ) {
|
|
67
|
+
const p = P + z;
|
|
68
|
+
p - n < 4 && t("Truncated KVD entry");
|
|
69
|
+
const _ = e(n);
|
|
70
|
+
n += 4, (!_ || _ > p - n) && t("Invalid KVD entry length");
|
|
71
|
+
const m = i.subarray(n, n + _), B = m.indexOf(0);
|
|
72
|
+
B <= 0 && t("Missing KVD key terminator");
|
|
73
|
+
let L;
|
|
74
|
+
try {
|
|
75
|
+
L = ie.decode(m.subarray(0, B));
|
|
76
|
+
} catch {
|
|
77
|
+
t("Invalid UTF-8 KVD key");
|
|
78
|
+
}
|
|
79
|
+
if (se.has(L) && t("Duplicate KVD key"), se.add(L), L === "KTXorientation" || L === "KTXswizzle") {
|
|
80
|
+
const k = m.subarray(B + 1);
|
|
81
|
+
(!k.length || k[k.length - 1] !== 0) && t("Unterminated KTX metadata string");
|
|
82
|
+
let S;
|
|
83
|
+
try {
|
|
84
|
+
S = ie.decode(k.subarray(0, -1));
|
|
85
|
+
} catch {
|
|
86
|
+
t("Invalid UTF-8 KTX metadata");
|
|
87
|
+
}
|
|
88
|
+
L === "KTXorientation" ? ((h ? /^[rl][du][oi]$/ : /^[rl][du]$/).test(S) || t("Invalid 2D orientation"), S !== "rd" && E("Only rd orientation is supported")) : /^[rgba01]{4}$/.test(S) ? S !== "rgba" && E("Swizzled textures require fallback") : t("Invalid component swizzle");
|
|
89
|
+
}
|
|
90
|
+
L === "KTXanimData" && E("Texture animation is unsupported");
|
|
91
|
+
const R = Math.ceil(_ / 4) * 4;
|
|
92
|
+
(R > p - n || i.subarray(n + _, n + R).some((k) => k !== 0)) && t("Invalid KVD padding"), n += R;
|
|
93
|
+
}
|
|
94
|
+
if (re) {
|
|
95
|
+
(!X || X < 20) && t("Missing BasisLZ global data");
|
|
96
|
+
let n = 0;
|
|
97
|
+
for (let k = 0; k < D; k++)
|
|
98
|
+
n += Math.max(1, h >> k);
|
|
99
|
+
const _ = 20 + n * Math.max(1, g) * f * 20, m = e(I + 4), B = e(I + 8), L = e(I + 12), R = e(I + 16);
|
|
100
|
+
if ((!s.getUint16(I, !0) || !s.getUint16(I + 2, !0) || !m || !B || !L || R || _ + m + B + L !== X) && t("Invalid BasisLZ global data lengths or codebooks"), !h && !g && f === 1)
|
|
101
|
+
for (let k = 0; k < D; k++) {
|
|
102
|
+
const S = I + 20 + k * 20, ne = e(S), q = e(S + 4), J = e(S + 8), C = e(S + 12), F = e(S + 16), V = ee[k].length;
|
|
103
|
+
(ne & -3 || !J || q > V || J > V - q || C > V || F > V - C || (K === 2 ? !F : C !== 0 || F !== 0) || F && q < C + F && C < q + J) && t("Invalid BasisLZ image slices"), ne & 2 && E("Inter-frame BasisLZ is unsupported");
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
return Object.freeze({ width: c, height: o, levelCount: D, hasAlpha: N, premultiplied: !N || !!(Z & 1), transfer: W === 1 ? "linear" : W === 2 ? "srgb" : "unsupported", blockBytes: H, unsupported: te });
|
|
107
|
+
}
|
|
108
|
+
const $ = Object.freeze({
|
|
109
|
+
version: "three@0.186.1/basis",
|
|
110
|
+
javascriptSHA256: "8478b5b6d6b74e7d3082b89f6417321d8d1dc0307f2b30d4484bb11b441696a1",
|
|
111
|
+
wasmSHA256: "6cf17dc889352c42e9acf8897107978d127005fe3386c36a0e3845e27967630a",
|
|
112
|
+
javascriptBytes: 57529,
|
|
113
|
+
wasmBytes: 527333
|
|
114
|
+
});
|
|
115
|
+
function U() {
|
|
116
|
+
return new DOMException("KTX2 operation aborted", "AbortError");
|
|
117
|
+
}
|
|
118
|
+
async function Y(i, r, t) {
|
|
119
|
+
const s = await fetch(i, { signal: t });
|
|
120
|
+
if (!s.ok)
|
|
121
|
+
throw new u("provider", `HTTP ${s.status}: ${i}`);
|
|
122
|
+
if (Number(s.headers.get("content-length")) > r)
|
|
123
|
+
throw await s.body?.cancel(), new u("limit", "Response byte budget exceeded");
|
|
124
|
+
if (!s.body)
|
|
125
|
+
throw new u("provider", "Readable response body is required");
|
|
126
|
+
const a = s.body.getReader(), d = [];
|
|
127
|
+
let l = 0;
|
|
128
|
+
try {
|
|
129
|
+
for (; ; ) {
|
|
130
|
+
t.throwIfAborted();
|
|
131
|
+
const h = await a.read();
|
|
132
|
+
if (h.done)
|
|
133
|
+
break;
|
|
134
|
+
if (l += h.value.byteLength, l > r)
|
|
135
|
+
throw new u("limit", "Response byte budget exceeded");
|
|
136
|
+
d.push(h.value);
|
|
137
|
+
}
|
|
138
|
+
} catch (h) {
|
|
139
|
+
throw await a.cancel().catch(() => {
|
|
140
|
+
}), h;
|
|
141
|
+
} finally {
|
|
142
|
+
a.releaseLock();
|
|
143
|
+
}
|
|
144
|
+
t.throwIfAborted();
|
|
145
|
+
const c = new Uint8Array(l);
|
|
146
|
+
let o = 0;
|
|
147
|
+
for (const h of d)
|
|
148
|
+
c.set(h, o), o += h.byteLength;
|
|
149
|
+
return c;
|
|
150
|
+
}
|
|
151
|
+
class ge {
|
|
152
|
+
constructor(r) {
|
|
153
|
+
this._provider = r;
|
|
154
|
+
}
|
|
155
|
+
_worker;
|
|
156
|
+
_url;
|
|
157
|
+
_generation = 0;
|
|
158
|
+
_pending;
|
|
159
|
+
async transcode(r, t, s, e) {
|
|
160
|
+
if (e.throwIfAborted(), !this._worker) {
|
|
161
|
+
const c = this._generation, [o, h] = await Promise.all([
|
|
162
|
+
this._verified(this._provider.javascriptURL, $.javascriptBytes, $.javascriptSHA256, e),
|
|
163
|
+
this._verified(this._provider.wasmURL, $.wasmBytes, $.wasmSHA256, e)
|
|
164
|
+
]);
|
|
165
|
+
if (e.throwIfAborted(), c !== this._generation)
|
|
166
|
+
throw U();
|
|
167
|
+
const g = new TextDecoder("utf-8", { fatal: !0 }).decode(o);
|
|
168
|
+
this._url = URL.createObjectURL(new Blob([g, `
|
|
169
|
+
;(${pe.toString()})();`], { type: "text/javascript" }));
|
|
170
|
+
try {
|
|
171
|
+
this._worker = new Worker(this._url), await this._request({ type: "init", wasm: h.buffer }, [h.buffer], e);
|
|
172
|
+
} catch (f) {
|
|
173
|
+
throw this.destroy(), f;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
const d = await this._request({ type: "transcode", bytes: r.buffer, metadata: t, format: s }, [r.buffer], e);
|
|
177
|
+
if (!d || !Array.isArray(d.levels) || d.levels.length !== t.levelCount)
|
|
178
|
+
throw this.destroy(), new u("provider", "Provider returned an invalid mip count");
|
|
179
|
+
let l = 0;
|
|
180
|
+
for (let c = 0; c < d.levels.length; c++) {
|
|
181
|
+
const o = d.levels[c], h = Math.max(1, t.width >> c), g = Math.max(1, t.height >> c), f = Math.ceil(h / 4) * Math.ceil(g / 4) * 16;
|
|
182
|
+
if (o.width !== h || o.height !== g || !(o.data instanceof Uint8Array) || o.data.byteLength !== f)
|
|
183
|
+
throw this.destroy(), new u("provider", "Provider returned invalid compressed blocks");
|
|
184
|
+
l += f, Object.freeze(o);
|
|
185
|
+
}
|
|
186
|
+
if (l !== t.blockBytes)
|
|
187
|
+
throw new u("provider", "Provider block byte mismatch");
|
|
188
|
+
return Object.freeze(d.levels);
|
|
189
|
+
}
|
|
190
|
+
destroy() {
|
|
191
|
+
this._generation++, this._worker?.terminate(), this._worker = void 0, this._url && URL.revokeObjectURL(this._url), this._url = void 0;
|
|
192
|
+
const r = this._pending;
|
|
193
|
+
this._pending = void 0, r?.(U());
|
|
194
|
+
}
|
|
195
|
+
async _verified(r, t, s, e) {
|
|
196
|
+
const a = await Y(r, t, e);
|
|
197
|
+
if (a.byteLength !== t)
|
|
198
|
+
throw new u("provider", "Pinned provider byte length mismatch");
|
|
199
|
+
const d = await crypto.subtle.digest("SHA-256", a);
|
|
200
|
+
if (e.throwIfAborted(), Array.from(new Uint8Array(d), (c) => c.toString(16).padStart(2, "0")).join("") !== s)
|
|
201
|
+
throw new u("provider", "Pinned provider SHA-256 mismatch");
|
|
202
|
+
return a;
|
|
203
|
+
}
|
|
204
|
+
_request(r, t, s) {
|
|
205
|
+
return new Promise((e, a) => {
|
|
206
|
+
const d = this._worker;
|
|
207
|
+
if (!d || s.aborted) {
|
|
208
|
+
a(U());
|
|
209
|
+
return;
|
|
210
|
+
}
|
|
211
|
+
const l = this._generation;
|
|
212
|
+
let c, o, h;
|
|
213
|
+
const g = (f, y) => {
|
|
214
|
+
clearTimeout(c), s.removeEventListener("abort", o), d.onmessage = d.onerror = d.onmessageerror = null, this._pending === h && (this._pending = void 0), f ? a(f) : e(y);
|
|
215
|
+
};
|
|
216
|
+
h = (f) => {
|
|
217
|
+
g(f);
|
|
218
|
+
}, o = () => {
|
|
219
|
+
this.destroy();
|
|
220
|
+
}, c = setTimeout(() => {
|
|
221
|
+
g(new u("provider", "Basis worker exceeded the 30 second deadline")), this.destroy();
|
|
222
|
+
}, 3e4), this._pending = h, s.addEventListener("abort", o, { once: !0 }), d.onerror = () => {
|
|
223
|
+
g(new u("provider", "Basis worker failed")), this.destroy();
|
|
224
|
+
}, d.onmessageerror = () => {
|
|
225
|
+
g(new u("provider", "Invalid Basis worker message")), this.destroy();
|
|
226
|
+
}, d.onmessage = (f) => {
|
|
227
|
+
if (l !== this._generation || s.aborted) {
|
|
228
|
+
g(U());
|
|
229
|
+
return;
|
|
230
|
+
}
|
|
231
|
+
if (!f.data || typeof f.data != "object") {
|
|
232
|
+
g(new u("provider", "Invalid Basis worker response")), this.destroy();
|
|
233
|
+
return;
|
|
234
|
+
}
|
|
235
|
+
f.data.error ? (g(new u("invalid", f.data.error)), this.destroy()) : g(void 0, f.data.value);
|
|
236
|
+
};
|
|
237
|
+
try {
|
|
238
|
+
d.postMessage(r, t);
|
|
239
|
+
} catch (f) {
|
|
240
|
+
g(f instanceof Error ? f : new Error(String(f))), this.destroy();
|
|
241
|
+
}
|
|
242
|
+
});
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
function pe() {
|
|
246
|
+
const i = globalThis;
|
|
247
|
+
let r;
|
|
248
|
+
i.onmessage = async (t) => {
|
|
249
|
+
try {
|
|
250
|
+
const s = t.data;
|
|
251
|
+
if (s.type === "init") {
|
|
252
|
+
r = await i.BASIS({ wasmBinary: s.wasm }), r.initializeBasis(), i.postMessage({ value: null });
|
|
253
|
+
return;
|
|
254
|
+
}
|
|
255
|
+
if (s.type !== "transcode" || !r)
|
|
256
|
+
throw new Error("Basis session is not ready");
|
|
257
|
+
const e = s.metadata, a = new r.KTX2File(new Uint8Array(s.bytes));
|
|
258
|
+
try {
|
|
259
|
+
if (!a.isValid() || !a.isETC1S() || a.getWidth() !== e.width || a.getHeight() !== e.height || a.getLevels() !== e.levelCount || a.getLayers() > 1 || a.getFaces() !== 1 || !!a.getHasAlpha() !== e.hasAlpha || e.hasAlpha && !!(a.getDFDFlags() & 1) !== e.premultiplied)
|
|
260
|
+
throw new Error("Basis metadata differs from the validated container");
|
|
261
|
+
if (!a.startTranscoding())
|
|
262
|
+
throw new Error("Basis could not start transcoding");
|
|
263
|
+
const d = s.format === "bc3" ? 3 : 1, l = [], c = [];
|
|
264
|
+
for (let o = 0; o < e.levelCount; o++) {
|
|
265
|
+
const h = Math.max(1, e.width >> o), g = Math.max(1, e.height >> o), f = a.getImageLevelInfo(o, 0, 0), y = Math.ceil(h / 4) * Math.ceil(g / 4) * 16;
|
|
266
|
+
if (f.origWidth !== h || f.origHeight !== g || a.getImageTranscodedSizeInBytes(o, 0, 0, d) !== y)
|
|
267
|
+
throw new Error("Basis mip dimensions or block byte length differ");
|
|
268
|
+
const x = new Uint8Array(y);
|
|
269
|
+
if (!a.transcodeImage(x, o, 0, 0, d, 0, -1, -1))
|
|
270
|
+
throw new Error("Basis mip transcoding failed");
|
|
271
|
+
l.push({ width: h, height: g, data: x }), c.push(x.buffer);
|
|
272
|
+
}
|
|
273
|
+
i.postMessage({ value: { levels: l } }, c);
|
|
274
|
+
} finally {
|
|
275
|
+
a.close(), a.delete();
|
|
276
|
+
}
|
|
277
|
+
} catch (s) {
|
|
278
|
+
i.postMessage({ error: s instanceof Error ? s.message : String(s) });
|
|
279
|
+
}
|
|
280
|
+
};
|
|
281
|
+
}
|
|
282
|
+
let me = 0;
|
|
283
|
+
class we {
|
|
284
|
+
constructor(r, t) {
|
|
285
|
+
if (this._app = r, this._limits = {
|
|
286
|
+
maxSourceBytes: M(t.maxSourceBytes, 16 * 1024 * 1024, 64 * 1024 * 1024),
|
|
287
|
+
maxDimension: M(t.maxDimension, 4096, 8192),
|
|
288
|
+
maxBlockBytes: M(t.maxBlockBytes, 32 * 1024 * 1024, 128 * 1024 * 1024)
|
|
289
|
+
}, this._maxQueued = M(t.maxQueuedLoads, 4, 16), this._maxRetained = M(t.maxRetainedBlockBytes, 64 * 1024 * 1024, 256 * 1024 * 1024), this._maxFallback = M(t.maxRetainedFallbackBytes, 128 * 1024 * 1024, 512 * 1024 * 1024), !t.provider?.javascriptURL || !t.provider.wasmURL)
|
|
290
|
+
throw new TypeError("[Nova KTX2] Explicit pinned provider URLs are required");
|
|
291
|
+
if (this._session = new ge(Object.freeze({ ...t.provider })), r.raph.core.disposed)
|
|
292
|
+
throw new Error("[Nova KTX2] App is destroyed");
|
|
293
|
+
this._unown = r.raph.core.root.own(() => {
|
|
294
|
+
this.destroy();
|
|
295
|
+
});
|
|
296
|
+
}
|
|
297
|
+
_id = ++me;
|
|
298
|
+
_queue = [];
|
|
299
|
+
_textures = /* @__PURE__ */ new Set();
|
|
300
|
+
_limits;
|
|
301
|
+
_session;
|
|
302
|
+
_maxQueued;
|
|
303
|
+
_maxRetained;
|
|
304
|
+
_maxFallback;
|
|
305
|
+
_retained = 0;
|
|
306
|
+
_fallbackBytes = 0;
|
|
307
|
+
_nextTexture = 0;
|
|
308
|
+
_active;
|
|
309
|
+
_destroyed = !1;
|
|
310
|
+
_unown;
|
|
311
|
+
// ---------------------------------------------
|
|
312
|
+
// PUBLIC API
|
|
313
|
+
// ---------------------------------------------
|
|
314
|
+
load(r) {
|
|
315
|
+
if (this._destroyed || this._app.raph.core.disposed)
|
|
316
|
+
return Promise.reject(new Error("[Nova KTX2] Loader is destroyed"));
|
|
317
|
+
if (r.signal?.aborted)
|
|
318
|
+
return Promise.reject(U());
|
|
319
|
+
if (!r.source || typeof r.source != "string" && !(r.source instanceof Uint8Array) || !r.fallback)
|
|
320
|
+
return Promise.reject(new TypeError("[Nova KTX2] Source and explicit PNG/WebP fallback URL are required"));
|
|
321
|
+
if (this.pendingCount >= this._maxQueued)
|
|
322
|
+
return Promise.reject(new u("limit", "Loader queue is full"));
|
|
323
|
+
if (typeof r.source != "string" && r.source.byteLength > this._limits.maxSourceBytes)
|
|
324
|
+
return Promise.reject(new u("limit", "Source byte budget exceeded"));
|
|
325
|
+
const t = typeof r.source == "string" ? r.source : r.source.slice(), s = new AbortController();
|
|
326
|
+
return new Promise((e, a) => {
|
|
327
|
+
let d;
|
|
328
|
+
const l = () => {
|
|
329
|
+
s.abort();
|
|
330
|
+
const c = this._queue.indexOf(d);
|
|
331
|
+
c >= 0 && (this._queue.splice(c, 1), d.unlink(), a(U()));
|
|
332
|
+
};
|
|
333
|
+
d = { source: t, fallback: r.fallback, controller: s, resolve: e, reject: a, unlink: () => r.signal?.removeEventListener("abort", l) }, r.signal?.addEventListener("abort", l, { once: !0 }), this._queue.push(d), this._pump();
|
|
334
|
+
});
|
|
335
|
+
}
|
|
336
|
+
destroy() {
|
|
337
|
+
if (this._destroyed)
|
|
338
|
+
return;
|
|
339
|
+
this._destroyed = !0, this._active?.controller.abort();
|
|
340
|
+
for (const s of this._queue.splice(0))
|
|
341
|
+
s.controller.abort(), s.unlink(), s.reject(U());
|
|
342
|
+
this._session.destroy();
|
|
343
|
+
const r = [];
|
|
344
|
+
for (const s of [...this._textures])
|
|
345
|
+
try {
|
|
346
|
+
s();
|
|
347
|
+
} catch (e) {
|
|
348
|
+
r.push(e);
|
|
349
|
+
}
|
|
350
|
+
this._textures.clear();
|
|
351
|
+
const t = this._unown;
|
|
352
|
+
if (this._unown = void 0, t?.(), r.length)
|
|
353
|
+
throw new AggregateError(r, "[Nova KTX2] Owned texture cleanup failed");
|
|
354
|
+
}
|
|
355
|
+
// ---------------------------------------------
|
|
356
|
+
// PRIVATE
|
|
357
|
+
// ---------------------------------------------
|
|
358
|
+
async _pump() {
|
|
359
|
+
if (this._active || this._destroyed)
|
|
360
|
+
return;
|
|
361
|
+
const r = this._queue.shift();
|
|
362
|
+
if (r) {
|
|
363
|
+
this._active = r;
|
|
364
|
+
try {
|
|
365
|
+
r.resolve(await this._load(r));
|
|
366
|
+
} catch (t) {
|
|
367
|
+
r.reject(t);
|
|
368
|
+
} finally {
|
|
369
|
+
r.controller.abort(), r.unlink(), this._active = void 0, this._destroyed || this._pump();
|
|
370
|
+
}
|
|
371
|
+
}
|
|
372
|
+
}
|
|
373
|
+
async _load(r) {
|
|
374
|
+
const t = r.controller.signal, s = typeof r.source == "string" ? await Y(r.source, this._limits.maxSourceBytes, t) : r.source;
|
|
375
|
+
t.throwIfAborted();
|
|
376
|
+
const e = ue(s, this._limits), a = e.width * e.height * 4;
|
|
377
|
+
if (this._fallbackBytes + a > this._maxFallback)
|
|
378
|
+
throw new u("limit", "Loader retained fallback logical byte budget exceeded");
|
|
379
|
+
const d = s.byteLength;
|
|
380
|
+
let l = e.unsupported, c;
|
|
381
|
+
const o = this._app.canvas.element.getContext("webgl2");
|
|
382
|
+
if (o && !o.isContextLost() && (e.width > o.getParameter(o.MAX_TEXTURE_SIZE) || e.height > o.getParameter(o.MAX_TEXTURE_SIZE)))
|
|
383
|
+
throw new u("limit", "Image exceeds current WebGL MAX_TEXTURE_SIZE");
|
|
384
|
+
if (l || (c = o ? ce(o, e.width, e.height) : void 0, c || (l = "Current backend has no supported BC3/ETC2 RGBA format or size")), c && this._retained + e.blockBytes > this._maxRetained)
|
|
385
|
+
throw new u("limit", "Loader retained block byte budget exceeded");
|
|
386
|
+
const h = c ? await this._session.transcode(s, e, c, t) : void 0;
|
|
387
|
+
t.throwIfAborted();
|
|
388
|
+
const g = await Y(r.fallback, this._limits.maxSourceBytes, t), f = ye(g);
|
|
389
|
+
if (f.width !== e.width || f.height !== e.height)
|
|
390
|
+
throw new u("invalid", "Fallback dimensions differ from KTX2");
|
|
391
|
+
const y = await createImageBitmap(new Blob([g], { type: f.type }), { imageOrientation: "none" });
|
|
392
|
+
let x;
|
|
393
|
+
const A = he(`nova.ktx2.${this._id}.${++this._nextTexture}`, { images: { texture: { type: "image", source: y, width: e.width, height: e.height } } }), D = () => {
|
|
394
|
+
let v;
|
|
395
|
+
try {
|
|
396
|
+
v = this._app.assets.resolveRecord(A.images.texture);
|
|
397
|
+
} catch (T) {
|
|
398
|
+
if (this._app.raph.core.disposed)
|
|
399
|
+
return;
|
|
400
|
+
throw T;
|
|
401
|
+
}
|
|
402
|
+
v?.descriptor === A.records.get(A.images.texture.id)?.descriptor && this._app.assets.unuse(A);
|
|
403
|
+
}, b = {
|
|
404
|
+
path: h ? "compressed-ready" : "fallback",
|
|
405
|
+
validation: h ? "transcoded" : "container-only",
|
|
406
|
+
providerScratch: h ? "provider-defined" : "not-started-for-image",
|
|
407
|
+
reason: l,
|
|
408
|
+
format: c,
|
|
409
|
+
transfer: e.transfer,
|
|
410
|
+
premultiplied: e.premultiplied,
|
|
411
|
+
mipLevels: h?.length ?? 1,
|
|
412
|
+
sourceBytes: d,
|
|
413
|
+
blockBytes: h ? e.blockBytes : 0,
|
|
414
|
+
fallbackEncodedBytes: g.byteLength,
|
|
415
|
+
fallbackLogicalRGBABytes: e.width * e.height * 4,
|
|
416
|
+
lastUpload: "none",
|
|
417
|
+
lastUploadLogicalBytes: 0
|
|
418
|
+
};
|
|
419
|
+
try {
|
|
420
|
+
if (t.throwIfAborted(), this._destroyed || this._app.raph.core.disposed)
|
|
421
|
+
throw U();
|
|
422
|
+
if (y.width !== e.width || y.height !== e.height)
|
|
423
|
+
throw new u("invalid", "Decoded fallback dimensions differ from KTX2");
|
|
424
|
+
if (h && c) {
|
|
425
|
+
if (e.transfer === "unsupported")
|
|
426
|
+
throw new u("unsupported", "Unsupported transfer cannot become a compressed image");
|
|
427
|
+
x = le(y, Object.freeze({
|
|
428
|
+
format: c,
|
|
429
|
+
width: e.width,
|
|
430
|
+
height: e.height,
|
|
431
|
+
levels: h,
|
|
432
|
+
bytes: e.blockBytes,
|
|
433
|
+
premultiplied: e.premultiplied,
|
|
434
|
+
transfer: e.transfer,
|
|
435
|
+
uploaded: (T, w) => {
|
|
436
|
+
b.path !== "destroyed" && (b.lastUpload = T ? "compressed" : "fallback", b.lastUploadLogicalBytes = T ? e.blockBytes : e.width * e.height * 4, b.reason = w);
|
|
437
|
+
}
|
|
438
|
+
}));
|
|
439
|
+
}
|
|
440
|
+
if (this._app.assets.use(A), t.throwIfAborted(), this._destroyed || this._app.raph.core.disposed)
|
|
441
|
+
throw U();
|
|
442
|
+
this._retained += b.blockBytes, this._fallbackBytes += a;
|
|
443
|
+
const v = () => {
|
|
444
|
+
if (b.path !== "destroyed") {
|
|
445
|
+
b.path = "destroyed", this._textures.delete(v), this._retained -= b.blockBytes, this._fallbackBytes -= a, b.blockBytes = 0, b.fallbackLogicalRGBABytes = 0, b.lastUploadLogicalBytes = 0, x?.(), x = void 0;
|
|
446
|
+
try {
|
|
447
|
+
D();
|
|
448
|
+
} finally {
|
|
449
|
+
y.close();
|
|
450
|
+
}
|
|
451
|
+
}
|
|
452
|
+
};
|
|
453
|
+
return this._textures.add(v), Object.freeze({
|
|
454
|
+
image: A.images.texture,
|
|
455
|
+
width: e.width,
|
|
456
|
+
height: e.height,
|
|
457
|
+
get diagnostics() {
|
|
458
|
+
return Object.freeze({ ...b });
|
|
459
|
+
},
|
|
460
|
+
destroy: v
|
|
461
|
+
});
|
|
462
|
+
} catch (v) {
|
|
463
|
+
x?.();
|
|
464
|
+
try {
|
|
465
|
+
D();
|
|
466
|
+
} catch (T) {
|
|
467
|
+
throw new AggregateError([v, T], "[Nova KTX2] Publication and rollback notification failed");
|
|
468
|
+
} finally {
|
|
469
|
+
y.close();
|
|
470
|
+
}
|
|
471
|
+
throw v;
|
|
472
|
+
}
|
|
473
|
+
}
|
|
474
|
+
// ---------------------------------------------
|
|
475
|
+
// ACCESS
|
|
476
|
+
// ---------------------------------------------
|
|
477
|
+
get pendingCount() {
|
|
478
|
+
return this._queue.length + (this._active ? 1 : 0);
|
|
479
|
+
}
|
|
480
|
+
get retainedBlockBytes() {
|
|
481
|
+
return this._retained;
|
|
482
|
+
}
|
|
483
|
+
get retainedFallbackLogicalBytes() {
|
|
484
|
+
return this._fallbackBytes;
|
|
485
|
+
}
|
|
486
|
+
}
|
|
487
|
+
function _e(i, r) {
|
|
488
|
+
return new we(i, r);
|
|
489
|
+
}
|
|
490
|
+
function M(i, r, t) {
|
|
491
|
+
const s = i ?? r;
|
|
492
|
+
if (!Number.isSafeInteger(s) || s < 1 || s > t)
|
|
493
|
+
throw new RangeError(`[Nova KTX2] Limit must be an integer in 1..${t}`);
|
|
494
|
+
return s;
|
|
495
|
+
}
|
|
496
|
+
function ye(i) {
|
|
497
|
+
const r = new DataView(i.buffer, i.byteOffset, i.byteLength), t = (e, a) => [...a].every((d, l) => i[e + l] === d.charCodeAt(0)), s = () => {
|
|
498
|
+
throw new u("invalid", "Fallback must be a bounded PNG or WebP image");
|
|
499
|
+
};
|
|
500
|
+
if (i.length >= 33 && i[0] === 137 && t(1, `PNG\r
|
|
501
|
+
|
|
502
|
+
`) && r.getUint32(8) === 13 && t(12, "IHDR")) {
|
|
503
|
+
const e = r.getUint32(16), a = r.getUint32(20);
|
|
504
|
+
return !e || !a ? s() : { width: e, height: a, type: "image/png" };
|
|
505
|
+
}
|
|
506
|
+
if (i.length >= 20 && t(0, "RIFF") && t(8, "WEBP") && r.getUint32(4, !0) + 8 === i.length) {
|
|
507
|
+
const e = (l) => i[l] + i[l + 1] * 256 + i[l + 2] * 65536;
|
|
508
|
+
let a, d;
|
|
509
|
+
for (let l = 12; l < i.length; ) {
|
|
510
|
+
if (i.length - l < 8)
|
|
511
|
+
return s();
|
|
512
|
+
const c = r.getUint32(l + 4, !0), o = l + 8;
|
|
513
|
+
if (c > i.length - o || c + c % 2 > i.length - o)
|
|
514
|
+
return s();
|
|
515
|
+
if (t(l, "VP8X")) {
|
|
516
|
+
if (l !== 12 || a || c !== 10 || i[o] & 195 || i[o + 1] || i[o + 2] || i[o + 3])
|
|
517
|
+
return s();
|
|
518
|
+
a = { width: e(o + 4) + 1, height: e(o + 7) + 1 };
|
|
519
|
+
} else if (t(l, "VP8L")) {
|
|
520
|
+
if (d || c < 5 || i[o] !== 47)
|
|
521
|
+
return s();
|
|
522
|
+
const h = r.getUint32(o + 1, !0);
|
|
523
|
+
if (h >>> 29)
|
|
524
|
+
return s();
|
|
525
|
+
d = { width: (h & 16383) + 1, height: (h >>> 14 & 16383) + 1 };
|
|
526
|
+
} else if (t(l, "VP8 ")) {
|
|
527
|
+
if (d || c < 10 || i[o] & 1 || !t(o + 3, "*"))
|
|
528
|
+
return s();
|
|
529
|
+
d = { width: r.getUint16(o + 6, !0) & 16383, height: r.getUint16(o + 8, !0) & 16383 };
|
|
530
|
+
} else if (t(l, "ANIM") || t(l, "ANMF"))
|
|
531
|
+
return s();
|
|
532
|
+
l = o + c + c % 2;
|
|
533
|
+
}
|
|
534
|
+
return !d?.width || !d.height || a && (d.width !== a.width || d.height !== a.height) ? s() : { ...d, type: "image/webp" };
|
|
535
|
+
}
|
|
536
|
+
return s();
|
|
537
|
+
}
|
|
538
|
+
export {
|
|
539
|
+
u as NovaKTX2Error,
|
|
540
|
+
_e as createKTX2Loader,
|
|
541
|
+
$ as novaKTX2BasisProvider
|
|
542
|
+
};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export type { NovaDirectionalLightOptions2D, NovaLightColor2D, NovaLightingBounds2D, NovaLightingHandle2D, NovaLightingOptions2D, NovaLightingRenderOptions2D, NovaLightOccluderOptions2D, NovaLightOptions2D, NovaLightReceiverOptions2D, NovaLightShadows2D, NovaLightVector2D, NovaPointLightOptions2D, NovaSpotLightOptions2D } from '../model/lighting/lighting.types.js';
|
|
2
|
+
/** Opt-in 2D lighting. Importing does not create devices, canvases or clocks. */
|
|
3
|
+
export { createLighting2D, NovaLighting2D } from '../model/lighting/NovaLighting2D.js';
|