@spiffcommerce/preview 3.6.2-rc.5 → 3.6.2-rc.7
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/_tslib.esm.js +33 -0
- package/dist/animation.esm.js +1364 -0
- package/dist/assetCache.esm.js +6 -0
- package/dist/blurPostProcess.esm.js +327 -0
- package/dist/bumpVertex.esm.js +497 -0
- package/dist/compatibilityOptions.esm.js +68 -0
- package/dist/configuration.esm.js +121 -0
- package/dist/core.esm.js +8135 -0
- package/dist/dynamicTexture.esm.js +105 -0
- package/dist/easing.esm.js +130 -0
- package/dist/effectFallbacks.esm.js +378 -0
- package/dist/engine.esm.js +25504 -0
- package/dist/glbLoaderExtensions.esm.js +690 -0
- package/dist/glowLayer.esm.js +1621 -0
- package/dist/glowLayerManager.esm.js +50 -0
- package/dist/guid.esm.js +21 -0
- package/dist/hdrFilteringFunctions.esm.js +816 -0
- package/dist/helperFunctions.esm.js +5145 -0
- package/dist/index.esm.js +38 -11
- package/dist/material.esm.js +115 -0
- package/dist/math.axis.esm.js +35 -0
- package/dist/math.color.esm.js +1661 -0
- package/dist/math.path.esm.js +15 -0
- package/dist/math.size.esm.js +137 -0
- package/dist/mesh.esm.js +11170 -0
- package/dist/modelContainer.esm.js +1895 -0
- package/dist/node.esm.js +795 -0
- package/dist/pbrBRDFFunctions.esm.js +122 -2
- package/dist/pbrMaterial.esm.js +8747 -0
- package/dist/productAnimations.esm.js +182 -0
- package/dist/productCamera.esm.js +14 -0
- package/dist/renderConstants.esm.js +116 -0
- package/dist/renderingPipeline.esm.js +18 -0
- package/dist/sceneLoaderFlags.esm.js +51 -0
- package/dist/types.esm.js +30 -0
- package/dist/variants.esm.js +16 -0
- package/dist/webRequest.esm.js +7777 -0
- package/package.json +6 -5
- package/dist/index.umd.js +0 -10010
- package/dist/lib/assetCache.esm.js +0 -21
- package/dist/lib/configuration.esm.js +0 -98
- package/dist/lib/core.esm.js +0 -417
- package/dist/lib/dynamicTexture.esm.js +0 -51
- package/dist/lib/glbLoaderExtensions.esm.js +0 -137
- package/dist/lib/glowLayerManager.esm.js +0 -19
- package/dist/lib/guid.esm.js +0 -7
- package/dist/lib/material.esm.js +0 -50
- package/dist/lib/modelContainer.esm.js +0 -351
- package/dist/lib/productAnimations.esm.js +0 -123
- package/dist/lib/productCamera.esm.js +0 -113
- package/dist/lib/renderConstants.esm.js +0 -103
- package/dist/lib/renderingPipeline.esm.js +0 -99
- package/dist/lib/types.esm.js +0 -5
- package/dist/lib/variants.esm.js +0 -112
- package/dist/node_modules/@babylonjs/core/Actions/abstractActionManager.esm.js +0 -41
- package/dist/node_modules/@babylonjs/core/Actions/action.esm.js +0 -122
- package/dist/node_modules/@babylonjs/core/Actions/actionEvent.esm.js +0 -59
- package/dist/node_modules/@babylonjs/core/Actions/actionManager.esm.js +0 -335
- package/dist/node_modules/@babylonjs/core/Actions/condition.esm.js +0 -193
- package/dist/node_modules/@babylonjs/core/Actions/directActions.esm.js +0 -354
- package/dist/node_modules/@babylonjs/core/Animations/animatable.esm.js +0 -478
- package/dist/node_modules/@babylonjs/core/Animations/animation.esm.js +0 -866
- package/dist/node_modules/@babylonjs/core/Animations/animationEvent.esm.js +0 -18
- package/dist/node_modules/@babylonjs/core/Animations/animationGroup.esm.js +0 -470
- package/dist/node_modules/@babylonjs/core/Animations/animationKey.esm.js +0 -7
- package/dist/node_modules/@babylonjs/core/Animations/animationRange.esm.js +0 -21
- package/dist/node_modules/@babylonjs/core/Animations/easing.esm.js +0 -93
- package/dist/node_modules/@babylonjs/core/Animations/runtimeAnimation.esm.js +0 -281
- package/dist/node_modules/@babylonjs/core/Audio/sound.esm.js +0 -568
- package/dist/node_modules/@babylonjs/core/Audio/weightedsound.esm.js +0 -117
- package/dist/node_modules/@babylonjs/core/Behaviors/Cameras/autoRotationBehavior.esm.js +0 -145
- package/dist/node_modules/@babylonjs/core/Behaviors/Cameras/bouncingBehavior.esm.js +0 -93
- package/dist/node_modules/@babylonjs/core/Behaviors/Cameras/framingBehavior.esm.js +0 -295
- package/dist/node_modules/@babylonjs/core/Bones/bone.esm.js +0 -701
- package/dist/node_modules/@babylonjs/core/Bones/skeleton.esm.js +0 -478
- package/dist/node_modules/@babylonjs/core/Buffers/buffer.esm.js +0 -433
- package/dist/node_modules/@babylonjs/core/Buffers/dataBuffer.esm.js +0 -18
- package/dist/node_modules/@babylonjs/core/Cameras/Inputs/BaseCameraMouseWheelInput.esm.js +0 -67
- package/dist/node_modules/@babylonjs/core/Cameras/Inputs/BaseCameraPointersInput.esm.js +0 -191
- package/dist/node_modules/@babylonjs/core/Cameras/Inputs/arcRotateCameraKeyboardMoveInput.esm.js +0 -93
- package/dist/node_modules/@babylonjs/core/Cameras/Inputs/arcRotateCameraMouseWheelInput.esm.js +0 -119
- package/dist/node_modules/@babylonjs/core/Cameras/Inputs/arcRotateCameraPointersInput.esm.js +0 -119
- package/dist/node_modules/@babylonjs/core/Cameras/Inputs/freeCameraKeyboardMoveInput.esm.js +0 -108
- package/dist/node_modules/@babylonjs/core/Cameras/Inputs/freeCameraMouseInput.esm.js +0 -114
- package/dist/node_modules/@babylonjs/core/Cameras/Inputs/freeCameraMouseWheelInput.esm.js +0 -249
- package/dist/node_modules/@babylonjs/core/Cameras/Inputs/freeCameraTouchInput.esm.js +0 -103
- package/dist/node_modules/@babylonjs/core/Cameras/arcRotateCamera.esm.js +0 -589
- package/dist/node_modules/@babylonjs/core/Cameras/arcRotateCameraInputsManager.esm.js +0 -37
- package/dist/node_modules/@babylonjs/core/Cameras/camera.esm.js +0 -686
- package/dist/node_modules/@babylonjs/core/Cameras/cameraInputsManager.esm.js +0 -147
- package/dist/node_modules/@babylonjs/core/Cameras/freeCamera.esm.js +0 -236
- package/dist/node_modules/@babylonjs/core/Cameras/freeCameraInputsManager.esm.js +0 -66
- package/dist/node_modules/@babylonjs/core/Cameras/targetCamera.esm.js +0 -214
- package/dist/node_modules/@babylonjs/core/Collisions/intersectionInfo.esm.js +0 -8
- package/dist/node_modules/@babylonjs/core/Collisions/meshCollisionData.esm.js +0 -9
- package/dist/node_modules/@babylonjs/core/Collisions/pickingInfo.esm.js +0 -59
- package/dist/node_modules/@babylonjs/core/Compat/compatibilityOptions.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Culling/boundingBox.esm.js +0 -174
- package/dist/node_modules/@babylonjs/core/Culling/boundingInfo.esm.js +0 -159
- package/dist/node_modules/@babylonjs/core/Culling/boundingSphere.esm.js +0 -114
- package/dist/node_modules/@babylonjs/core/DeviceInput/InputDevices/deviceEnums.esm.js +0 -37
- package/dist/node_modules/@babylonjs/core/DeviceInput/InputDevices/deviceSource.esm.js +0 -23
- package/dist/node_modules/@babylonjs/core/DeviceInput/InputDevices/deviceSourceManager.esm.js +0 -106
- package/dist/node_modules/@babylonjs/core/DeviceInput/eventFactory.esm.js +0 -118
- package/dist/node_modules/@babylonjs/core/DeviceInput/internalDeviceSourceManager.esm.js +0 -46
- package/dist/node_modules/@babylonjs/core/DeviceInput/nativeDeviceInputSystem.esm.js +0 -50
- package/dist/node_modules/@babylonjs/core/DeviceInput/webDeviceInputSystem.esm.js +0 -354
- package/dist/node_modules/@babylonjs/core/Engines/Extensions/engine.alpha.esm.js +0 -101
- package/dist/node_modules/@babylonjs/core/Engines/Extensions/engine.cubeTexture.esm.js +0 -103
- package/dist/node_modules/@babylonjs/core/Engines/Extensions/engine.dynamicBuffer.esm.js +0 -11
- package/dist/node_modules/@babylonjs/core/Engines/Extensions/engine.dynamicTexture.esm.js +0 -14
- package/dist/node_modules/@babylonjs/core/Engines/Extensions/engine.multiRender.esm.js +0 -111
- package/dist/node_modules/@babylonjs/core/Engines/Extensions/engine.rawTexture.esm.js +0 -109
- package/dist/node_modules/@babylonjs/core/Engines/Extensions/engine.readTexture.esm.js +0 -76
- package/dist/node_modules/@babylonjs/core/Engines/Extensions/engine.renderTarget.esm.js +0 -69
- package/dist/node_modules/@babylonjs/core/Engines/Extensions/engine.renderTargetCube.esm.js +0 -15
- package/dist/node_modules/@babylonjs/core/Engines/Extensions/engine.uniformBuffer.esm.js +0 -29
- package/dist/node_modules/@babylonjs/core/Engines/Extensions/engine.views.esm.js +0 -85
- package/dist/node_modules/@babylonjs/core/Engines/Processors/Expressions/Operators/shaderDefineAndOperator.esm.js +0 -9
- package/dist/node_modules/@babylonjs/core/Engines/Processors/Expressions/Operators/shaderDefineArithmeticOperator.esm.js +0 -36
- package/dist/node_modules/@babylonjs/core/Engines/Processors/Expressions/Operators/shaderDefineIsDefinedOperator.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Engines/Processors/Expressions/Operators/shaderDefineOrOperator.esm.js +0 -9
- package/dist/node_modules/@babylonjs/core/Engines/Processors/Expressions/shaderDefineExpression.esm.js +0 -88
- package/dist/node_modules/@babylonjs/core/Engines/Processors/shaderCodeConditionNode.esm.js +0 -14
- package/dist/node_modules/@babylonjs/core/Engines/Processors/shaderCodeCursor.esm.js +0 -44
- package/dist/node_modules/@babylonjs/core/Engines/Processors/shaderCodeNode.esm.js +0 -31
- package/dist/node_modules/@babylonjs/core/Engines/Processors/shaderCodeTestNode.esm.js +0 -9
- package/dist/node_modules/@babylonjs/core/Engines/Processors/shaderProcessor.esm.js +0 -230
- package/dist/node_modules/@babylonjs/core/Engines/WebGL/webGL2ShaderProcessors.esm.js +0 -30
- package/dist/node_modules/@babylonjs/core/Engines/WebGL/webGLHardwareTexture.esm.js +0 -34
- package/dist/node_modules/@babylonjs/core/Engines/WebGL/webGLPipelineContext.esm.js +0 -388
- package/dist/node_modules/@babylonjs/core/Engines/WebGL/webGLRenderTargetWrapper.esm.js +0 -87
- package/dist/node_modules/@babylonjs/core/Engines/WebGL/webGLShaderProcessors.esm.js +0 -16
- package/dist/node_modules/@babylonjs/core/Engines/constants.esm.js +0 -254
- package/dist/node_modules/@babylonjs/core/Engines/engine.esm.js +0 -1120
- package/dist/node_modules/@babylonjs/core/Engines/engineStore.esm.js +0 -23
- package/dist/node_modules/@babylonjs/core/Engines/nullEngine.esm.js +0 -697
- package/dist/node_modules/@babylonjs/core/Engines/performanceConfigurator.esm.js +0 -22
- package/dist/node_modules/@babylonjs/core/Engines/renderTargetWrapper.esm.js +0 -273
- package/dist/node_modules/@babylonjs/core/Engines/shaderStore.esm.js +0 -36
- package/dist/node_modules/@babylonjs/core/Engines/thinEngine.esm.js +0 -2921
- package/dist/node_modules/@babylonjs/core/Events/deviceInputEvents.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Events/keyboardEvents.esm.js +0 -41
- package/dist/node_modules/@babylonjs/core/Events/pointerEvents.esm.js +0 -63
- package/dist/node_modules/@babylonjs/core/Inputs/pointerPickingConfiguration.esm.js +0 -8
- package/dist/node_modules/@babylonjs/core/Inputs/scene.inputManager.esm.js +0 -418
- package/dist/node_modules/@babylonjs/core/Layers/effectLayer.esm.js +0 -437
- package/dist/node_modules/@babylonjs/core/Layers/effectLayerSceneComponent.esm.js +0 -141
- package/dist/node_modules/@babylonjs/core/Layers/glowLayer.esm.js +0 -343
- package/dist/node_modules/@babylonjs/core/Layers/highlightLayer.esm.js +0 -396
- package/dist/node_modules/@babylonjs/core/Lights/directionalLight.esm.js +0 -224
- package/dist/node_modules/@babylonjs/core/Lights/hemisphericLight.esm.js +0 -92
- package/dist/node_modules/@babylonjs/core/Lights/light.esm.js +0 -476
- package/dist/node_modules/@babylonjs/core/Lights/lightConstants.esm.js +0 -30
- package/dist/node_modules/@babylonjs/core/Lights/pointLight.esm.js +0 -153
- package/dist/node_modules/@babylonjs/core/Lights/shadowLight.esm.js +0 -196
- package/dist/node_modules/@babylonjs/core/Lights/spotLight.esm.js +0 -287
- package/dist/node_modules/@babylonjs/core/Loading/sceneLoader.esm.js +0 -551
- package/dist/node_modules/@babylonjs/core/Loading/sceneLoaderFlags.esm.js +0 -48
- package/dist/node_modules/@babylonjs/core/Materials/PBR/pbrAnisotropicConfiguration.esm.js +0 -112
- package/dist/node_modules/@babylonjs/core/Materials/PBR/pbrBRDFConfiguration.esm.js +0 -48
- package/dist/node_modules/@babylonjs/core/Materials/PBR/pbrBaseMaterial.esm.js +0 -568
- package/dist/node_modules/@babylonjs/core/Materials/PBR/pbrClearCoatConfiguration.esm.js +0 -139
- package/dist/node_modules/@babylonjs/core/Materials/PBR/pbrIridescenceConfiguration.esm.js +0 -97
- package/dist/node_modules/@babylonjs/core/Materials/PBR/pbrMaterial.esm.js +0 -496
- package/dist/node_modules/@babylonjs/core/Materials/PBR/pbrSheenConfiguration.esm.js +0 -106
- package/dist/node_modules/@babylonjs/core/Materials/PBR/pbrSubSurfaceConfiguration.esm.js +0 -270
- package/dist/node_modules/@babylonjs/core/Materials/Textures/Filtering/hdrFiltering.esm.js +0 -103
- package/dist/node_modules/@babylonjs/core/Materials/Textures/Loaders/ddsTextureLoader.esm.js +0 -53
- package/dist/node_modules/@babylonjs/core/Materials/Textures/Loaders/envTextureLoader.esm.js +0 -51
- package/dist/node_modules/@babylonjs/core/Materials/Textures/Loaders/ktxTextureLoader.esm.js +0 -81
- package/dist/node_modules/@babylonjs/core/Materials/Textures/baseTexture.esm.js +0 -542
- package/dist/node_modules/@babylonjs/core/Materials/Textures/baseTexture.polynomial.esm.js +0 -23
- package/dist/node_modules/@babylonjs/core/Materials/Textures/cubeTexture.esm.js +0 -244
- package/dist/node_modules/@babylonjs/core/Materials/Textures/dynamicTexture.esm.js +0 -134
- package/dist/node_modules/@babylonjs/core/Materials/Textures/equiRectangularCubeTexture.esm.js +0 -89
- package/dist/node_modules/@babylonjs/core/Materials/Textures/hdrCubeTexture.esm.js +0 -175
- package/dist/node_modules/@babylonjs/core/Materials/Textures/internalTexture.esm.js +0 -150
- package/dist/node_modules/@babylonjs/core/Materials/Textures/ktx2decoderTypes.esm.js +0 -17
- package/dist/node_modules/@babylonjs/core/Materials/Textures/mirrorTexture.esm.js +0 -138
- package/dist/node_modules/@babylonjs/core/Materials/Textures/multiRenderTarget.esm.js +0 -223
- package/dist/node_modules/@babylonjs/core/Materials/Textures/rawCubeTexture.esm.js +0 -58
- package/dist/node_modules/@babylonjs/core/Materials/Textures/rawTexture.esm.js +0 -156
- package/dist/node_modules/@babylonjs/core/Materials/Textures/rawTexture2DArray.esm.js +0 -53
- package/dist/node_modules/@babylonjs/core/Materials/Textures/renderTargetTexture.esm.js +0 -605
- package/dist/node_modules/@babylonjs/core/Materials/Textures/texture.esm.js +0 -421
- package/dist/node_modules/@babylonjs/core/Materials/Textures/textureSampler.esm.js +0 -101
- package/dist/node_modules/@babylonjs/core/Materials/Textures/thinTexture.esm.js +0 -170
- package/dist/node_modules/@babylonjs/core/Materials/clipPlaneMaterialHelper.esm.js +0 -28
- package/dist/node_modules/@babylonjs/core/Materials/colorCurves.esm.js +0 -397
- package/dist/node_modules/@babylonjs/core/Materials/drawWrapper.esm.js +0 -22
- package/dist/node_modules/@babylonjs/core/Materials/effect.esm.js +0 -890
- package/dist/node_modules/@babylonjs/core/Materials/effectFallbacks.esm.js +0 -73
- package/dist/node_modules/@babylonjs/core/Materials/effectRenderer.esm.js +0 -132
- package/dist/node_modules/@babylonjs/core/Materials/imageProcessingConfiguration.esm.js +0 -428
- package/dist/node_modules/@babylonjs/core/Materials/material.detailMapConfiguration.esm.js +0 -90
- package/dist/node_modules/@babylonjs/core/Materials/material.esm.js +0 -906
- package/dist/node_modules/@babylonjs/core/Materials/materialDefines.esm.js +0 -161
- package/dist/node_modules/@babylonjs/core/Materials/materialFlags.esm.js +0 -226
- package/dist/node_modules/@babylonjs/core/Materials/materialHelper.esm.js +0 -501
- package/dist/node_modules/@babylonjs/core/Materials/materialPluginBase.esm.js +0 -226
- package/dist/node_modules/@babylonjs/core/Materials/materialPluginEvent.esm.js +0 -7
- package/dist/node_modules/@babylonjs/core/Materials/materialPluginManager.esm.js +0 -212
- package/dist/node_modules/@babylonjs/core/Materials/materialStencilState.esm.js +0 -145
- package/dist/node_modules/@babylonjs/core/Materials/multiMaterial.esm.js +0 -164
- package/dist/node_modules/@babylonjs/core/Materials/prePassConfiguration.esm.js +0 -38
- package/dist/node_modules/@babylonjs/core/Materials/pushMaterial.esm.js +0 -48
- package/dist/node_modules/@babylonjs/core/Materials/shaderLanguage.esm.js +0 -7
- package/dist/node_modules/@babylonjs/core/Materials/shaderMaterial.esm.js +0 -838
- package/dist/node_modules/@babylonjs/core/Materials/standardMaterial.esm.js +0 -934
- package/dist/node_modules/@babylonjs/core/Materials/uniformBuffer.esm.js +0 -541
- package/dist/node_modules/@babylonjs/core/Maths/math.axis.esm.js +0 -19
- package/dist/node_modules/@babylonjs/core/Maths/math.color.esm.js +0 -903
- package/dist/node_modules/@babylonjs/core/Maths/math.constants.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Maths/math.frustum.esm.js +0 -91
- package/dist/node_modules/@babylonjs/core/Maths/math.functions.esm.js +0 -43
- package/dist/node_modules/@babylonjs/core/Maths/math.path.esm.js +0 -9
- package/dist/node_modules/@babylonjs/core/Maths/math.plane.esm.js +0 -145
- package/dist/node_modules/@babylonjs/core/Maths/math.scalar.esm.js +0 -284
- package/dist/node_modules/@babylonjs/core/Maths/math.size.esm.js +0 -124
- package/dist/node_modules/@babylonjs/core/Maths/math.vector.esm.js +0 -4915
- package/dist/node_modules/@babylonjs/core/Maths/math.viewport.esm.js +0 -41
- package/dist/node_modules/@babylonjs/core/Maths/sphericalPolynomial.esm.js +0 -177
- package/dist/node_modules/@babylonjs/core/Meshes/Builders/boxBuilder.esm.js +0 -260
- package/dist/node_modules/@babylonjs/core/Meshes/Compression/dracoCompression.esm.js +0 -233
- package/dist/node_modules/@babylonjs/core/Meshes/Compression/meshoptCompression.esm.js +0 -47
- package/dist/node_modules/@babylonjs/core/Meshes/WebGL/webGLDataBuffer.esm.js +0 -12
- package/dist/node_modules/@babylonjs/core/Meshes/abstractMesh.esm.js +0 -1448
- package/dist/node_modules/@babylonjs/core/Meshes/geometry.esm.js +0 -729
- package/dist/node_modules/@babylonjs/core/Meshes/instancedMesh.esm.js +0 -455
- package/dist/node_modules/@babylonjs/core/Meshes/mesh.esm.js +0 -2526
- package/dist/node_modules/@babylonjs/core/Meshes/mesh.vertexData.esm.js +0 -865
- package/dist/node_modules/@babylonjs/core/Meshes/meshLODLevel.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Meshes/subMesh.esm.js +0 -422
- package/dist/node_modules/@babylonjs/core/Meshes/thinInstanceMesh.esm.js +0 -129
- package/dist/node_modules/@babylonjs/core/Meshes/transformNode.esm.js +0 -796
- package/dist/node_modules/@babylonjs/core/Misc/HighDynamicRange/cubemapToSphericalPolynomial.esm.js +0 -111
- package/dist/node_modules/@babylonjs/core/Misc/HighDynamicRange/hdr.esm.js +0 -122
- package/dist/node_modules/@babylonjs/core/Misc/HighDynamicRange/panoramaToCubemap.esm.js +0 -78
- package/dist/node_modules/@babylonjs/core/Misc/andOrNotEvaluator.esm.js +0 -41
- package/dist/node_modules/@babylonjs/core/Misc/arrayTools.esm.js +0 -52
- package/dist/node_modules/@babylonjs/core/Misc/assetsManager.esm.js +0 -561
- package/dist/node_modules/@babylonjs/core/Misc/brdfTextureTools.esm.js +0 -31
- package/dist/node_modules/@babylonjs/core/Misc/copyTools.esm.js +0 -44
- package/dist/node_modules/@babylonjs/core/Misc/coroutine.esm.js +0 -53
- package/dist/node_modules/@babylonjs/core/Misc/dataReader.esm.js +0 -55
- package/dist/node_modules/@babylonjs/core/Misc/dds.esm.js +0 -329
- package/dist/node_modules/@babylonjs/core/Misc/decorators.esm.js +0 -332
- package/dist/node_modules/@babylonjs/core/Misc/deepCopier.esm.js +0 -52
- package/dist/node_modules/@babylonjs/core/Misc/deferred.esm.js +0 -25
- package/dist/node_modules/@babylonjs/core/Misc/devTools.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Misc/domManagement.esm.js +0 -21
- package/dist/node_modules/@babylonjs/core/Misc/dumpTools.esm.js +0 -117
- package/dist/node_modules/@babylonjs/core/Misc/environmentTextureTools.esm.js +0 -187
- package/dist/node_modules/@babylonjs/core/Misc/error.esm.js +0 -40
- package/dist/node_modules/@babylonjs/core/Misc/fileTools.esm.js +0 -339
- package/dist/node_modules/@babylonjs/core/Misc/filesInputStore.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Misc/guid.esm.js +0 -9
- package/dist/node_modules/@babylonjs/core/Misc/instantiationTools.esm.js +0 -26
- package/dist/node_modules/@babylonjs/core/Misc/khronosTextureContainer.esm.js +0 -79
- package/dist/node_modules/@babylonjs/core/Misc/khronosTextureContainer2.esm.js +0 -281
- package/dist/node_modules/@babylonjs/core/Misc/logger.esm.js +0 -77
- package/dist/node_modules/@babylonjs/core/Misc/observable.esm.js +0 -231
- package/dist/node_modules/@babylonjs/core/Misc/perfCounter.esm.js +0 -99
- package/dist/node_modules/@babylonjs/core/Misc/performanceMonitor.esm.js +0 -144
- package/dist/node_modules/@babylonjs/core/Misc/precisionDate.esm.js +0 -12
- package/dist/node_modules/@babylonjs/core/Misc/retryStrategy.esm.js +0 -14
- package/dist/node_modules/@babylonjs/core/Misc/rgbdTextureTools.esm.js +0 -51
- package/dist/node_modules/@babylonjs/core/Misc/screenshotTools.esm.js +0 -92
- package/dist/node_modules/@babylonjs/core/Misc/smartArray.esm.js +0 -118
- package/dist/node_modules/@babylonjs/core/Misc/stringDictionary.esm.js +0 -129
- package/dist/node_modules/@babylonjs/core/Misc/stringTools.esm.js +0 -26
- package/dist/node_modules/@babylonjs/core/Misc/tags.esm.js +0 -97
- package/dist/node_modules/@babylonjs/core/Misc/textureTools.esm.js +0 -41
- package/dist/node_modules/@babylonjs/core/Misc/timingTools.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Misc/tools.esm.js +0 -929
- package/dist/node_modules/@babylonjs/core/Misc/typeStore.esm.js +0 -11
- package/dist/node_modules/@babylonjs/core/Misc/uniqueIdGenerator.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Misc/webRequest.esm.js +0 -135
- package/dist/node_modules/@babylonjs/core/Misc/workerPool.esm.js +0 -80
- package/dist/node_modules/@babylonjs/core/Morph/morphTarget.esm.js +0 -187
- package/dist/node_modules/@babylonjs/core/Morph/morphTargetManager.esm.js +0 -249
- package/dist/node_modules/@babylonjs/core/PostProcesses/RenderPipeline/Pipelines/defaultRenderingPipeline.esm.js +0 -349
- package/dist/node_modules/@babylonjs/core/PostProcesses/RenderPipeline/Pipelines/ssao2RenderingPipeline.esm.js +0 -306
- package/dist/node_modules/@babylonjs/core/PostProcesses/RenderPipeline/Pipelines/ssaoRenderingPipeline.esm.js +0 -161
- package/dist/node_modules/@babylonjs/core/PostProcesses/RenderPipeline/Pipelines/ssrRenderingPipeline.esm.js +0 -589
- package/dist/node_modules/@babylonjs/core/PostProcesses/RenderPipeline/Pipelines/standardRenderingPipeline.esm.js +0 -512
- package/dist/node_modules/@babylonjs/core/PostProcesses/RenderPipeline/postProcessRenderEffect.esm.js +0 -114
- package/dist/node_modules/@babylonjs/core/PostProcesses/RenderPipeline/postProcessRenderPipeline.esm.js +0 -139
- package/dist/node_modules/@babylonjs/core/PostProcesses/RenderPipeline/postProcessRenderPipelineManager.esm.js +0 -99
- package/dist/node_modules/@babylonjs/core/PostProcesses/RenderPipeline/postProcessRenderPipelineManagerSceneComponent.esm.js +0 -48
- package/dist/node_modules/@babylonjs/core/PostProcesses/bloomEffect.esm.js +0 -76
- package/dist/node_modules/@babylonjs/core/PostProcesses/bloomMergePostProcess.esm.js +0 -40
- package/dist/node_modules/@babylonjs/core/PostProcesses/blurPostProcess.esm.js +0 -165
- package/dist/node_modules/@babylonjs/core/PostProcesses/chromaticAberrationPostProcess.esm.js +0 -61
- package/dist/node_modules/@babylonjs/core/PostProcesses/circleOfConfusionPostProcess.esm.js +0 -62
- package/dist/node_modules/@babylonjs/core/PostProcesses/depthOfFieldBlurPostProcess.esm.js +0 -58
- package/dist/node_modules/@babylonjs/core/PostProcesses/depthOfFieldEffect.esm.js +0 -131
- package/dist/node_modules/@babylonjs/core/PostProcesses/depthOfFieldMergePostProcess.esm.js +0 -48
- package/dist/node_modules/@babylonjs/core/PostProcesses/extractHighlightsPostProcess.esm.js +0 -27
- package/dist/node_modules/@babylonjs/core/PostProcesses/fxaaPostProcess.esm.js +0 -41
- package/dist/node_modules/@babylonjs/core/PostProcesses/grainPostProcess.esm.js +0 -46
- package/dist/node_modules/@babylonjs/core/PostProcesses/imageProcessingPostProcess.esm.js +0 -359
- package/dist/node_modules/@babylonjs/core/PostProcesses/motionBlurPostProcess.esm.js +0 -178
- package/dist/node_modules/@babylonjs/core/PostProcesses/passPostProcess.esm.js +0 -40
- package/dist/node_modules/@babylonjs/core/PostProcesses/postProcess.esm.js +0 -457
- package/dist/node_modules/@babylonjs/core/PostProcesses/postProcessManager.esm.js +0 -94
- package/dist/node_modules/@babylonjs/core/PostProcesses/screenSpaceReflectionPostProcess.esm.js +0 -147
- package/dist/node_modules/@babylonjs/core/PostProcesses/sharpenPostProcess.esm.js +0 -46
- package/dist/node_modules/@babylonjs/core/Probes/reflectionProbe.esm.js +0 -184
- package/dist/node_modules/@babylonjs/core/Rendering/boundingBoxRenderer.esm.js +0 -170
- package/dist/node_modules/@babylonjs/core/Rendering/depthRenderer.esm.js +0 -185
- package/dist/node_modules/@babylonjs/core/Rendering/depthRendererSceneComponent.esm.js +0 -65
- package/dist/node_modules/@babylonjs/core/Rendering/geometryBufferRenderer.esm.js +0 -353
- package/dist/node_modules/@babylonjs/core/Rendering/geometryBufferRendererSceneComponent.esm.js +0 -55
- package/dist/node_modules/@babylonjs/core/Rendering/motionBlurConfiguration.esm.js +0 -8
- package/dist/node_modules/@babylonjs/core/Rendering/renderingGroup.esm.js +0 -223
- package/dist/node_modules/@babylonjs/core/Rendering/renderingManager.esm.js +0 -185
- package/dist/node_modules/@babylonjs/core/Rendering/screenSpaceReflections2Configuration.esm.js +0 -8
- package/dist/node_modules/@babylonjs/core/Rendering/screenSpaceReflectionsConfiguration.esm.js +0 -8
- package/dist/node_modules/@babylonjs/core/Rendering/ssao2Configuration.esm.js +0 -8
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/bakedVertexAnimation.esm.js +0 -48
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/bakedVertexAnimationDeclaration.esm.js +0 -24
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/bonesDeclaration.esm.js +0 -35
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/bonesVertex.esm.js +0 -56
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/boundingBoxRendererFragmentDeclaration.esm.js +0 -4
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/boundingBoxRendererUboDeclaration.esm.js +0 -19
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/boundingBoxRendererVertexDeclaration.esm.js +0 -8
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/bumpFragment.esm.js +0 -67
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/bumpFragmentFunctions.esm.js +0 -58
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/bumpFragmentMainFunctions.esm.js +0 -93
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/bumpVertex.esm.js +0 -11
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/bumpVertexDeclaration.esm.js +0 -8
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/clipPlaneFragment.esm.js +0 -42
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/clipPlaneFragmentDeclaration.esm.js +0 -21
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/clipPlaneVertex.esm.js +0 -21
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/clipPlaneVertexDeclaration.esm.js +0 -27
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/decalFragment.esm.js +0 -12
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/decalFragmentDeclaration.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/decalVertexDeclaration.esm.js +0 -7
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/defaultFragmentDeclaration.esm.js +0 -86
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/defaultUboDeclaration.esm.js +0 -50
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/defaultVertexDeclaration.esm.js +0 -46
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/depthPrePass.esm.js +0 -7
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/fogFragment.esm.js +0 -10
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/fogFragmentDeclaration.esm.js +0 -34
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/fogVertex.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/fogVertexDeclaration.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/fresnelFunction.esm.js +0 -10
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/geometryUboDeclaration.esm.js +0 -5
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/geometryVertexDeclaration.esm.js +0 -4
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/harmonicsFunctions.esm.js +0 -42
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/hdrFilteringFunctions.esm.js +0 -139
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/helperFunctions.esm.js +0 -166
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/imageProcessingDeclaration.esm.js +0 -32
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/imageProcessingFunctions.esm.js +0 -129
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/importanceSampling.esm.js +0 -22
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/instancesDeclaration.esm.js +0 -31
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/instancesVertex.esm.js +0 -20
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/kernelBlurFragment.esm.js +0 -15
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/kernelBlurFragment2.esm.js +0 -15
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/kernelBlurVaryingDeclaration.esm.js +0 -3
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/kernelBlurVertex.esm.js +0 -3
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/lightFragment.esm.js +0 -278
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/lightFragmentDeclaration.esm.js +0 -82
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/lightUboDeclaration.esm.js +0 -81
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/lightVxFragmentDeclaration.esm.js +0 -35
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/lightVxUboDeclaration.esm.js +0 -34
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/lightsFragmentFunctions.esm.js +0 -93
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/logDepthDeclaration.esm.js +0 -7
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/logDepthFragment.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/logDepthVertex.esm.js +0 -7
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/mainUVVaryingDeclaration.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/meshUboDeclaration.esm.js +0 -15
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/morphTargetsVertex.esm.js +0 -32
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/morphTargetsVertexDeclaration.esm.js +0 -17
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/morphTargetsVertexGlobal.esm.js +0 -8
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/morphTargetsVertexGlobalDeclaration.esm.js +0 -19
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/mrtFragmentDeclaration.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/oitDeclaration.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/oitFragment.esm.js +0 -40
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/packingFunctions.esm.js +0 -15
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBRDFFunctions.esm.js +0 -268
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockAlbedoOpacity.esm.js +0 -83
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockAlphaFresnel.esm.js +0 -37
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockAmbientOcclusion.esm.js +0 -32
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockAnisotropic.esm.js +0 -50
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockClearcoat.esm.js +0 -276
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockDirectLighting.esm.js +0 -19
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockFinalColorComposition.esm.js +0 -45
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockFinalLitComponents.esm.js +0 -100
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockFinalUnlitComponents.esm.js +0 -27
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockGeometryInfo.esm.js +0 -30
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockImageProcessing.esm.js +0 -14
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockIridescence.esm.js +0 -63
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockLightmapInit.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockNormalFinal.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockNormalGeometric.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockReflectance.esm.js +0 -24
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockReflectance0.esm.js +0 -14
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockReflection.esm.js +0 -270
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockReflectivity.esm.js +0 -131
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockSheen.esm.js +0 -197
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrBlockSubSurface.esm.js +0 -337
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrDebug.esm.js +0 -176
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrDirectLightingFalloffFunctions.esm.js +0 -64
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrDirectLightingFunctions.esm.js +0 -130
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrDirectLightingSetupFunctions.esm.js +0 -53
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrFragmentDeclaration.esm.js +0 -179
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrFragmentExtraDeclaration.esm.js +0 -18
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrFragmentSamplersDeclaration.esm.js +0 -101
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrHelperFunctions.esm.js +0 -83
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrIBLFunctions.esm.js +0 -35
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrUboDeclaration.esm.js +0 -65
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pbrVertexDeclaration.esm.js +0 -151
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/pointCloudVertex.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/prePassDeclaration.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/prePassVertex.esm.js +0 -37
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/prePassVertexDeclaration.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/reflectionFunction.esm.js +0 -116
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/samplerFragmentAlternateDeclaration.esm.js +0 -20
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/samplerFragmentDeclaration.esm.js +0 -21
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/samplerVertexDeclaration.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/samplerVertexImplementation.esm.js +0 -39
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/sceneUboDeclaration.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/screenSpaceRayTrace.esm.js +0 -208
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/shadowsFragmentFunctions.esm.js +0 -614
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/shadowsVertex.esm.js +0 -23
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/subSurfaceScatteringFunctions.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/uvAttributeDeclaration.esm.js +0 -6
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/uvVariableDeclaration.esm.js +0 -9
- package/dist/node_modules/@babylonjs/core/Shaders/ShadersInclude/vertexColorMixing.esm.js +0 -16
- package/dist/node_modules/@babylonjs/core/Shaders/bloomMerge.fragment.esm.js +0 -14
- package/dist/node_modules/@babylonjs/core/Shaders/boundingBoxRenderer.fragment.esm.js +0 -11
- package/dist/node_modules/@babylonjs/core/Shaders/boundingBoxRenderer.vertex.esm.js +0 -22
- package/dist/node_modules/@babylonjs/core/Shaders/chromaticAberration.fragment.esm.js +0 -34
- package/dist/node_modules/@babylonjs/core/Shaders/circleOfConfusion.fragment.esm.js +0 -19
- package/dist/node_modules/@babylonjs/core/Shaders/default.fragment.esm.js +0 -387
- package/dist/node_modules/@babylonjs/core/Shaders/default.vertex.esm.js +0 -171
- package/dist/node_modules/@babylonjs/core/Shaders/depth.fragment.esm.js +0 -47
- package/dist/node_modules/@babylonjs/core/Shaders/depth.vertex.esm.js +0 -72
- package/dist/node_modules/@babylonjs/core/Shaders/depthOfField.fragment.esm.js +0 -137
- package/dist/node_modules/@babylonjs/core/Shaders/depthOfFieldMerge.fragment.esm.js +0 -54
- package/dist/node_modules/@babylonjs/core/Shaders/extractHighlights.fragment.esm.js +0 -15
- package/dist/node_modules/@babylonjs/core/Shaders/fxaa.fragment.esm.js +0 -211
- package/dist/node_modules/@babylonjs/core/Shaders/fxaa.vertex.esm.js +0 -29
- package/dist/node_modules/@babylonjs/core/Shaders/geometry.fragment.esm.js +0 -147
- package/dist/node_modules/@babylonjs/core/Shaders/geometry.vertex.esm.js +0 -164
- package/dist/node_modules/@babylonjs/core/Shaders/glowBlurPostProcess.fragment.esm.js +0 -39
- package/dist/node_modules/@babylonjs/core/Shaders/glowMapGeneration.fragment.esm.js +0 -73
- package/dist/node_modules/@babylonjs/core/Shaders/glowMapGeneration.vertex.esm.js +0 -94
- package/dist/node_modules/@babylonjs/core/Shaders/glowMapMerge.fragment.esm.js +0 -29
- package/dist/node_modules/@babylonjs/core/Shaders/glowMapMerge.vertex.esm.js +0 -12
- package/dist/node_modules/@babylonjs/core/Shaders/grain.fragment.esm.js +0 -19
- package/dist/node_modules/@babylonjs/core/Shaders/hdrFiltering.fragment.esm.js +0 -19
- package/dist/node_modules/@babylonjs/core/Shaders/hdrFiltering.vertex.esm.js +0 -15
- package/dist/node_modules/@babylonjs/core/Shaders/imageProcessing.fragment.esm.js +0 -26
- package/dist/node_modules/@babylonjs/core/Shaders/kernelBlur.fragment.esm.js +0 -49
- package/dist/node_modules/@babylonjs/core/Shaders/kernelBlur.vertex.esm.js +0 -17
- package/dist/node_modules/@babylonjs/core/Shaders/lensHighlights.fragment.esm.js +0 -115
- package/dist/node_modules/@babylonjs/core/Shaders/motionBlur.fragment.esm.js +0 -74
- package/dist/node_modules/@babylonjs/core/Shaders/pass.fragment.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Shaders/passCube.fragment.esm.js +0 -27
- package/dist/node_modules/@babylonjs/core/Shaders/pbr.fragment.esm.js +0 -648
- package/dist/node_modules/@babylonjs/core/Shaders/pbr.vertex.esm.js +0 -236
- package/dist/node_modules/@babylonjs/core/Shaders/postprocess.vertex.esm.js +0 -13
- package/dist/node_modules/@babylonjs/core/Shaders/rgbdDecode.fragment.esm.js +0 -11
- package/dist/node_modules/@babylonjs/core/Shaders/rgbdEncode.fragment.esm.js +0 -11
- package/dist/node_modules/@babylonjs/core/Shaders/screenSpaceReflection.fragment.esm.js +0 -136
- package/dist/node_modules/@babylonjs/core/Shaders/screenSpaceReflection2.fragment.esm.js +0 -215
- package/dist/node_modules/@babylonjs/core/Shaders/screenSpaceReflection2Blur.fragment.esm.js +0 -52
- package/dist/node_modules/@babylonjs/core/Shaders/screenSpaceReflection2BlurCombiner.fragment.esm.js +0 -59
- package/dist/node_modules/@babylonjs/core/Shaders/sharpen.fragment.esm.js +0 -18
- package/dist/node_modules/@babylonjs/core/Shaders/ssao.fragment.esm.js +0 -55
- package/dist/node_modules/@babylonjs/core/Shaders/ssao2.fragment.esm.js +0 -165
- package/dist/node_modules/@babylonjs/core/Shaders/ssaoCombine.fragment.esm.js +0 -15
- package/dist/node_modules/@babylonjs/core/Shaders/standard.fragment.esm.js +0 -339
- package/dist/node_modules/@babylonjs/core/States/alphaCullingState.esm.js +0 -35
- package/dist/node_modules/@babylonjs/core/States/depthCullingState.esm.js +0 -69
- package/dist/node_modules/@babylonjs/core/States/stencilState.esm.js +0 -62
- package/dist/node_modules/@babylonjs/core/States/stencilStateComposer.esm.js +0 -70
- package/dist/node_modules/@babylonjs/core/abstractScene.esm.js +0 -71
- package/dist/node_modules/@babylonjs/core/assetContainer.esm.js +0 -425
- package/dist/node_modules/@babylonjs/core/node.esm.js +0 -536
- package/dist/node_modules/@babylonjs/core/scene.esm.js +0 -2809
- package/dist/node_modules/@babylonjs/core/sceneComponent.esm.js +0 -102
- package/dist/node_modules/@babylonjs/core/tslib.es6.esm.js +0 -12
- package/dist/node_modules/@babylonjs/loaders/glTF/1.0/glTFBinaryExtension.esm.js +0 -37
- package/dist/node_modules/@babylonjs/loaders/glTF/1.0/glTFLoader.esm.js +0 -902
- package/dist/node_modules/@babylonjs/loaders/glTF/1.0/glTFLoaderInterfaces.esm.js +0 -42
- package/dist/node_modules/@babylonjs/loaders/glTF/1.0/glTFLoaderUtils.esm.js +0 -195
- package/dist/node_modules/@babylonjs/loaders/glTF/1.0/glTFMaterialsCommonExtension.esm.js +0 -75
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/EXT_lights_image_based.esm.js +0 -77
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/EXT_mesh_gpu_instancing.esm.js +0 -53
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/EXT_meshopt_compression.esm.js +0 -31
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/EXT_texture_webp.esm.js +0 -29
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/ExtrasAsMetadata.esm.js +0 -47
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_animation_pointer.data.esm.js +0 -173
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_animation_pointer.esm.js +0 -82
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_draco_mesh_compression.esm.js +0 -68
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_lights_punctual.esm.js +0 -60
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_anisotropy.esm.js +0 -39
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_clearcoat.esm.js +0 -42
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_emissive_strength.esm.js +0 -32
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_ior.esm.js +0 -35
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_iridescence.esm.js +0 -41
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_pbrSpecularGlossiness.esm.js +0 -41
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_sheen.esm.js +0 -41
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_specular.esm.js +0 -41
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_translucency.esm.js +0 -41
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_transmission.esm.js +0 -136
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_unlit.esm.js +0 -37
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_variants.esm.js +0 -178
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_materials_volume.esm.js +0 -40
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_mesh_quantization.esm.js +0 -17
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_texture_basisu.esm.js +0 -29
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_texture_transform.esm.js +0 -29
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/KHR_xmp_json_ld.esm.js +0 -31
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/MSFT_audio_emitter.esm.js +0 -149
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/MSFT_lod.esm.js +0 -170
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/MSFT_minecraftMesh.esm.js +0 -29
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/Extensions/MSFT_sRGBFactors.esm.js +0 -29
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/glTFLoader.esm.js +0 -1562
- package/dist/node_modules/@babylonjs/loaders/glTF/2.0/glTFLoaderAnimation.esm.js +0 -66
- package/dist/node_modules/@babylonjs/loaders/glTF/glTFFileLoader.esm.js +0 -462
- package/dist/node_modules/@babylonjs/loaders/glTF/glTFValidation.esm.js +0 -81
|
@@ -1,838 +0,0 @@
|
|
|
1
|
-
import { SerializationHelper as E } from "../Misc/decorators.esm.js";
|
|
2
|
-
import { Matrix as O, Vector2 as j, Vector3 as q, Vector4 as W, Quaternion as L } from "../Maths/math.vector.esm.js";
|
|
3
|
-
import { VertexBuffer as l } from "../Buffers/buffer.esm.js";
|
|
4
|
-
import { Texture as C } from "./Textures/texture.esm.js";
|
|
5
|
-
import { MaterialHelper as g } from "./materialHelper.esm.js";
|
|
6
|
-
import { RegisterClass as z } from "../Misc/typeStore.esm.js";
|
|
7
|
-
import { Color3 as V, Color4 as N } from "../Maths/math.color.esm.js";
|
|
8
|
-
import { EffectFallbacks as H } from "./effectFallbacks.esm.js";
|
|
9
|
-
import { WebRequest as R } from "../Misc/webRequest.esm.js";
|
|
10
|
-
import { PushMaterial as K } from "./pushMaterial.esm.js";
|
|
11
|
-
import { EngineStore as I } from "../Engines/engineStore.esm.js";
|
|
12
|
-
import { addClipPlaneUniforms as G, prepareStringDefinesForClipPlanes as D, bindClipPlane as Q } from "./clipPlaneMaterialHelper.esm.js";
|
|
13
|
-
const k = { effect: null, subMesh: null };
|
|
14
|
-
class x extends K {
|
|
15
|
-
/**
|
|
16
|
-
* Instantiate a new shader material.
|
|
17
|
-
* The ShaderMaterial object has the necessary methods to pass data from your scene to the Vertex and Fragment Shaders and returns a material that can be applied to any mesh.
|
|
18
|
-
* This returned material effects how the mesh will look based on the code in the shaders.
|
|
19
|
-
* @see https://doc.babylonjs.com/features/featuresDeepDive/materials/shaders/shaderMaterial
|
|
20
|
-
* @param name Define the name of the material in the scene
|
|
21
|
-
* @param scene Define the scene the material belongs to
|
|
22
|
-
* @param shaderPath Defines the route to the shader code in one of three ways:
|
|
23
|
-
* * object: \{ vertex: "custom", fragment: "custom" \}, used with Effect.ShadersStore["customVertexShader"] and Effect.ShadersStore["customFragmentShader"]
|
|
24
|
-
* * object: \{ vertexElement: "vertexShaderCode", fragmentElement: "fragmentShaderCode" \}, used with shader code in script tags
|
|
25
|
-
* * object: \{ vertexSource: "vertex shader code string", fragmentSource: "fragment shader code string" \} using with strings containing the shaders code
|
|
26
|
-
* * string: "./COMMON_NAME", used with external files COMMON_NAME.vertex.fx and COMMON_NAME.fragment.fx in index.html folder.
|
|
27
|
-
* @param options Define the options used to create the shader
|
|
28
|
-
* @param storeEffectOnSubMeshes true to store effect on submeshes, false to store the effect directly in the material class.
|
|
29
|
-
*/
|
|
30
|
-
constructor(t, s, e, o = {}, i = !0) {
|
|
31
|
-
super(t, s, i), this._textures = {}, this._textureArrays = {}, this._externalTextures = {}, this._floats = {}, this._ints = {}, this._uints = {}, this._floatsArrays = {}, this._colors3 = {}, this._colors3Arrays = {}, this._colors4 = {}, this._colors4Arrays = {}, this._vectors2 = {}, this._vectors3 = {}, this._vectors4 = {}, this._quaternions = {}, this._quaternionsArrays = {}, this._matrices = {}, this._matrixArrays = {}, this._matrices3x3 = {}, this._matrices2x2 = {}, this._vectors2Arrays = {}, this._vectors3Arrays = {}, this._vectors4Arrays = {}, this._uniformBuffers = {}, this._textureSamplers = {}, this._storageBuffers = {}, this._cachedWorldViewMatrix = new O(), this._cachedWorldViewProjectionMatrix = new O(), this._multiview = !1, this._materialHelperNeedsPreviousMatrices = !1, this._shaderPath = e, this._options = Object.assign({ needAlphaBlending: !1, needAlphaTesting: !1, attributes: ["position", "normal", "uv"], uniforms: ["worldViewProjection"], uniformBuffers: [], samplers: [], externalTextures: [], samplerObjects: [], storageBuffers: [], defines: [], useClipPlane: !1 }, o);
|
|
32
|
-
}
|
|
33
|
-
/**
|
|
34
|
-
* Gets the shader path used to define the shader code
|
|
35
|
-
* It can be modified to trigger a new compilation
|
|
36
|
-
*/
|
|
37
|
-
get shaderPath() {
|
|
38
|
-
return this._shaderPath;
|
|
39
|
-
}
|
|
40
|
-
/**
|
|
41
|
-
* Sets the shader path used to define the shader code
|
|
42
|
-
* It can be modified to trigger a new compilation
|
|
43
|
-
*/
|
|
44
|
-
set shaderPath(t) {
|
|
45
|
-
this._shaderPath = t;
|
|
46
|
-
}
|
|
47
|
-
/**
|
|
48
|
-
* Gets the options used to compile the shader.
|
|
49
|
-
* They can be modified to trigger a new compilation
|
|
50
|
-
*/
|
|
51
|
-
get options() {
|
|
52
|
-
return this._options;
|
|
53
|
-
}
|
|
54
|
-
/**
|
|
55
|
-
* is multiview set to true?
|
|
56
|
-
*/
|
|
57
|
-
get isMultiview() {
|
|
58
|
-
return this._multiview;
|
|
59
|
-
}
|
|
60
|
-
/**
|
|
61
|
-
* Gets the current class name of the material e.g. "ShaderMaterial"
|
|
62
|
-
* Mainly use in serialization.
|
|
63
|
-
* @returns the class name
|
|
64
|
-
*/
|
|
65
|
-
getClassName() {
|
|
66
|
-
return "ShaderMaterial";
|
|
67
|
-
}
|
|
68
|
-
/**
|
|
69
|
-
* Specifies if the material will require alpha blending
|
|
70
|
-
* @returns a boolean specifying if alpha blending is needed
|
|
71
|
-
*/
|
|
72
|
-
needAlphaBlending() {
|
|
73
|
-
return this.alpha < 1 || this._options.needAlphaBlending;
|
|
74
|
-
}
|
|
75
|
-
/**
|
|
76
|
-
* Specifies if this material should be rendered in alpha test mode
|
|
77
|
-
* @returns a boolean specifying if an alpha test is needed.
|
|
78
|
-
*/
|
|
79
|
-
needAlphaTesting() {
|
|
80
|
-
return this._options.needAlphaTesting;
|
|
81
|
-
}
|
|
82
|
-
_checkUniform(t) {
|
|
83
|
-
this._options.uniforms.indexOf(t) === -1 && this._options.uniforms.push(t);
|
|
84
|
-
}
|
|
85
|
-
/**
|
|
86
|
-
* Set a texture in the shader.
|
|
87
|
-
* @param name Define the name of the uniform samplers as defined in the shader
|
|
88
|
-
* @param texture Define the texture to bind to this sampler
|
|
89
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
90
|
-
*/
|
|
91
|
-
setTexture(t, s) {
|
|
92
|
-
return this._options.samplers.indexOf(t) === -1 && this._options.samplers.push(t), this._textures[t] = s, this;
|
|
93
|
-
}
|
|
94
|
-
/**
|
|
95
|
-
* Set a texture array in the shader.
|
|
96
|
-
* @param name Define the name of the uniform sampler array as defined in the shader
|
|
97
|
-
* @param textures Define the list of textures to bind to this sampler
|
|
98
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
99
|
-
*/
|
|
100
|
-
setTextureArray(t, s) {
|
|
101
|
-
return this._options.samplers.indexOf(t) === -1 && this._options.samplers.push(t), this._checkUniform(t), this._textureArrays[t] = s, this;
|
|
102
|
-
}
|
|
103
|
-
/**
|
|
104
|
-
* Set an internal texture in the shader.
|
|
105
|
-
* @param name Define the name of the uniform samplers as defined in the shader
|
|
106
|
-
* @param texture Define the texture to bind to this sampler
|
|
107
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
108
|
-
*/
|
|
109
|
-
setExternalTexture(t, s) {
|
|
110
|
-
return this._options.externalTextures.indexOf(t) === -1 && this._options.externalTextures.push(t), this._externalTextures[t] = s, this;
|
|
111
|
-
}
|
|
112
|
-
/**
|
|
113
|
-
* Set a float in the shader.
|
|
114
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
115
|
-
* @param value Define the value to give to the uniform
|
|
116
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
117
|
-
*/
|
|
118
|
-
setFloat(t, s) {
|
|
119
|
-
return this._checkUniform(t), this._floats[t] = s, this;
|
|
120
|
-
}
|
|
121
|
-
/**
|
|
122
|
-
* Set a int in the shader.
|
|
123
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
124
|
-
* @param value Define the value to give to the uniform
|
|
125
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
126
|
-
*/
|
|
127
|
-
setInt(t, s) {
|
|
128
|
-
return this._checkUniform(t), this._ints[t] = s, this;
|
|
129
|
-
}
|
|
130
|
-
/**
|
|
131
|
-
* Set a unsigned int in the shader.
|
|
132
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
133
|
-
* @param value Define the value to give to the uniform
|
|
134
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
135
|
-
*/
|
|
136
|
-
setUInt(t, s) {
|
|
137
|
-
return this._checkUniform(t), this._uints[t] = s, this;
|
|
138
|
-
}
|
|
139
|
-
/**
|
|
140
|
-
* Set an array of floats in the shader.
|
|
141
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
142
|
-
* @param value Define the value to give to the uniform
|
|
143
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
144
|
-
*/
|
|
145
|
-
setFloats(t, s) {
|
|
146
|
-
return this._checkUniform(t), this._floatsArrays[t] = s, this;
|
|
147
|
-
}
|
|
148
|
-
/**
|
|
149
|
-
* Set a vec3 in the shader from a Color3.
|
|
150
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
151
|
-
* @param value Define the value to give to the uniform
|
|
152
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
153
|
-
*/
|
|
154
|
-
setColor3(t, s) {
|
|
155
|
-
return this._checkUniform(t), this._colors3[t] = s, this;
|
|
156
|
-
}
|
|
157
|
-
/**
|
|
158
|
-
* Set a vec3 array in the shader from a Color3 array.
|
|
159
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
160
|
-
* @param value Define the value to give to the uniform
|
|
161
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
162
|
-
*/
|
|
163
|
-
setColor3Array(t, s) {
|
|
164
|
-
return this._checkUniform(t), this._colors3Arrays[t] = s.reduce((e, o) => (o.toArray(e, e.length), e), []), this;
|
|
165
|
-
}
|
|
166
|
-
/**
|
|
167
|
-
* Set a vec4 in the shader from a Color4.
|
|
168
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
169
|
-
* @param value Define the value to give to the uniform
|
|
170
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
171
|
-
*/
|
|
172
|
-
setColor4(t, s) {
|
|
173
|
-
return this._checkUniform(t), this._colors4[t] = s, this;
|
|
174
|
-
}
|
|
175
|
-
/**
|
|
176
|
-
* Set a vec4 array in the shader from a Color4 array.
|
|
177
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
178
|
-
* @param value Define the value to give to the uniform
|
|
179
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
180
|
-
*/
|
|
181
|
-
setColor4Array(t, s) {
|
|
182
|
-
return this._checkUniform(t), this._colors4Arrays[t] = s.reduce((e, o) => (o.toArray(e, e.length), e), []), this;
|
|
183
|
-
}
|
|
184
|
-
/**
|
|
185
|
-
* Set a vec2 in the shader from a Vector2.
|
|
186
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
187
|
-
* @param value Define the value to give to the uniform
|
|
188
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
189
|
-
*/
|
|
190
|
-
setVector2(t, s) {
|
|
191
|
-
return this._checkUniform(t), this._vectors2[t] = s, this;
|
|
192
|
-
}
|
|
193
|
-
/**
|
|
194
|
-
* Set a vec3 in the shader from a Vector3.
|
|
195
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
196
|
-
* @param value Define the value to give to the uniform
|
|
197
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
198
|
-
*/
|
|
199
|
-
setVector3(t, s) {
|
|
200
|
-
return this._checkUniform(t), this._vectors3[t] = s, this;
|
|
201
|
-
}
|
|
202
|
-
/**
|
|
203
|
-
* Set a vec4 in the shader from a Vector4.
|
|
204
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
205
|
-
* @param value Define the value to give to the uniform
|
|
206
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
207
|
-
*/
|
|
208
|
-
setVector4(t, s) {
|
|
209
|
-
return this._checkUniform(t), this._vectors4[t] = s, this;
|
|
210
|
-
}
|
|
211
|
-
/**
|
|
212
|
-
* Set a vec4 in the shader from a Quaternion.
|
|
213
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
214
|
-
* @param value Define the value to give to the uniform
|
|
215
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
216
|
-
*/
|
|
217
|
-
setQuaternion(t, s) {
|
|
218
|
-
return this._checkUniform(t), this._quaternions[t] = s, this;
|
|
219
|
-
}
|
|
220
|
-
/**
|
|
221
|
-
* Set a vec4 array in the shader from a Quaternion array.
|
|
222
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
223
|
-
* @param value Define the value to give to the uniform
|
|
224
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
225
|
-
*/
|
|
226
|
-
setQuaternionArray(t, s) {
|
|
227
|
-
return this._checkUniform(t), this._quaternionsArrays[t] = s.reduce((e, o) => (o.toArray(e, e.length), e), []), this;
|
|
228
|
-
}
|
|
229
|
-
/**
|
|
230
|
-
* Set a mat4 in the shader from a Matrix.
|
|
231
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
232
|
-
* @param value Define the value to give to the uniform
|
|
233
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
234
|
-
*/
|
|
235
|
-
setMatrix(t, s) {
|
|
236
|
-
return this._checkUniform(t), this._matrices[t] = s, this;
|
|
237
|
-
}
|
|
238
|
-
/**
|
|
239
|
-
* Set a float32Array in the shader from a matrix array.
|
|
240
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
241
|
-
* @param value Define the value to give to the uniform
|
|
242
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
243
|
-
*/
|
|
244
|
-
setMatrices(t, s) {
|
|
245
|
-
this._checkUniform(t);
|
|
246
|
-
const e = new Float32Array(s.length * 16);
|
|
247
|
-
for (let o = 0; o < s.length; o++)
|
|
248
|
-
s[o].copyToArray(e, o * 16);
|
|
249
|
-
return this._matrixArrays[t] = e, this;
|
|
250
|
-
}
|
|
251
|
-
/**
|
|
252
|
-
* Set a mat3 in the shader from a Float32Array.
|
|
253
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
254
|
-
* @param value Define the value to give to the uniform
|
|
255
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
256
|
-
*/
|
|
257
|
-
setMatrix3x3(t, s) {
|
|
258
|
-
return this._checkUniform(t), this._matrices3x3[t] = s, this;
|
|
259
|
-
}
|
|
260
|
-
/**
|
|
261
|
-
* Set a mat2 in the shader from a Float32Array.
|
|
262
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
263
|
-
* @param value Define the value to give to the uniform
|
|
264
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
265
|
-
*/
|
|
266
|
-
setMatrix2x2(t, s) {
|
|
267
|
-
return this._checkUniform(t), this._matrices2x2[t] = s, this;
|
|
268
|
-
}
|
|
269
|
-
/**
|
|
270
|
-
* Set a vec2 array in the shader from a number array.
|
|
271
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
272
|
-
* @param value Define the value to give to the uniform
|
|
273
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
274
|
-
*/
|
|
275
|
-
setArray2(t, s) {
|
|
276
|
-
return this._checkUniform(t), this._vectors2Arrays[t] = s, this;
|
|
277
|
-
}
|
|
278
|
-
/**
|
|
279
|
-
* Set a vec3 array in the shader from a number array.
|
|
280
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
281
|
-
* @param value Define the value to give to the uniform
|
|
282
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
283
|
-
*/
|
|
284
|
-
setArray3(t, s) {
|
|
285
|
-
return this._checkUniform(t), this._vectors3Arrays[t] = s, this;
|
|
286
|
-
}
|
|
287
|
-
/**
|
|
288
|
-
* Set a vec4 array in the shader from a number array.
|
|
289
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
290
|
-
* @param value Define the value to give to the uniform
|
|
291
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
292
|
-
*/
|
|
293
|
-
setArray4(t, s) {
|
|
294
|
-
return this._checkUniform(t), this._vectors4Arrays[t] = s, this;
|
|
295
|
-
}
|
|
296
|
-
/**
|
|
297
|
-
* Set a uniform buffer in the shader
|
|
298
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
299
|
-
* @param buffer Define the value to give to the uniform
|
|
300
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
301
|
-
*/
|
|
302
|
-
setUniformBuffer(t, s) {
|
|
303
|
-
return this._options.uniformBuffers.indexOf(t) === -1 && this._options.uniformBuffers.push(t), this._uniformBuffers[t] = s, this;
|
|
304
|
-
}
|
|
305
|
-
/**
|
|
306
|
-
* Set a texture sampler in the shader
|
|
307
|
-
* @param name Define the name of the uniform as defined in the shader
|
|
308
|
-
* @param sampler Define the value to give to the uniform
|
|
309
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
310
|
-
*/
|
|
311
|
-
setTextureSampler(t, s) {
|
|
312
|
-
return this._options.samplerObjects.indexOf(t) === -1 && this._options.samplerObjects.push(t), this._textureSamplers[t] = s, this;
|
|
313
|
-
}
|
|
314
|
-
/**
|
|
315
|
-
* Set a storage buffer in the shader
|
|
316
|
-
* @param name Define the name of the storage buffer as defined in the shader
|
|
317
|
-
* @param buffer Define the value to give to the uniform
|
|
318
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
319
|
-
*/
|
|
320
|
-
setStorageBuffer(t, s) {
|
|
321
|
-
return this._options.storageBuffers.indexOf(t) === -1 && this._options.storageBuffers.push(t), this._storageBuffers[t] = s, this;
|
|
322
|
-
}
|
|
323
|
-
/**
|
|
324
|
-
* Adds, removes, or replaces the specified shader define and value.
|
|
325
|
-
* * setDefine("MY_DEFINE", true); // enables a boolean define
|
|
326
|
-
* * setDefine("MY_DEFINE", "0.5"); // adds "#define MY_DEFINE 0.5" to the shader (or sets and replaces the value of any existing define with that name)
|
|
327
|
-
* * setDefine("MY_DEFINE", false); // disables and removes the define
|
|
328
|
-
* Note if the active defines do change, the shader will be recompiled and this can be expensive.
|
|
329
|
-
* @param define the define name e.g., "OUTPUT_TO_SRGB" or "#define OUTPUT_TO_SRGB". If the define was passed into the constructor already, the version used should match that, and in either case, it should not include any appended value.
|
|
330
|
-
* @param value either the value of the define (e.g. a numerical value) or for booleans, true if the define should be enabled or false if it should be disabled
|
|
331
|
-
* @returns the material itself allowing "fluent" like uniform updates
|
|
332
|
-
*/
|
|
333
|
-
setDefine(t, s) {
|
|
334
|
-
const e = t.trimEnd() + " ", o = this.options.defines.findIndex((i) => i === t || i.startsWith(e));
|
|
335
|
-
return o >= 0 && this.options.defines.splice(o, 1), (typeof s != "boolean" || s) && this.options.defines.push(e + s), this;
|
|
336
|
-
}
|
|
337
|
-
/**
|
|
338
|
-
* Specifies that the submesh is ready to be used
|
|
339
|
-
* @param mesh defines the mesh to check
|
|
340
|
-
* @param subMesh defines which submesh to check
|
|
341
|
-
* @param useInstances specifies that instances should be used
|
|
342
|
-
* @returns a boolean indicating that the submesh is ready or not
|
|
343
|
-
*/
|
|
344
|
-
isReadyForSubMesh(t, s, e) {
|
|
345
|
-
return this.isReady(t, e, s);
|
|
346
|
-
}
|
|
347
|
-
/**
|
|
348
|
-
* Checks if the material is ready to render the requested mesh
|
|
349
|
-
* @param mesh Define the mesh to render
|
|
350
|
-
* @param useInstances Define whether or not the material is used with instances
|
|
351
|
-
* @param subMesh defines which submesh to render
|
|
352
|
-
* @returns true if ready, otherwise false
|
|
353
|
-
*/
|
|
354
|
-
isReady(t, s, e) {
|
|
355
|
-
var o, i, h, n;
|
|
356
|
-
const c = e && this._storeEffectOnSubMeshes;
|
|
357
|
-
if (this.isFrozen)
|
|
358
|
-
if (c) {
|
|
359
|
-
if (e.effect && e.effect._wasPreviouslyReady)
|
|
360
|
-
return !0;
|
|
361
|
-
} else {
|
|
362
|
-
const f = this._drawWrapper.effect;
|
|
363
|
-
if (f && f._wasPreviouslyReady && f._wasPreviouslyUsingInstances === s)
|
|
364
|
-
return !0;
|
|
365
|
-
}
|
|
366
|
-
const u = this.getScene(), y = u.getEngine(), r = [], a = [], B = new H();
|
|
367
|
-
let P = this._shaderPath, _ = this._options.uniforms, T = this._options.uniformBuffers, S = this._options.samplers;
|
|
368
|
-
y.getCaps().multiview && u.activeCamera && u.activeCamera.outputRenderTarget && u.activeCamera.outputRenderTarget.getViewCount() > 1 && (this._multiview = !0, r.push("#define MULTIVIEW"), this._options.uniforms.indexOf("viewProjection") !== -1 && this._options.uniforms.indexOf("viewProjectionR") === -1 && this._options.uniforms.push("viewProjectionR"));
|
|
369
|
-
for (let f = 0; f < this._options.defines.length; f++) {
|
|
370
|
-
const b = this._options.defines[f].indexOf("#define") === 0 ? this._options.defines[f] : `#define ${this._options.defines[f]}`;
|
|
371
|
-
r.push(b);
|
|
372
|
-
}
|
|
373
|
-
for (let f = 0; f < this._options.attributes.length; f++)
|
|
374
|
-
a.push(this._options.attributes[f]);
|
|
375
|
-
if (t && t.isVerticesDataPresent(l.ColorKind) && (a.push(l.ColorKind), r.push("#define VERTEXCOLOR")), s && (r.push("#define INSTANCES"), g.PushAttributesForInstances(a, this._materialHelperNeedsPreviousMatrices), t != null && t.hasThinInstances && (r.push("#define THIN_INSTANCES"), t && t.isVerticesDataPresent(l.ColorInstanceKind) && (a.push(l.ColorInstanceKind), r.push("#define INSTANCESCOLOR")))), t && t.useBones && t.computeBonesUsingShaders && t.skeleton) {
|
|
376
|
-
a.push(l.MatricesIndicesKind), a.push(l.MatricesWeightsKind), t.numBoneInfluencers > 4 && (a.push(l.MatricesIndicesExtraKind), a.push(l.MatricesWeightsExtraKind));
|
|
377
|
-
const f = t.skeleton;
|
|
378
|
-
r.push("#define NUM_BONE_INFLUENCERS " + t.numBoneInfluencers), B.addCPUSkinningFallback(0, t), f.isUsingTextureForMatrices ? (r.push("#define BONETEXTURE"), this._options.uniforms.indexOf("boneTextureWidth") === -1 && this._options.uniforms.push("boneTextureWidth"), this._options.samplers.indexOf("boneSampler") === -1 && this._options.samplers.push("boneSampler")) : (r.push("#define BonesPerMesh " + (f.bones.length + 1)), this._options.uniforms.indexOf("mBones") === -1 && this._options.uniforms.push("mBones"));
|
|
379
|
-
} else
|
|
380
|
-
r.push("#define NUM_BONE_INFLUENCERS 0");
|
|
381
|
-
let A = 0;
|
|
382
|
-
const m = t ? t.morphTargetManager : null;
|
|
383
|
-
if (m) {
|
|
384
|
-
const f = m.supportsUVs && r.indexOf("#define UV1") !== -1, b = m.supportsTangents && r.indexOf("#define TANGENT") !== -1, w = m.supportsNormals && r.indexOf("#define NORMAL") !== -1;
|
|
385
|
-
A = m.numInfluencers, f && r.push("#define MORPHTARGETS_UV"), b && r.push("#define MORPHTARGETS_TANGENT"), w && r.push("#define MORPHTARGETS_NORMAL"), A > 0 && r.push("#define MORPHTARGETS"), m.isUsingTextureForTargets && (r.push("#define MORPHTARGETS_TEXTURE"), this._options.uniforms.indexOf("morphTargetTextureIndices") === -1 && this._options.uniforms.push("morphTargetTextureIndices"), this._options.samplers.indexOf("morphTargets") === -1 && this._options.samplers.push("morphTargets")), r.push("#define NUM_MORPH_INFLUENCERS " + A);
|
|
386
|
-
for (let v = 0; v < A; v++)
|
|
387
|
-
a.push(l.PositionKind + v), w && a.push(l.NormalKind + v), b && a.push(l.TangentKind + v), f && a.push(l.UVKind + "_" + v);
|
|
388
|
-
A > 0 && (_ = _.slice(), _.push("morphTargetInfluences"), _.push("morphTargetTextureInfo"), _.push("morphTargetTextureIndices"));
|
|
389
|
-
} else
|
|
390
|
-
r.push("#define NUM_MORPH_INFLUENCERS 0");
|
|
391
|
-
if (t) {
|
|
392
|
-
const f = t.bakedVertexAnimationManager;
|
|
393
|
-
f && f.isEnabled && (r.push("#define BAKED_VERTEX_ANIMATION_TEXTURE"), this._options.uniforms.indexOf("bakedVertexAnimationSettings") === -1 && this._options.uniforms.push("bakedVertexAnimationSettings"), this._options.uniforms.indexOf("bakedVertexAnimationTextureSizeInverted") === -1 && this._options.uniforms.push("bakedVertexAnimationTextureSizeInverted"), this._options.uniforms.indexOf("bakedVertexAnimationTime") === -1 && this._options.uniforms.push("bakedVertexAnimationTime"), this._options.samplers.indexOf("bakedVertexAnimationTexture") === -1 && this._options.samplers.push("bakedVertexAnimationTexture")), g.PrepareAttributesForBakedVertexAnimation(a, t, r);
|
|
394
|
-
}
|
|
395
|
-
for (const f in this._textures)
|
|
396
|
-
if (!this._textures[f].isReady())
|
|
397
|
-
return !1;
|
|
398
|
-
t && this._shouldTurnAlphaTestOn(t) && r.push("#define ALPHATEST"), this._options.useClipPlane !== !1 && (G(_), D(this, u, r)), this.customShaderNameResolve && (_ = _.slice(), T = T.slice(), S = S.slice(), P = this.customShaderNameResolve(P, _, T, S, r, a));
|
|
399
|
-
const d = c ? e._getDrawWrapper() : this._drawWrapper, U = (o = d == null ? void 0 : d.effect) !== null && o !== void 0 ? o : null, F = (i = d == null ? void 0 : d.defines) !== null && i !== void 0 ? i : null, M = r.join(`
|
|
400
|
-
`);
|
|
401
|
-
let p = U;
|
|
402
|
-
return F !== M && (p = y.createEffect(P, {
|
|
403
|
-
attributes: a,
|
|
404
|
-
uniformsNames: _,
|
|
405
|
-
uniformBuffersNames: T,
|
|
406
|
-
samplers: S,
|
|
407
|
-
defines: M,
|
|
408
|
-
fallbacks: B,
|
|
409
|
-
onCompiled: this.onCompiled,
|
|
410
|
-
onError: this.onError,
|
|
411
|
-
indexParameters: { maxSimultaneousMorphTargets: A },
|
|
412
|
-
shaderLanguage: this._options.shaderLanguage
|
|
413
|
-
}, y), c ? e.setEffect(p, M, this._materialContext) : d && d.setEffect(p, M), this._onEffectCreatedObservable && (k.effect = p, k.subMesh = (h = e ?? (t == null ? void 0 : t.subMeshes[0])) !== null && h !== void 0 ? h : null, this._onEffectCreatedObservable.notifyObservers(k))), p._wasPreviouslyUsingInstances = !!s, !((n = !(p != null && p.isReady())) !== null && n !== void 0) || n ? !1 : (U !== p && u.resetCachedMaterial(), p._wasPreviouslyReady = !0, !0);
|
|
414
|
-
}
|
|
415
|
-
/**
|
|
416
|
-
* Binds the world matrix to the material
|
|
417
|
-
* @param world defines the world transformation matrix
|
|
418
|
-
* @param effectOverride - If provided, use this effect instead of internal effect
|
|
419
|
-
*/
|
|
420
|
-
bindOnlyWorldMatrix(t, s) {
|
|
421
|
-
const e = this.getScene(), o = s ?? this.getEffect();
|
|
422
|
-
o && (this._options.uniforms.indexOf("world") !== -1 && o.setMatrix("world", t), this._options.uniforms.indexOf("worldView") !== -1 && (t.multiplyToRef(e.getViewMatrix(), this._cachedWorldViewMatrix), o.setMatrix("worldView", this._cachedWorldViewMatrix)), this._options.uniforms.indexOf("worldViewProjection") !== -1 && (t.multiplyToRef(e.getTransformMatrix(), this._cachedWorldViewProjectionMatrix), o.setMatrix("worldViewProjection", this._cachedWorldViewProjectionMatrix)));
|
|
423
|
-
}
|
|
424
|
-
/**
|
|
425
|
-
* Binds the submesh to this material by preparing the effect and shader to draw
|
|
426
|
-
* @param world defines the world transformation matrix
|
|
427
|
-
* @param mesh defines the mesh containing the submesh
|
|
428
|
-
* @param subMesh defines the submesh to bind the material to
|
|
429
|
-
*/
|
|
430
|
-
bindForSubMesh(t, s, e) {
|
|
431
|
-
var o;
|
|
432
|
-
this.bind(t, s, (o = e._drawWrapperOverride) === null || o === void 0 ? void 0 : o.effect, e);
|
|
433
|
-
}
|
|
434
|
-
/**
|
|
435
|
-
* Binds the material to the mesh
|
|
436
|
-
* @param world defines the world transformation matrix
|
|
437
|
-
* @param mesh defines the mesh to bind the material to
|
|
438
|
-
* @param effectOverride - If provided, use this effect instead of internal effect
|
|
439
|
-
* @param subMesh defines the submesh to bind the material to
|
|
440
|
-
*/
|
|
441
|
-
bind(t, s, e, o) {
|
|
442
|
-
var i;
|
|
443
|
-
const h = o && this._storeEffectOnSubMeshes, n = e ?? (h ? o.effect : this.getEffect());
|
|
444
|
-
if (!n)
|
|
445
|
-
return;
|
|
446
|
-
this._activeEffect = n, this.bindOnlyWorldMatrix(t, e);
|
|
447
|
-
const c = this._options.uniformBuffers;
|
|
448
|
-
let u = !1;
|
|
449
|
-
if (n && c && c.length > 0 && this.getScene().getEngine().supportsUniformBuffers)
|
|
450
|
-
for (let r = 0; r < c.length; ++r)
|
|
451
|
-
switch (c[r]) {
|
|
452
|
-
case "Mesh":
|
|
453
|
-
s && (s.getMeshUniformBuffer().bindToEffect(n, "Mesh"), s.transferToEffect(t));
|
|
454
|
-
break;
|
|
455
|
-
case "Scene":
|
|
456
|
-
g.BindSceneUniformBuffer(n, this.getScene().getSceneUniformBuffer()), this.getScene().finalizeSceneUbo(), u = !0;
|
|
457
|
-
break;
|
|
458
|
-
}
|
|
459
|
-
const y = s && h ? this._mustRebind(this.getScene(), n, s.visibility) : this.getScene().getCachedMaterial() !== this;
|
|
460
|
-
if (n && y) {
|
|
461
|
-
!u && this._options.uniforms.indexOf("view") !== -1 && n.setMatrix("view", this.getScene().getViewMatrix()), !u && this._options.uniforms.indexOf("projection") !== -1 && n.setMatrix("projection", this.getScene().getProjectionMatrix()), !u && this._options.uniforms.indexOf("viewProjection") !== -1 && (n.setMatrix("viewProjection", this.getScene().getTransformMatrix()), this._multiview && n.setMatrix("viewProjectionR", this.getScene()._transformMatrixR)), this.getScene().activeCamera && this._options.uniforms.indexOf("cameraPosition") !== -1 && n.setVector3("cameraPosition", this.getScene().activeCamera.globalPosition), g.BindBonesParameters(s, n), Q(n, this, this.getScene());
|
|
462
|
-
let r;
|
|
463
|
-
for (r in this._textures)
|
|
464
|
-
n.setTexture(r, this._textures[r]);
|
|
465
|
-
for (r in this._textureArrays)
|
|
466
|
-
n.setTextureArray(r, this._textureArrays[r]);
|
|
467
|
-
for (r in this._externalTextures)
|
|
468
|
-
n.setExternalTexture(r, this._externalTextures[r]);
|
|
469
|
-
for (r in this._ints)
|
|
470
|
-
n.setInt(r, this._ints[r]);
|
|
471
|
-
for (r in this._uints)
|
|
472
|
-
n.setUInt(r, this._uints[r]);
|
|
473
|
-
for (r in this._floats)
|
|
474
|
-
n.setFloat(r, this._floats[r]);
|
|
475
|
-
for (r in this._floatsArrays)
|
|
476
|
-
n.setArray(r, this._floatsArrays[r]);
|
|
477
|
-
for (r in this._colors3)
|
|
478
|
-
n.setColor3(r, this._colors3[r]);
|
|
479
|
-
for (r in this._colors3Arrays)
|
|
480
|
-
n.setArray3(r, this._colors3Arrays[r]);
|
|
481
|
-
for (r in this._colors4) {
|
|
482
|
-
const a = this._colors4[r];
|
|
483
|
-
n.setFloat4(r, a.r, a.g, a.b, a.a);
|
|
484
|
-
}
|
|
485
|
-
for (r in this._colors4Arrays)
|
|
486
|
-
n.setArray4(r, this._colors4Arrays[r]);
|
|
487
|
-
for (r in this._vectors2)
|
|
488
|
-
n.setVector2(r, this._vectors2[r]);
|
|
489
|
-
for (r in this._vectors3)
|
|
490
|
-
n.setVector3(r, this._vectors3[r]);
|
|
491
|
-
for (r in this._vectors4)
|
|
492
|
-
n.setVector4(r, this._vectors4[r]);
|
|
493
|
-
for (r in this._quaternions)
|
|
494
|
-
n.setQuaternion(r, this._quaternions[r]);
|
|
495
|
-
for (r in this._matrices)
|
|
496
|
-
n.setMatrix(r, this._matrices[r]);
|
|
497
|
-
for (r in this._matrixArrays)
|
|
498
|
-
n.setMatrices(r, this._matrixArrays[r]);
|
|
499
|
-
for (r in this._matrices3x3)
|
|
500
|
-
n.setMatrix3x3(r, this._matrices3x3[r]);
|
|
501
|
-
for (r in this._matrices2x2)
|
|
502
|
-
n.setMatrix2x2(r, this._matrices2x2[r]);
|
|
503
|
-
for (r in this._vectors2Arrays)
|
|
504
|
-
n.setArray2(r, this._vectors2Arrays[r]);
|
|
505
|
-
for (r in this._vectors3Arrays)
|
|
506
|
-
n.setArray3(r, this._vectors3Arrays[r]);
|
|
507
|
-
for (r in this._vectors4Arrays)
|
|
508
|
-
n.setArray4(r, this._vectors4Arrays[r]);
|
|
509
|
-
for (r in this._quaternionsArrays)
|
|
510
|
-
n.setArray4(r, this._quaternionsArrays[r]);
|
|
511
|
-
for (r in this._uniformBuffers) {
|
|
512
|
-
const a = this._uniformBuffers[r].getBuffer();
|
|
513
|
-
a && n.bindUniformBuffer(a, r);
|
|
514
|
-
}
|
|
515
|
-
for (r in this._textureSamplers)
|
|
516
|
-
n.setTextureSampler(r, this._textureSamplers[r]);
|
|
517
|
-
for (r in this._storageBuffers)
|
|
518
|
-
n.setStorageBuffer(r, this._storageBuffers[r]);
|
|
519
|
-
}
|
|
520
|
-
if (n && s && (y || !this.isFrozen)) {
|
|
521
|
-
const r = s.morphTargetManager;
|
|
522
|
-
r && r.numInfluencers > 0 && g.BindMorphTargetParameters(s, n);
|
|
523
|
-
const a = s.bakedVertexAnimationManager;
|
|
524
|
-
a && a.isEnabled && ((i = s.bakedVertexAnimationManager) === null || i === void 0 || i.bind(n, !!n._wasPreviouslyUsingInstances));
|
|
525
|
-
}
|
|
526
|
-
this._afterBind(s, n);
|
|
527
|
-
}
|
|
528
|
-
/**
|
|
529
|
-
* Gets the active textures from the material
|
|
530
|
-
* @returns an array of textures
|
|
531
|
-
*/
|
|
532
|
-
getActiveTextures() {
|
|
533
|
-
const t = super.getActiveTextures();
|
|
534
|
-
for (const s in this._textures)
|
|
535
|
-
t.push(this._textures[s]);
|
|
536
|
-
for (const s in this._textureArrays) {
|
|
537
|
-
const e = this._textureArrays[s];
|
|
538
|
-
for (let o = 0; o < e.length; o++)
|
|
539
|
-
t.push(e[o]);
|
|
540
|
-
}
|
|
541
|
-
return t;
|
|
542
|
-
}
|
|
543
|
-
/**
|
|
544
|
-
* Specifies if the material uses a texture
|
|
545
|
-
* @param texture defines the texture to check against the material
|
|
546
|
-
* @returns a boolean specifying if the material uses the texture
|
|
547
|
-
*/
|
|
548
|
-
hasTexture(t) {
|
|
549
|
-
if (super.hasTexture(t))
|
|
550
|
-
return !0;
|
|
551
|
-
for (const s in this._textures)
|
|
552
|
-
if (this._textures[s] === t)
|
|
553
|
-
return !0;
|
|
554
|
-
for (const s in this._textureArrays) {
|
|
555
|
-
const e = this._textureArrays[s];
|
|
556
|
-
for (let o = 0; o < e.length; o++)
|
|
557
|
-
if (e[o] === t)
|
|
558
|
-
return !0;
|
|
559
|
-
}
|
|
560
|
-
return !1;
|
|
561
|
-
}
|
|
562
|
-
/**
|
|
563
|
-
* Makes a duplicate of the material, and gives it a new name
|
|
564
|
-
* @param name defines the new name for the duplicated material
|
|
565
|
-
* @returns the cloned material
|
|
566
|
-
*/
|
|
567
|
-
clone(t) {
|
|
568
|
-
const s = E.Clone(() => new x(t, this.getScene(), this._shaderPath, this._options, this._storeEffectOnSubMeshes), this);
|
|
569
|
-
s.name = t, s.id = t, typeof s._shaderPath == "object" && (s._shaderPath = Object.assign({}, s._shaderPath)), this._options = Object.assign({}, this._options), Object.keys(this._options).forEach((e) => {
|
|
570
|
-
const o = this._options[e];
|
|
571
|
-
Array.isArray(o) && (this._options[e] = o.slice(0));
|
|
572
|
-
}), this.stencil.copyTo(s.stencil);
|
|
573
|
-
for (const e in this._textures)
|
|
574
|
-
s.setTexture(e, this._textures[e]);
|
|
575
|
-
for (const e in this._textureArrays)
|
|
576
|
-
s.setTextureArray(e, this._textureArrays[e]);
|
|
577
|
-
for (const e in this._externalTextures)
|
|
578
|
-
s.setExternalTexture(e, this._externalTextures[e]);
|
|
579
|
-
for (const e in this._ints)
|
|
580
|
-
s.setInt(e, this._ints[e]);
|
|
581
|
-
for (const e in this._uints)
|
|
582
|
-
s.setUInt(e, this._uints[e]);
|
|
583
|
-
for (const e in this._floats)
|
|
584
|
-
s.setFloat(e, this._floats[e]);
|
|
585
|
-
for (const e in this._floatsArrays)
|
|
586
|
-
s.setFloats(e, this._floatsArrays[e]);
|
|
587
|
-
for (const e in this._colors3)
|
|
588
|
-
s.setColor3(e, this._colors3[e]);
|
|
589
|
-
for (const e in this._colors3Arrays)
|
|
590
|
-
s._colors3Arrays[e] = this._colors3Arrays[e];
|
|
591
|
-
for (const e in this._colors4)
|
|
592
|
-
s.setColor4(e, this._colors4[e]);
|
|
593
|
-
for (const e in this._colors4Arrays)
|
|
594
|
-
s._colors4Arrays[e] = this._colors4Arrays[e];
|
|
595
|
-
for (const e in this._vectors2)
|
|
596
|
-
s.setVector2(e, this._vectors2[e]);
|
|
597
|
-
for (const e in this._vectors3)
|
|
598
|
-
s.setVector3(e, this._vectors3[e]);
|
|
599
|
-
for (const e in this._vectors4)
|
|
600
|
-
s.setVector4(e, this._vectors4[e]);
|
|
601
|
-
for (const e in this._quaternions)
|
|
602
|
-
s.setQuaternion(e, this._quaternions[e]);
|
|
603
|
-
for (const e in this._quaternionsArrays)
|
|
604
|
-
s._quaternionsArrays[e] = this._quaternionsArrays[e];
|
|
605
|
-
for (const e in this._matrices)
|
|
606
|
-
s.setMatrix(e, this._matrices[e]);
|
|
607
|
-
for (const e in this._matrixArrays)
|
|
608
|
-
s._matrixArrays[e] = this._matrixArrays[e].slice();
|
|
609
|
-
for (const e in this._matrices3x3)
|
|
610
|
-
s.setMatrix3x3(e, this._matrices3x3[e]);
|
|
611
|
-
for (const e in this._matrices2x2)
|
|
612
|
-
s.setMatrix2x2(e, this._matrices2x2[e]);
|
|
613
|
-
for (const e in this._vectors2Arrays)
|
|
614
|
-
s.setArray2(e, this._vectors2Arrays[e]);
|
|
615
|
-
for (const e in this._vectors3Arrays)
|
|
616
|
-
s.setArray3(e, this._vectors3Arrays[e]);
|
|
617
|
-
for (const e in this._vectors4Arrays)
|
|
618
|
-
s.setArray4(e, this._vectors4Arrays[e]);
|
|
619
|
-
for (const e in this._uniformBuffers)
|
|
620
|
-
s.setUniformBuffer(e, this._uniformBuffers[e]);
|
|
621
|
-
for (const e in this._textureSamplers)
|
|
622
|
-
s.setTextureSampler(e, this._textureSamplers[e]);
|
|
623
|
-
for (const e in this._storageBuffers)
|
|
624
|
-
s.setStorageBuffer(e, this._storageBuffers[e]);
|
|
625
|
-
return s;
|
|
626
|
-
}
|
|
627
|
-
/**
|
|
628
|
-
* Disposes the material
|
|
629
|
-
* @param forceDisposeEffect specifies if effects should be forcefully disposed
|
|
630
|
-
* @param forceDisposeTextures specifies if textures should be forcefully disposed
|
|
631
|
-
* @param notBoundToMesh specifies if the material that is being disposed is known to be not bound to any mesh
|
|
632
|
-
*/
|
|
633
|
-
dispose(t, s, e) {
|
|
634
|
-
if (s) {
|
|
635
|
-
let o;
|
|
636
|
-
for (o in this._textures)
|
|
637
|
-
this._textures[o].dispose();
|
|
638
|
-
for (o in this._textureArrays) {
|
|
639
|
-
const i = this._textureArrays[o];
|
|
640
|
-
for (let h = 0; h < i.length; h++)
|
|
641
|
-
i[h].dispose();
|
|
642
|
-
}
|
|
643
|
-
}
|
|
644
|
-
this._textures = {}, super.dispose(t, s, e);
|
|
645
|
-
}
|
|
646
|
-
/**
|
|
647
|
-
* Serializes this material in a JSON representation
|
|
648
|
-
* @returns the serialized material object
|
|
649
|
-
*/
|
|
650
|
-
serialize() {
|
|
651
|
-
const t = E.Serialize(this);
|
|
652
|
-
t.customType = "BABYLON.ShaderMaterial", t.uniqueId = this.uniqueId, t.options = this._options, t.shaderPath = this._shaderPath, t.storeEffectOnSubMeshes = this._storeEffectOnSubMeshes;
|
|
653
|
-
let s;
|
|
654
|
-
t.stencil = this.stencil.serialize(), t.textures = {};
|
|
655
|
-
for (s in this._textures)
|
|
656
|
-
t.textures[s] = this._textures[s].serialize();
|
|
657
|
-
t.textureArrays = {};
|
|
658
|
-
for (s in this._textureArrays) {
|
|
659
|
-
t.textureArrays[s] = [];
|
|
660
|
-
const e = this._textureArrays[s];
|
|
661
|
-
for (let o = 0; o < e.length; o++)
|
|
662
|
-
t.textureArrays[s].push(e[o].serialize());
|
|
663
|
-
}
|
|
664
|
-
t.ints = {};
|
|
665
|
-
for (s in this._ints)
|
|
666
|
-
t.ints[s] = this._ints[s];
|
|
667
|
-
t.uints = {};
|
|
668
|
-
for (s in this._uints)
|
|
669
|
-
t.uints[s] = this._uints[s];
|
|
670
|
-
t.floats = {};
|
|
671
|
-
for (s in this._floats)
|
|
672
|
-
t.floats[s] = this._floats[s];
|
|
673
|
-
t.FloatArrays = {};
|
|
674
|
-
for (s in this._floatsArrays)
|
|
675
|
-
t.FloatArrays[s] = this._floatsArrays[s];
|
|
676
|
-
t.colors3 = {};
|
|
677
|
-
for (s in this._colors3)
|
|
678
|
-
t.colors3[s] = this._colors3[s].asArray();
|
|
679
|
-
t.colors3Arrays = {};
|
|
680
|
-
for (s in this._colors3Arrays)
|
|
681
|
-
t.colors3Arrays[s] = this._colors3Arrays[s];
|
|
682
|
-
t.colors4 = {};
|
|
683
|
-
for (s in this._colors4)
|
|
684
|
-
t.colors4[s] = this._colors4[s].asArray();
|
|
685
|
-
t.colors4Arrays = {};
|
|
686
|
-
for (s in this._colors4Arrays)
|
|
687
|
-
t.colors4Arrays[s] = this._colors4Arrays[s];
|
|
688
|
-
t.vectors2 = {};
|
|
689
|
-
for (s in this._vectors2)
|
|
690
|
-
t.vectors2[s] = this._vectors2[s].asArray();
|
|
691
|
-
t.vectors3 = {};
|
|
692
|
-
for (s in this._vectors3)
|
|
693
|
-
t.vectors3[s] = this._vectors3[s].asArray();
|
|
694
|
-
t.vectors4 = {};
|
|
695
|
-
for (s in this._vectors4)
|
|
696
|
-
t.vectors4[s] = this._vectors4[s].asArray();
|
|
697
|
-
t.quaternions = {};
|
|
698
|
-
for (s in this._quaternions)
|
|
699
|
-
t.quaternions[s] = this._quaternions[s].asArray();
|
|
700
|
-
t.matrices = {};
|
|
701
|
-
for (s in this._matrices)
|
|
702
|
-
t.matrices[s] = this._matrices[s].asArray();
|
|
703
|
-
t.matrixArray = {};
|
|
704
|
-
for (s in this._matrixArrays)
|
|
705
|
-
t.matrixArray[s] = this._matrixArrays[s];
|
|
706
|
-
t.matrices3x3 = {};
|
|
707
|
-
for (s in this._matrices3x3)
|
|
708
|
-
t.matrices3x3[s] = this._matrices3x3[s];
|
|
709
|
-
t.matrices2x2 = {};
|
|
710
|
-
for (s in this._matrices2x2)
|
|
711
|
-
t.matrices2x2[s] = this._matrices2x2[s];
|
|
712
|
-
t.vectors2Arrays = {};
|
|
713
|
-
for (s in this._vectors2Arrays)
|
|
714
|
-
t.vectors2Arrays[s] = this._vectors2Arrays[s];
|
|
715
|
-
t.vectors3Arrays = {};
|
|
716
|
-
for (s in this._vectors3Arrays)
|
|
717
|
-
t.vectors3Arrays[s] = this._vectors3Arrays[s];
|
|
718
|
-
t.vectors4Arrays = {};
|
|
719
|
-
for (s in this._vectors4Arrays)
|
|
720
|
-
t.vectors4Arrays[s] = this._vectors4Arrays[s];
|
|
721
|
-
t.quaternionsArrays = {};
|
|
722
|
-
for (s in this._quaternionsArrays)
|
|
723
|
-
t.quaternionsArrays[s] = this._quaternionsArrays[s];
|
|
724
|
-
return t;
|
|
725
|
-
}
|
|
726
|
-
/**
|
|
727
|
-
* Creates a shader material from parsed shader material data
|
|
728
|
-
* @param source defines the JSON representation of the material
|
|
729
|
-
* @param scene defines the hosting scene
|
|
730
|
-
* @param rootUrl defines the root URL to use to load textures and relative dependencies
|
|
731
|
-
* @returns a new material
|
|
732
|
-
*/
|
|
733
|
-
static Parse(t, s, e) {
|
|
734
|
-
const o = E.Parse(() => new x(t.name, s, t.shaderPath, t.options, t.storeEffectOnSubMeshes), t, s, e);
|
|
735
|
-
let i;
|
|
736
|
-
t.stencil && o.stencil.parse(t.stencil, s, e);
|
|
737
|
-
for (i in t.textures)
|
|
738
|
-
o.setTexture(i, C.Parse(t.textures[i], s, e));
|
|
739
|
-
for (i in t.textureArrays) {
|
|
740
|
-
const h = t.textureArrays[i], n = new Array();
|
|
741
|
-
for (let c = 0; c < h.length; c++)
|
|
742
|
-
n.push(C.Parse(h[c], s, e));
|
|
743
|
-
o.setTextureArray(i, n);
|
|
744
|
-
}
|
|
745
|
-
for (i in t.ints)
|
|
746
|
-
o.setInt(i, t.ints[i]);
|
|
747
|
-
for (i in t.uints)
|
|
748
|
-
o.setUInt(i, t.uints[i]);
|
|
749
|
-
for (i in t.floats)
|
|
750
|
-
o.setFloat(i, t.floats[i]);
|
|
751
|
-
for (i in t.floatsArrays)
|
|
752
|
-
o.setFloats(i, t.floatsArrays[i]);
|
|
753
|
-
for (i in t.colors3)
|
|
754
|
-
o.setColor3(i, V.FromArray(t.colors3[i]));
|
|
755
|
-
for (i in t.colors3Arrays) {
|
|
756
|
-
const h = t.colors3Arrays[i].reduce((n, c, u) => (u % 3 === 0 ? n.push([c]) : n[n.length - 1].push(c), n), []).map((n) => V.FromArray(n));
|
|
757
|
-
o.setColor3Array(i, h);
|
|
758
|
-
}
|
|
759
|
-
for (i in t.colors4)
|
|
760
|
-
o.setColor4(i, N.FromArray(t.colors4[i]));
|
|
761
|
-
for (i in t.colors4Arrays) {
|
|
762
|
-
const h = t.colors4Arrays[i].reduce((n, c, u) => (u % 4 === 0 ? n.push([c]) : n[n.length - 1].push(c), n), []).map((n) => N.FromArray(n));
|
|
763
|
-
o.setColor4Array(i, h);
|
|
764
|
-
}
|
|
765
|
-
for (i in t.vectors2)
|
|
766
|
-
o.setVector2(i, j.FromArray(t.vectors2[i]));
|
|
767
|
-
for (i in t.vectors3)
|
|
768
|
-
o.setVector3(i, q.FromArray(t.vectors3[i]));
|
|
769
|
-
for (i in t.vectors4)
|
|
770
|
-
o.setVector4(i, W.FromArray(t.vectors4[i]));
|
|
771
|
-
for (i in t.quaternions)
|
|
772
|
-
o.setQuaternion(i, L.FromArray(t.quaternions[i]));
|
|
773
|
-
for (i in t.matrices)
|
|
774
|
-
o.setMatrix(i, O.FromArray(t.matrices[i]));
|
|
775
|
-
for (i in t.matrixArray)
|
|
776
|
-
o._matrixArrays[i] = new Float32Array(t.matrixArray[i]);
|
|
777
|
-
for (i in t.matrices3x3)
|
|
778
|
-
o.setMatrix3x3(i, t.matrices3x3[i]);
|
|
779
|
-
for (i in t.matrices2x2)
|
|
780
|
-
o.setMatrix2x2(i, t.matrices2x2[i]);
|
|
781
|
-
for (i in t.vectors2Arrays)
|
|
782
|
-
o.setArray2(i, t.vectors2Arrays[i]);
|
|
783
|
-
for (i in t.vectors3Arrays)
|
|
784
|
-
o.setArray3(i, t.vectors3Arrays[i]);
|
|
785
|
-
for (i in t.vectors4Arrays)
|
|
786
|
-
o.setArray4(i, t.vectors4Arrays[i]);
|
|
787
|
-
for (i in t.quaternionsArrays)
|
|
788
|
-
o.setArray4(i, t.quaternionsArrays[i]);
|
|
789
|
-
return o;
|
|
790
|
-
}
|
|
791
|
-
/**
|
|
792
|
-
* Creates a new ShaderMaterial from a snippet saved in a remote file
|
|
793
|
-
* @param name defines the name of the ShaderMaterial to create (can be null or empty to use the one from the json data)
|
|
794
|
-
* @param url defines the url to load from
|
|
795
|
-
* @param scene defines the hosting scene
|
|
796
|
-
* @param rootUrl defines the root URL to use to load textures and relative dependencies
|
|
797
|
-
* @returns a promise that will resolve to the new ShaderMaterial
|
|
798
|
-
*/
|
|
799
|
-
static ParseFromFileAsync(t, s, e, o = "") {
|
|
800
|
-
return new Promise((i, h) => {
|
|
801
|
-
const n = new R();
|
|
802
|
-
n.addEventListener("readystatechange", () => {
|
|
803
|
-
if (n.readyState == 4)
|
|
804
|
-
if (n.status == 200) {
|
|
805
|
-
const c = JSON.parse(n.responseText), u = this.Parse(c, e || I.LastCreatedScene, o);
|
|
806
|
-
t && (u.name = t), i(u);
|
|
807
|
-
} else
|
|
808
|
-
h("Unable to load the ShaderMaterial");
|
|
809
|
-
}), n.open("GET", s), n.send();
|
|
810
|
-
});
|
|
811
|
-
}
|
|
812
|
-
/**
|
|
813
|
-
* Creates a ShaderMaterial from a snippet saved by the Inspector
|
|
814
|
-
* @param snippetId defines the snippet to load
|
|
815
|
-
* @param scene defines the hosting scene
|
|
816
|
-
* @param rootUrl defines the root URL to use to load textures and relative dependencies
|
|
817
|
-
* @returns a promise that will resolve to the new ShaderMaterial
|
|
818
|
-
*/
|
|
819
|
-
static ParseFromSnippetAsync(t, s, e = "") {
|
|
820
|
-
return new Promise((o, i) => {
|
|
821
|
-
const h = new R();
|
|
822
|
-
h.addEventListener("readystatechange", () => {
|
|
823
|
-
if (h.readyState == 4)
|
|
824
|
-
if (h.status == 200) {
|
|
825
|
-
const n = JSON.parse(JSON.parse(h.responseText).jsonPayload), c = JSON.parse(n.shaderMaterial), u = this.Parse(c, s || I.LastCreatedScene, e);
|
|
826
|
-
u.snippetId = t, o(u);
|
|
827
|
-
} else
|
|
828
|
-
i("Unable to load the snippet " + t);
|
|
829
|
-
}), h.open("GET", this.SnippetUrl + "/" + t.replace(/#/g, "/")), h.send();
|
|
830
|
-
});
|
|
831
|
-
}
|
|
832
|
-
}
|
|
833
|
-
x.SnippetUrl = "https://snippet.babylonjs.com";
|
|
834
|
-
x.CreateFromSnippetAsync = x.ParseFromSnippetAsync;
|
|
835
|
-
z("BABYLON.ShaderMaterial", x);
|
|
836
|
-
export {
|
|
837
|
-
x as ShaderMaterial
|
|
838
|
-
};
|