@babylonjs/core 7.51.1 → 7.51.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Animations/animation.js +2 -1
- package/Animations/animation.js.map +1 -1
- package/Buffers/bufferUtils.d.ts +7 -5
- package/Buffers/bufferUtils.js +13 -9
- package/Buffers/bufferUtils.js.map +1 -1
- package/Engines/ICanvas.d.ts +96 -1
- package/Engines/ICanvas.js.map +1 -1
- package/Engines/Native/nativeInterfaces.d.ts +7 -1
- package/Engines/Native/nativeInterfaces.js.map +1 -1
- package/Engines/WebGPU/webgpuTextureManager.js +3 -3
- package/Engines/WebGPU/webgpuTextureManager.js.map +1 -1
- package/Engines/abstractEngine.d.ts +7 -1
- package/Engines/abstractEngine.js +10 -2
- package/Engines/abstractEngine.js.map +1 -1
- package/Engines/constants.d.ts +32 -0
- package/Engines/constants.js +33 -0
- package/Engines/constants.js.map +1 -1
- package/Engines/nativeEngine.d.ts +7 -1
- package/Engines/nativeEngine.js +12 -0
- package/Engines/nativeEngine.js.map +1 -1
- package/Engines/webgpuEngine.js +6 -3
- package/Engines/webgpuEngine.js.map +1 -1
- package/FlowGraph/Blocks/Data/Math/flowGraphMathBlocks.d.ts +148 -465
- package/FlowGraph/Blocks/Data/Math/flowGraphMathBlocks.js +394 -691
- package/FlowGraph/Blocks/Data/Math/flowGraphMathBlocks.js.map +1 -1
- package/FlowGraph/Blocks/Data/Math/flowGraphMathCombineExtractBlocks.d.ts +142 -0
- package/FlowGraph/Blocks/Data/Math/flowGraphMathCombineExtractBlocks.js +342 -0
- package/FlowGraph/Blocks/Data/Math/flowGraphMathCombineExtractBlocks.js.map +1 -0
- package/FlowGraph/Blocks/Data/Math/flowGraphMatrixMathBlocks.d.ts +111 -0
- package/FlowGraph/Blocks/Data/Math/flowGraphMatrixMathBlocks.js +141 -0
- package/FlowGraph/Blocks/Data/Math/flowGraphMatrixMathBlocks.js.map +1 -0
- package/FlowGraph/Blocks/Data/Math/flowGraphVectorMathBlocks.d.ts +77 -0
- package/FlowGraph/Blocks/Data/Math/flowGraphVectorMathBlocks.js +139 -0
- package/FlowGraph/Blocks/Data/Math/flowGraphVectorMathBlocks.js.map +1 -0
- package/FlowGraph/Blocks/Data/Math/index.d.ts +3 -0
- package/FlowGraph/Blocks/Data/Math/index.js +3 -0
- package/FlowGraph/Blocks/Data/Math/index.js.map +1 -1
- package/FlowGraph/Blocks/Data/Transformers/flowGraphJsonPointerParserBlock.d.ts +85 -0
- package/FlowGraph/Blocks/Data/Transformers/flowGraphJsonPointerParserBlock.js +133 -0
- package/FlowGraph/Blocks/Data/Transformers/flowGraphJsonPointerParserBlock.js.map +1 -0
- package/FlowGraph/Blocks/Data/Transformers/flowGraphTypeToTypeBlocks.d.ts +49 -0
- package/FlowGraph/Blocks/Data/Transformers/flowGraphTypeToTypeBlocks.js +71 -0
- package/FlowGraph/Blocks/Data/Transformers/flowGraphTypeToTypeBlocks.js.map +1 -0
- package/FlowGraph/Blocks/Data/Transformers/index.d.ts +2 -0
- package/FlowGraph/Blocks/Data/Transformers/index.js +3 -0
- package/FlowGraph/Blocks/Data/Transformers/index.js.map +1 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphArrayIndexBlock.d.ts +39 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphArrayIndexBlock.js +46 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphArrayIndexBlock.js.map +1 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphCodeExecutionBlock.d.ts +35 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphCodeExecutionBlock.js +34 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphCodeExecutionBlock.js.map +1 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphContextBlock.d.ts +20 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphContextBlock.js +25 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphContextBlock.js.map +1 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphFunctionReferenceBlock.d.ts +34 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphFunctionReferenceBlock.js +35 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphFunctionReferenceBlock.js.map +1 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphIndexOfBlock.d.ts +39 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphIndexOfBlock.js +42 -0
- package/FlowGraph/Blocks/Data/Utils/flowGraphIndexOfBlock.js.map +1 -0
- package/FlowGraph/Blocks/Data/Utils/index.d.ts +5 -0
- package/FlowGraph/Blocks/Data/Utils/index.js +6 -0
- package/FlowGraph/Blocks/Data/Utils/index.js.map +1 -0
- package/FlowGraph/Blocks/Data/flowGraphBinaryOperationBlock.d.ts +0 -1
- package/FlowGraph/Blocks/Data/flowGraphBinaryOperationBlock.js +3 -2
- package/FlowGraph/Blocks/Data/flowGraphBinaryOperationBlock.js.map +1 -1
- package/FlowGraph/Blocks/Data/flowGraphCachedOperationBlock.d.ts +1 -1
- package/FlowGraph/Blocks/Data/flowGraphCachedOperationBlock.js +4 -4
- package/FlowGraph/Blocks/Data/flowGraphCachedOperationBlock.js.map +1 -1
- package/FlowGraph/Blocks/Data/flowGraphConditionalDataBlock.d.ts +6 -3
- package/FlowGraph/Blocks/Data/flowGraphConditionalDataBlock.js +12 -6
- package/FlowGraph/Blocks/Data/flowGraphConditionalDataBlock.js.map +1 -1
- package/FlowGraph/Blocks/Data/flowGraphConstantBlock.d.ts +0 -2
- package/FlowGraph/Blocks/Data/flowGraphConstantBlock.js +2 -3
- package/FlowGraph/Blocks/Data/flowGraphConstantBlock.js.map +1 -1
- package/FlowGraph/Blocks/Data/flowGraphConstantOperationBlock.d.ts +5 -4
- package/FlowGraph/Blocks/Data/flowGraphConstantOperationBlock.js +5 -4
- package/FlowGraph/Blocks/Data/flowGraphConstantOperationBlock.js.map +1 -1
- package/FlowGraph/Blocks/Data/flowGraphGetAssetBlock.d.ts +62 -0
- package/FlowGraph/Blocks/Data/flowGraphGetAssetBlock.js +41 -0
- package/FlowGraph/Blocks/Data/flowGraphGetAssetBlock.js.map +1 -0
- package/FlowGraph/Blocks/Data/flowGraphGetPropertyBlock.d.ts +38 -33
- package/FlowGraph/Blocks/Data/flowGraphGetPropertyBlock.js +42 -25
- package/FlowGraph/Blocks/Data/flowGraphGetPropertyBlock.js.map +1 -1
- package/FlowGraph/Blocks/Data/flowGraphGetVariableBlock.d.ts +11 -16
- package/FlowGraph/Blocks/Data/flowGraphGetVariableBlock.js +9 -17
- package/FlowGraph/Blocks/Data/flowGraphGetVariableBlock.js.map +1 -1
- package/FlowGraph/Blocks/Data/flowGraphTernaryOperationBlock.d.ts +1 -1
- package/FlowGraph/Blocks/Data/flowGraphTernaryOperationBlock.js +1 -1
- package/FlowGraph/Blocks/Data/flowGraphTernaryOperationBlock.js.map +1 -1
- package/FlowGraph/Blocks/Data/{flowGraphCoordinateTransformBlock.d.ts → flowGraphTransformCoordinatesSystemBlock.d.ts} +1 -2
- package/FlowGraph/Blocks/Data/{flowGraphCoordinateTransformBlock.js → flowGraphTransformCoordinatesSystemBlock.js} +4 -5
- package/FlowGraph/Blocks/Data/flowGraphTransformCoordinatesSystemBlock.js.map +1 -0
- package/FlowGraph/Blocks/Data/flowGraphUnaryOperationBlock.d.ts +1 -1
- package/FlowGraph/Blocks/Data/flowGraphUnaryOperationBlock.js +1 -1
- package/FlowGraph/Blocks/Data/flowGraphUnaryOperationBlock.js.map +1 -1
- package/FlowGraph/Blocks/Data/index.d.ts +7 -3
- package/FlowGraph/Blocks/Data/index.js +9 -4
- package/FlowGraph/Blocks/Data/index.js.map +1 -1
- package/FlowGraph/Blocks/Event/flowGraphMeshPickEventBlock.d.ts +45 -24
- package/FlowGraph/Blocks/Event/flowGraphMeshPickEventBlock.js +45 -51
- package/FlowGraph/Blocks/Event/flowGraphMeshPickEventBlock.js.map +1 -1
- package/FlowGraph/Blocks/Event/flowGraphPointerOutEventBlock.d.ts +61 -0
- package/FlowGraph/Blocks/Event/flowGraphPointerOutEventBlock.js +39 -0
- package/FlowGraph/Blocks/Event/flowGraphPointerOutEventBlock.js.map +1 -0
- package/FlowGraph/Blocks/Event/flowGraphPointerOverEventBlock.d.ts +61 -0
- package/FlowGraph/Blocks/Event/flowGraphPointerOverEventBlock.js +40 -0
- package/FlowGraph/Blocks/Event/flowGraphPointerOverEventBlock.js.map +1 -0
- package/FlowGraph/Blocks/Event/flowGraphReceiveCustomEventBlock.d.ts +12 -14
- package/FlowGraph/Blocks/Event/flowGraphReceiveCustomEventBlock.js +19 -26
- package/FlowGraph/Blocks/Event/flowGraphReceiveCustomEventBlock.js.map +1 -1
- package/FlowGraph/Blocks/Event/flowGraphSceneReadyEventBlock.d.ts +6 -12
- package/FlowGraph/Blocks/Event/flowGraphSceneReadyEventBlock.js +13 -24
- package/FlowGraph/Blocks/Event/flowGraphSceneReadyEventBlock.js.map +1 -1
- package/FlowGraph/Blocks/Event/flowGraphSceneTickEventBlock.d.ts +31 -7
- package/FlowGraph/Blocks/Event/flowGraphSceneTickEventBlock.js +22 -20
- package/FlowGraph/Blocks/Event/flowGraphSceneTickEventBlock.js.map +1 -1
- package/FlowGraph/Blocks/{Execution → Event}/flowGraphSendCustomEventBlock.d.ts +12 -7
- package/FlowGraph/Blocks/Event/flowGraphSendCustomEventBlock.js +39 -0
- package/FlowGraph/Blocks/Event/flowGraphSendCustomEventBlock.js.map +1 -0
- package/FlowGraph/Blocks/Event/index.d.ts +3 -0
- package/FlowGraph/Blocks/Event/index.js +3 -0
- package/FlowGraph/Blocks/Event/index.js.map +1 -1
- package/FlowGraph/Blocks/Execution/Animation/flowGraphBezierCurveEasingBlock.d.ts +44 -0
- package/FlowGraph/Blocks/Execution/Animation/flowGraphBezierCurveEasingBlock.js +46 -0
- package/FlowGraph/Blocks/Execution/Animation/flowGraphBezierCurveEasingBlock.js.map +1 -0
- package/FlowGraph/Blocks/Execution/Animation/flowGraphEasingBlock.d.ts +60 -0
- package/FlowGraph/Blocks/Execution/Animation/flowGraphEasingBlock.js +93 -0
- package/FlowGraph/Blocks/Execution/Animation/flowGraphEasingBlock.js.map +1 -0
- package/FlowGraph/Blocks/Execution/Animation/flowGraphInterpolationBlock.d.ts +82 -0
- package/FlowGraph/Blocks/Execution/Animation/flowGraphInterpolationBlock.js +105 -0
- package/FlowGraph/Blocks/Execution/Animation/flowGraphInterpolationBlock.js.map +1 -0
- package/FlowGraph/Blocks/Execution/Animation/flowGraphPauseAnimationBlock.d.ts +2 -2
- package/FlowGraph/Blocks/Execution/Animation/flowGraphPauseAnimationBlock.js +2 -2
- package/FlowGraph/Blocks/Execution/Animation/flowGraphPauseAnimationBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/Animation/flowGraphPlayAnimationBlock.d.ts +40 -42
- package/FlowGraph/Blocks/Execution/Animation/flowGraphPlayAnimationBlock.js +116 -50
- package/FlowGraph/Blocks/Execution/Animation/flowGraphPlayAnimationBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/Animation/flowGraphStopAnimationBlock.d.ts +12 -4
- package/FlowGraph/Blocks/Execution/Animation/flowGraphStopAnimationBlock.js +86 -8
- package/FlowGraph/Blocks/Execution/Animation/flowGraphStopAnimationBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/Animation/index.d.ts +3 -0
- package/FlowGraph/Blocks/Execution/Animation/index.js +3 -0
- package/FlowGraph/Blocks/Execution/Animation/index.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphBranchBlock.d.ts +1 -2
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphBranchBlock.js +3 -4
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphBranchBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/{Audio/flowGraphStopAudioBlock.d.ts → ControlFlow/flowGraphCancelDelayBlock.d.ts} +6 -8
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphCancelDelayBlock.js +31 -0
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphCancelDelayBlock.js.map +1 -0
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphCounterBlock.d.ts +2 -2
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphCounterBlock.js +5 -5
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphCounterBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphDebounceBlock.d.ts +0 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphDebounceBlock.js +2 -3
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphDebounceBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphDoNBlock.d.ts +5 -10
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphDoNBlock.js +11 -15
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphDoNBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphFlipFlopBlock.d.ts +11 -3
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphFlipFlopBlock.js +5 -6
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphFlipFlopBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphForLoopBlock.d.ts +27 -7
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphForLoopBlock.js +28 -30
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphForLoopBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphMultiGateBlock.d.ts +13 -16
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphMultiGateBlock.js +50 -52
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphMultiGateBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphSequenceBlock.d.ts +8 -9
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphSequenceBlock.js +26 -13
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphSequenceBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphSetDelayBlock.d.ts +32 -0
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphSetDelayBlock.js +84 -0
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphSetDelayBlock.js.map +1 -0
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphSwitchBlock.d.ts +20 -6
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphSwitchBlock.js +55 -16
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphSwitchBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphThrottleBlock.d.ts +3 -4
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphThrottleBlock.js +36 -13
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphThrottleBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphWaitAllBlock.d.ts +13 -5
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphWaitAllBlock.js +22 -17
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphWaitAllBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphWhileLoopBlock.d.ts +12 -16
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphWhileLoopBlock.js +21 -21
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphWhileLoopBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/index.d.ts +2 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/index.js +2 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/index.js.map +1 -1
- package/FlowGraph/Blocks/Execution/flowGraphConsoleLogBlock.d.ts +4 -5
- package/FlowGraph/Blocks/Execution/flowGraphConsoleLogBlock.js +13 -8
- package/FlowGraph/Blocks/Execution/flowGraphConsoleLogBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/flowGraphSetPropertyBlock.d.ts +33 -36
- package/FlowGraph/Blocks/Execution/flowGraphSetPropertyBlock.js +42 -26
- package/FlowGraph/Blocks/Execution/flowGraphSetPropertyBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/flowGraphSetVariableBlock.d.ts +10 -25
- package/FlowGraph/Blocks/Execution/flowGraphSetVariableBlock.js +38 -24
- package/FlowGraph/Blocks/Execution/flowGraphSetVariableBlock.js.map +1 -1
- package/FlowGraph/Blocks/Execution/index.d.ts +0 -3
- package/FlowGraph/Blocks/Execution/index.js +0 -3
- package/FlowGraph/Blocks/Execution/index.js.map +1 -1
- package/FlowGraph/Blocks/flowGraphBlockFactory.d.ts +16 -0
- package/FlowGraph/Blocks/flowGraphBlockFactory.js +292 -0
- package/FlowGraph/Blocks/flowGraphBlockFactory.js.map +1 -0
- package/FlowGraph/Blocks/flowGraphBlockNames.d.ts +145 -0
- package/FlowGraph/Blocks/flowGraphBlockNames.js +147 -0
- package/FlowGraph/Blocks/flowGraphBlockNames.js.map +1 -0
- package/FlowGraph/Blocks/index.d.ts +2 -0
- package/FlowGraph/Blocks/index.js +2 -0
- package/FlowGraph/Blocks/index.js.map +1 -1
- package/FlowGraph/{flowGraphInteger.d.ts → CustomTypes/flowGraphInteger.d.ts} +2 -3
- package/FlowGraph/{flowGraphInteger.js → CustomTypes/flowGraphInteger.js} +4 -5
- package/FlowGraph/CustomTypes/flowGraphInteger.js.map +1 -0
- package/FlowGraph/CustomTypes/flowGraphMatrix.d.ts +196 -0
- package/FlowGraph/CustomTypes/flowGraphMatrix.js +272 -0
- package/FlowGraph/CustomTypes/flowGraphMatrix.js.map +1 -0
- package/FlowGraph/CustomTypes/index.d.ts +2 -0
- package/FlowGraph/CustomTypes/index.js +3 -0
- package/FlowGraph/CustomTypes/index.js.map +1 -0
- package/FlowGraph/flowGraph.d.ts +29 -34
- package/FlowGraph/flowGraph.js +120 -104
- package/FlowGraph/flowGraph.js.map +1 -1
- package/FlowGraph/flowGraphAssetsContext.d.ts +29 -0
- package/FlowGraph/flowGraphAssetsContext.js +52 -0
- package/FlowGraph/flowGraphAssetsContext.js.map +1 -0
- package/FlowGraph/flowGraphAsyncExecutionBlock.d.ts +15 -8
- package/FlowGraph/flowGraphAsyncExecutionBlock.js +25 -5
- package/FlowGraph/flowGraphAsyncExecutionBlock.js.map +1 -1
- package/FlowGraph/flowGraphBlock.d.ts +22 -15
- package/FlowGraph/flowGraphBlock.js +31 -52
- package/FlowGraph/flowGraphBlock.js.map +1 -1
- package/FlowGraph/flowGraphConnection.d.ts +13 -12
- package/FlowGraph/flowGraphConnection.js +31 -16
- package/FlowGraph/flowGraphConnection.js.map +1 -1
- package/FlowGraph/flowGraphContext.d.ts +89 -13
- package/FlowGraph/flowGraphContext.js +210 -23
- package/FlowGraph/flowGraphContext.js.map +1 -1
- package/FlowGraph/flowGraphCoordinator.d.ts +4 -10
- package/FlowGraph/flowGraphCoordinator.js +4 -16
- package/FlowGraph/flowGraphCoordinator.js.map +1 -1
- package/FlowGraph/flowGraphDataConnection.d.ts +52 -14
- package/FlowGraph/flowGraphDataConnection.js +73 -26
- package/FlowGraph/flowGraphDataConnection.js.map +1 -1
- package/FlowGraph/flowGraphEventBlock.d.ts +17 -1
- package/FlowGraph/flowGraphEventBlock.js +13 -2
- package/FlowGraph/flowGraphEventBlock.js.map +1 -1
- package/FlowGraph/flowGraphEventType.d.ts +16 -0
- package/FlowGraph/flowGraphEventType.js +18 -0
- package/FlowGraph/flowGraphEventType.js.map +1 -0
- package/FlowGraph/flowGraphExecutionBlock.d.ts +11 -1
- package/FlowGraph/flowGraphExecutionBlock.js +21 -2
- package/FlowGraph/flowGraphExecutionBlock.js.map +1 -1
- package/FlowGraph/flowGraphExecutionBlockWithOutSignal.d.ts +2 -2
- package/FlowGraph/flowGraphExecutionBlockWithOutSignal.js +0 -1
- package/FlowGraph/flowGraphExecutionBlockWithOutSignal.js.map +1 -1
- package/FlowGraph/flowGraphLogger.d.ts +60 -0
- package/FlowGraph/flowGraphLogger.js +53 -0
- package/FlowGraph/flowGraphLogger.js.map +1 -0
- package/FlowGraph/flowGraphParser.d.ts +85 -0
- package/FlowGraph/flowGraphParser.js +271 -0
- package/FlowGraph/flowGraphParser.js.map +1 -0
- package/FlowGraph/flowGraphPathConverter.d.ts +1 -1
- package/FlowGraph/flowGraphPathConverter.js +3 -2
- package/FlowGraph/flowGraphPathConverter.js.map +1 -1
- package/FlowGraph/flowGraphPathConverterComponent.d.ts +8 -1
- package/FlowGraph/flowGraphPathConverterComponent.js +18 -2
- package/FlowGraph/flowGraphPathConverterComponent.js.map +1 -1
- package/FlowGraph/flowGraphRichTypes.d.ts +51 -9
- package/FlowGraph/flowGraphRichTypes.js +160 -50
- package/FlowGraph/flowGraphRichTypes.js.map +1 -1
- package/FlowGraph/flowGraphSceneEventCoordinator.d.ts +45 -0
- package/FlowGraph/flowGraphSceneEventCoordinator.js +77 -0
- package/FlowGraph/flowGraphSceneEventCoordinator.js.map +1 -0
- package/FlowGraph/flowGraphSignalConnection.d.ts +8 -5
- package/FlowGraph/flowGraphSignalConnection.js +26 -9
- package/FlowGraph/flowGraphSignalConnection.js.map +1 -1
- package/FlowGraph/index.d.ts +6 -1
- package/FlowGraph/index.js +7 -1
- package/FlowGraph/index.js.map +1 -1
- package/FlowGraph/serialization.d.ts +5 -2
- package/FlowGraph/serialization.js +94 -22
- package/FlowGraph/serialization.js.map +1 -1
- package/FlowGraph/typeDefinitions.d.ts +74 -12
- package/FlowGraph/typeDefinitions.js.map +1 -1
- package/FlowGraph/utils.d.ts +47 -0
- package/FlowGraph/utils.js +55 -0
- package/FlowGraph/utils.js.map +1 -1
- package/Layers/effectLayer.d.ts +5 -0
- package/Layers/effectLayer.js +7 -0
- package/Layers/effectLayer.js.map +1 -1
- package/Loading/sceneLoader.d.ts +25 -11
- package/Loading/sceneLoader.js +28 -11
- package/Loading/sceneLoader.js.map +1 -1
- package/Materials/material.js +1 -0
- package/Materials/material.js.map +1 -1
- package/Maths/math.path.js +3 -0
- package/Maths/math.path.js.map +1 -1
- package/Meshes/csg2.d.ts +2 -2
- package/Meshes/csg2.js +2 -2
- package/Meshes/csg2.js.map +1 -1
- package/Meshes/geometry.d.ts +2 -1
- package/Meshes/geometry.js +8 -2
- package/Meshes/geometry.js.map +1 -1
- package/Meshes/instancedMesh.d.ts +5 -0
- package/Meshes/instancedMesh.js +6 -0
- package/Meshes/instancedMesh.js.map +1 -1
- package/Meshes/mesh.d.ts +2 -1
- package/Meshes/mesh.js +3 -2
- package/Meshes/mesh.js.map +1 -1
- package/Misc/environmentTextureTools.js +2 -2
- package/Misc/environmentTextureTools.js.map +1 -1
- package/ObjectModel/objectModelInterfaces.d.ts +2 -2
- package/ObjectModel/objectModelInterfaces.js.map +1 -1
- package/Rendering/IBLShadows/iblShadowsPluginMaterial.js +26 -18
- package/Rendering/IBLShadows/iblShadowsPluginMaterial.js.map +1 -1
- package/package.json +1 -1
- package/scene.js +8 -0
- package/scene.js.map +1 -1
- package/FlowGraph/Blocks/Data/Logic/flowGraphLogicBlocks.d.ts +0 -24
- package/FlowGraph/Blocks/Data/Logic/flowGraphLogicBlocks.js +0 -39
- package/FlowGraph/Blocks/Data/Logic/flowGraphLogicBlocks.js.map +0 -1
- package/FlowGraph/Blocks/Data/Logic/index.d.ts +0 -1
- package/FlowGraph/Blocks/Data/Logic/index.js +0 -2
- package/FlowGraph/Blocks/Data/Logic/index.js.map +0 -1
- package/FlowGraph/Blocks/Data/flowGraphCoordinateTransformBlock.js.map +0 -1
- package/FlowGraph/Blocks/Execution/Audio/flowGraphPlayAudioBlock.d.ts +0 -19
- package/FlowGraph/Blocks/Execution/Audio/flowGraphPlayAudioBlock.js +0 -26
- package/FlowGraph/Blocks/Execution/Audio/flowGraphPlayAudioBlock.js.map +0 -1
- package/FlowGraph/Blocks/Execution/Audio/flowGraphStopAudioBlock.js +0 -25
- package/FlowGraph/Blocks/Execution/Audio/flowGraphStopAudioBlock.js.map +0 -1
- package/FlowGraph/Blocks/Execution/Audio/index.d.ts +0 -2
- package/FlowGraph/Blocks/Execution/Audio/index.js +0 -3
- package/FlowGraph/Blocks/Execution/Audio/index.js.map +0 -1
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphTimerBlock.d.ts +0 -31
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphTimerBlock.js +0 -69
- package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphTimerBlock.js.map +0 -1
- package/FlowGraph/Blocks/Execution/flowGraphSendCustomEventBlock.js +0 -38
- package/FlowGraph/Blocks/Execution/flowGraphSendCustomEventBlock.js.map +0 -1
- package/FlowGraph/flowGraphContextLogger.d.ts +0 -9
- package/FlowGraph/flowGraphContextLogger.js +0 -14
- package/FlowGraph/flowGraphContextLogger.js.map +0 -1
- package/FlowGraph/flowGraphInteger.js.map +0 -1
|
@@ -1,57 +1,62 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import type {
|
|
5
|
-
import type {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
export interface IFlowGraphGetPropertyBlockConfiguration extends IFlowGraphBlockConfiguration {
|
|
1
|
+
import type { AssetType, FlowGraphAssetType } from "../../flowGraphAssetsContext.js";
|
|
2
|
+
import type { IFlowGraphBlockConfiguration } from "../../flowGraphBlock.js";
|
|
3
|
+
import { FlowGraphBlock } from "../../flowGraphBlock.js";
|
|
4
|
+
import type { FlowGraphContext } from "../../flowGraphContext.js";
|
|
5
|
+
import type { FlowGraphDataConnection } from "../../flowGraphDataConnection.js";
|
|
6
|
+
export interface IFlowGraphGetPropertyBlockConfiguration<O extends FlowGraphAssetType> extends IFlowGraphBlockConfiguration {
|
|
7
|
+
/**
|
|
8
|
+
* The name of the property that will be set
|
|
9
|
+
*/
|
|
10
|
+
propertyName?: string;
|
|
12
11
|
/**
|
|
13
|
-
* The
|
|
12
|
+
* The target asset from which the property will be retrieved
|
|
14
13
|
*/
|
|
15
|
-
|
|
14
|
+
object?: AssetType<O>;
|
|
16
15
|
/**
|
|
17
|
-
*
|
|
16
|
+
* If true, the block will reset the output to the default value when the target asset is undefined.
|
|
18
17
|
*/
|
|
19
|
-
|
|
18
|
+
resetToDefaultWhenUndefined?: boolean;
|
|
20
19
|
}
|
|
21
20
|
/**
|
|
22
|
-
*
|
|
21
|
+
* This block will deliver a property of an asset, based on the property name and an input asset.
|
|
22
|
+
* The property name can include dots ("."), which will be interpreted as a path to the property.
|
|
23
|
+
*
|
|
24
|
+
* For example, with an input of a mesh asset, the property name "position.x" will deliver the x component of the position of the mesh.
|
|
25
|
+
*
|
|
26
|
+
* Note that it is recommended to input the object on which you are working on (i.e. a material) rather than providing a mesh as object and then getting the material from it.
|
|
23
27
|
*/
|
|
24
|
-
export declare class FlowGraphGetPropertyBlock extends FlowGraphBlock {
|
|
28
|
+
export declare class FlowGraphGetPropertyBlock<P extends any, O extends FlowGraphAssetType> extends FlowGraphBlock {
|
|
25
29
|
/**
|
|
26
30
|
* the configuration of the block
|
|
27
31
|
*/
|
|
28
|
-
config: IFlowGraphGetPropertyBlockConfiguration
|
|
32
|
+
config: IFlowGraphGetPropertyBlockConfiguration<O>;
|
|
29
33
|
/**
|
|
30
34
|
* Output connection: The value of the property.
|
|
31
35
|
*/
|
|
32
|
-
readonly value: FlowGraphDataConnection<
|
|
36
|
+
readonly value: FlowGraphDataConnection<P>;
|
|
33
37
|
/**
|
|
34
|
-
* The
|
|
38
|
+
* Input connection: The asset from which the property will be retrieved
|
|
35
39
|
*/
|
|
36
|
-
readonly
|
|
37
|
-
constructor(
|
|
40
|
+
readonly object: FlowGraphDataConnection<AssetType<O>>;
|
|
38
41
|
/**
|
|
39
|
-
*
|
|
42
|
+
* Input connection: The name of the property that will be set
|
|
40
43
|
*/
|
|
41
|
-
|
|
42
|
-
_updateOutputs(context: FlowGraphContext): void;
|
|
44
|
+
readonly propertyName: FlowGraphDataConnection<string>;
|
|
43
45
|
/**
|
|
44
|
-
*
|
|
45
|
-
* @returns the class name
|
|
46
|
+
* Output connection: Whether the value is valid.
|
|
46
47
|
*/
|
|
47
|
-
|
|
48
|
+
readonly isValid: FlowGraphDataConnection<boolean>;
|
|
48
49
|
/**
|
|
49
|
-
*
|
|
50
|
-
*
|
|
50
|
+
* Input connection: A function that can be used to get the value of the property.
|
|
51
|
+
* This will be used if defined, instead of the default get function.
|
|
51
52
|
*/
|
|
52
|
-
|
|
53
|
+
readonly customGetFunction: FlowGraphDataConnection<(target: AssetType<O>, propertyName: string, context: FlowGraphContext) => P | undefined>;
|
|
54
|
+
constructor(
|
|
53
55
|
/**
|
|
54
|
-
*
|
|
56
|
+
* the configuration of the block
|
|
55
57
|
*/
|
|
56
|
-
|
|
58
|
+
config: IFlowGraphGetPropertyBlockConfiguration<O>);
|
|
59
|
+
_updateOutputs(context: FlowGraphContext): void;
|
|
60
|
+
private _getPropertyValue;
|
|
61
|
+
getClassName(): string;
|
|
57
62
|
}
|
|
@@ -1,9 +1,13 @@
|
|
|
1
|
-
import { RegisterClass } from "../../../Misc/typeStore.js";
|
|
2
1
|
import { FlowGraphBlock } from "../../flowGraphBlock.js";
|
|
3
2
|
import { RichTypeAny } from "../../flowGraphRichTypes.js";
|
|
4
|
-
import {
|
|
3
|
+
import { RegisterClass } from "../../../Misc/typeStore.js";
|
|
5
4
|
/**
|
|
6
|
-
*
|
|
5
|
+
* This block will deliver a property of an asset, based on the property name and an input asset.
|
|
6
|
+
* The property name can include dots ("."), which will be interpreted as a path to the property.
|
|
7
|
+
*
|
|
8
|
+
* For example, with an input of a mesh asset, the property name "position.x" will deliver the x component of the position of the mesh.
|
|
9
|
+
*
|
|
10
|
+
* Note that it is recommended to input the object on which you are working on (i.e. a material) rather than providing a mesh as object and then getting the material from it.
|
|
7
11
|
*/
|
|
8
12
|
export class FlowGraphGetPropertyBlock extends FlowGraphBlock {
|
|
9
13
|
constructor(
|
|
@@ -13,33 +17,46 @@ export class FlowGraphGetPropertyBlock extends FlowGraphBlock {
|
|
|
13
17
|
config) {
|
|
14
18
|
super(config);
|
|
15
19
|
this.config = config;
|
|
20
|
+
this.object = this.registerDataInput("object", RichTypeAny, config.object);
|
|
21
|
+
this.propertyName = this.registerDataInput("propertyName", RichTypeAny, config.propertyName);
|
|
16
22
|
this.value = this.registerDataOutput("value", RichTypeAny);
|
|
17
|
-
this.
|
|
23
|
+
this.isValid = this.registerDataOutput("isValid", RichTypeAny, false);
|
|
24
|
+
this.customGetFunction = this.registerDataInput("customGetFunction", RichTypeAny);
|
|
18
25
|
}
|
|
19
26
|
_updateOutputs(context) {
|
|
20
|
-
const
|
|
21
|
-
|
|
22
|
-
|
|
27
|
+
const getter = this.customGetFunction.getValue(context);
|
|
28
|
+
let value;
|
|
29
|
+
if (getter) {
|
|
30
|
+
value = getter(this.object.getValue(context), this.propertyName.getValue(context), context);
|
|
31
|
+
}
|
|
32
|
+
else {
|
|
33
|
+
const target = this.object.getValue(context);
|
|
34
|
+
const propertyName = this.propertyName.getValue(context);
|
|
35
|
+
value = target && propertyName ? this._getPropertyValue(target, propertyName) : undefined;
|
|
36
|
+
}
|
|
37
|
+
if (value === undefined) {
|
|
38
|
+
this.value.resetToDefaultValue(context);
|
|
39
|
+
this.isValid.setValue(false, context);
|
|
40
|
+
}
|
|
41
|
+
else {
|
|
42
|
+
this.value.setValue(value, context);
|
|
43
|
+
this.isValid.setValue(true, context);
|
|
44
|
+
}
|
|
23
45
|
}
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
46
|
+
_getPropertyValue(target, propertyName) {
|
|
47
|
+
const path = propertyName.split(".");
|
|
48
|
+
let value = target;
|
|
49
|
+
for (const prop of path) {
|
|
50
|
+
value = value[prop];
|
|
51
|
+
if (value === undefined) {
|
|
52
|
+
return;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
return value;
|
|
30
56
|
}
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
* @param serializationObject the object to serialize to
|
|
34
|
-
*/
|
|
35
|
-
serialize(serializationObject = {}) {
|
|
36
|
-
super.serialize(serializationObject);
|
|
37
|
-
serializationObject.config.path = this.config.path;
|
|
57
|
+
getClassName() {
|
|
58
|
+
return "FlowGraphGetPropertyBlock" /* FlowGraphBlockNames.GetProperty */;
|
|
38
59
|
}
|
|
39
60
|
}
|
|
40
|
-
|
|
41
|
-
* Class name of the block.
|
|
42
|
-
*/
|
|
43
|
-
FlowGraphGetPropertyBlock.ClassName = "FGGetPropertyBlock";
|
|
44
|
-
RegisterClass(FlowGraphGetPropertyBlock.ClassName, FlowGraphGetPropertyBlock);
|
|
61
|
+
RegisterClass("FlowGraphGetPropertyBlock" /* FlowGraphBlockNames.GetProperty */, FlowGraphGetPropertyBlock);
|
|
45
62
|
//# sourceMappingURL=flowGraphGetPropertyBlock.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowGraphGetPropertyBlock.js","sourceRoot":"","sources":["../../../../../../dev/core/src/FlowGraph/Blocks/Data/flowGraphGetPropertyBlock.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"flowGraphGetPropertyBlock.js","sourceRoot":"","sources":["../../../../../../dev/core/src/FlowGraph/Blocks/Data/flowGraphGetPropertyBlock.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,gCAAsC;AAG/D,OAAO,EAAE,WAAW,EAAE,oCAA0C;AAChE,OAAO,EAAE,aAAa,EAAE,mCAA4B;AAoBpD;;;;;;;GAOG;AACH,MAAM,OAAO,yBAAuE,SAAQ,cAAc;IA2BtG;IACI;;OAEG;IACa,MAAkD;QAElE,KAAK,CAAC,MAAM,CAAC,CAAC;QAFE,WAAM,GAAN,MAAM,CAA4C;QAGlE,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,iBAAiB,CAAC,QAAQ,EAAE,WAAW,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC;QAC3E,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,iBAAiB,CAAC,cAAc,EAAE,WAAW,EAAE,MAAM,CAAC,YAAY,CAAC,CAAC;QAC7F,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,kBAAkB,CAAC,OAAO,EAAE,WAAW,CAAC,CAAC;QAC3D,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,kBAAkB,CAAC,SAAS,EAAE,WAAW,EAAE,KAAK,CAAC,CAAC;QACtE,IAAI,CAAC,iBAAiB,GAAG,IAAI,CAAC,iBAAiB,CAAC,mBAAmB,EAAE,WAAW,CAAC,CAAC;IACtF,CAAC;IAEe,cAAc,CAAC,OAAyB;QACpD,MAAM,MAAM,GAAG,IAAI,CAAC,iBAAiB,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;QACxD,IAAI,KAAK,CAAC;QACV,IAAI,MAAM,EAAE,CAAC;YACT,KAAK,GAAG,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,YAAY,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC,CAAC;QAChG,CAAC;aAAM,CAAC;YACJ,MAAM,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;YAC7C,MAAM,YAAY,GAAG,IAAI,CAAC,YAAY,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;YACzD,KAAK,GAAG,MAAM,IAAI,YAAY,CAAC,CAAC,CAAC,IAAI,CAAC,iBAAiB,CAAC,MAAM,EAAE,YAAY,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;QAC9F,CAAC;QACD,IAAI,KAAK,KAAK,SAAS,EAAE,CAAC;YACtB,IAAI,CAAC,KAAK,CAAC,mBAAmB,CAAC,OAAO,CAAC,CAAC;YACxC,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;QAC1C,CAAC;aAAM,CAAC;YACJ,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;YACpC,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;QACzC,CAAC;IACL,CAAC;IAEO,iBAAiB,CAAC,MAAoB,EAAE,YAAoB;QAChE,MAAM,IAAI,GAAG,YAAY,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACrC,IAAI,KAAK,GAAQ,MAAM,CAAC;QACxB,KAAK,MAAM,IAAI,IAAI,IAAI,EAAE,CAAC;YACtB,KAAK,GAAG,KAAK,CAAC,IAAI,CAAC,CAAC;YACpB,IAAI,KAAK,KAAK,SAAS,EAAE,CAAC;gBACtB,OAAO;YACX,CAAC;QACL,CAAC;QACD,OAAO,KAAU,CAAC;IACtB,CAAC;IAEe,YAAY;QACxB,yEAAuC;IAC3C,CAAC;CACJ;AAED,aAAa,oEAAkC,yBAAyB,CAAC,CAAC","sourcesContent":["import type { AssetType, FlowGraphAssetType } from \"core/FlowGraph/flowGraphAssetsContext\";\nimport type { IFlowGraphBlockConfiguration } from \"core/FlowGraph/flowGraphBlock\";\nimport { FlowGraphBlock } from \"core/FlowGraph/flowGraphBlock\";\nimport type { FlowGraphContext } from \"core/FlowGraph/flowGraphContext\";\nimport type { FlowGraphDataConnection } from \"core/FlowGraph/flowGraphDataConnection\";\nimport { RichTypeAny } from \"core/FlowGraph/flowGraphRichTypes\";\nimport { RegisterClass } from \"core/Misc/typeStore\";\nimport { FlowGraphBlockNames } from \"../flowGraphBlockNames\";\n\nexport interface IFlowGraphGetPropertyBlockConfiguration<O extends FlowGraphAssetType> extends IFlowGraphBlockConfiguration {\n /**\n * The name of the property that will be set\n */\n propertyName?: string;\n\n /**\n * The target asset from which the property will be retrieved\n */\n object?: AssetType<O>;\n\n /**\n * If true, the block will reset the output to the default value when the target asset is undefined.\n */\n resetToDefaultWhenUndefined?: boolean;\n}\n\n/**\n * This block will deliver a property of an asset, based on the property name and an input asset.\n * The property name can include dots (\".\"), which will be interpreted as a path to the property.\n *\n * For example, with an input of a mesh asset, the property name \"position.x\" will deliver the x component of the position of the mesh.\n *\n * Note that it is recommended to input the object on which you are working on (i.e. a material) rather than providing a mesh as object and then getting the material from it.\n */\nexport class FlowGraphGetPropertyBlock<P extends any, O extends FlowGraphAssetType> extends FlowGraphBlock {\n /**\n * Output connection: The value of the property.\n */\n public readonly value: FlowGraphDataConnection<P>;\n\n /**\n * Input connection: The asset from which the property will be retrieved\n */\n public readonly object: FlowGraphDataConnection<AssetType<O>>;\n\n /**\n * Input connection: The name of the property that will be set\n */\n public readonly propertyName: FlowGraphDataConnection<string>;\n\n /**\n * Output connection: Whether the value is valid.\n */\n public readonly isValid: FlowGraphDataConnection<boolean>;\n\n /**\n * Input connection: A function that can be used to get the value of the property.\n * This will be used if defined, instead of the default get function.\n */\n public readonly customGetFunction: FlowGraphDataConnection<(target: AssetType<O>, propertyName: string, context: FlowGraphContext) => P | undefined>;\n\n constructor(\n /**\n * the configuration of the block\n */\n public override config: IFlowGraphGetPropertyBlockConfiguration<O>\n ) {\n super(config);\n this.object = this.registerDataInput(\"object\", RichTypeAny, config.object);\n this.propertyName = this.registerDataInput(\"propertyName\", RichTypeAny, config.propertyName);\n this.value = this.registerDataOutput(\"value\", RichTypeAny);\n this.isValid = this.registerDataOutput(\"isValid\", RichTypeAny, false);\n this.customGetFunction = this.registerDataInput(\"customGetFunction\", RichTypeAny);\n }\n\n public override _updateOutputs(context: FlowGraphContext): void {\n const getter = this.customGetFunction.getValue(context);\n let value;\n if (getter) {\n value = getter(this.object.getValue(context), this.propertyName.getValue(context), context);\n } else {\n const target = this.object.getValue(context);\n const propertyName = this.propertyName.getValue(context);\n value = target && propertyName ? this._getPropertyValue(target, propertyName) : undefined;\n }\n if (value === undefined) {\n this.value.resetToDefaultValue(context);\n this.isValid.setValue(false, context);\n } else {\n this.value.setValue(value, context);\n this.isValid.setValue(true, context);\n }\n }\n\n private _getPropertyValue(target: AssetType<O>, propertyName: string): P | undefined {\n const path = propertyName.split(\".\");\n let value: any = target;\n for (const prop of path) {\n value = value[prop];\n if (value === undefined) {\n return;\n }\n }\n return value as P;\n }\n\n public override getClassName(): string {\n return FlowGraphBlockNames.GetProperty;\n }\n}\n\nRegisterClass(FlowGraphBlockNames.GetProperty, FlowGraphGetPropertyBlock);\n"]}
|
|
@@ -3,46 +3,41 @@ import type { IFlowGraphBlockConfiguration } from "../../flowGraphBlock";
|
|
|
3
3
|
import { FlowGraphBlock } from "../../flowGraphBlock";
|
|
4
4
|
import type { FlowGraphDataConnection } from "../../flowGraphDataConnection";
|
|
5
5
|
/**
|
|
6
|
-
* @experimental
|
|
7
6
|
* The configuration of the FlowGraphGetVariableBlock.
|
|
8
7
|
*/
|
|
9
|
-
export interface IFlowGraphGetVariableBlockConfiguration extends IFlowGraphBlockConfiguration {
|
|
8
|
+
export interface IFlowGraphGetVariableBlockConfiguration<T> extends IFlowGraphBlockConfiguration {
|
|
10
9
|
/**
|
|
11
10
|
* The name of the variable to get.
|
|
12
11
|
*/
|
|
13
|
-
|
|
12
|
+
variable: string;
|
|
13
|
+
/**
|
|
14
|
+
* The initial value of the variable.
|
|
15
|
+
*/
|
|
16
|
+
initialValue?: T;
|
|
14
17
|
}
|
|
15
18
|
/**
|
|
16
19
|
* A block that gets the value of a variable.
|
|
17
|
-
*
|
|
20
|
+
* Variables are an stored in the context of the flow graph.
|
|
18
21
|
*/
|
|
19
22
|
export declare class FlowGraphGetVariableBlock<T> extends FlowGraphBlock {
|
|
20
|
-
config: IFlowGraphGetVariableBlockConfiguration
|
|
23
|
+
config: IFlowGraphGetVariableBlockConfiguration<T>;
|
|
21
24
|
/**
|
|
22
25
|
* Output connection: The value of the variable.
|
|
23
26
|
*/
|
|
24
|
-
readonly
|
|
27
|
+
readonly value: FlowGraphDataConnection<T>;
|
|
25
28
|
/**
|
|
26
29
|
* Construct a FlowGraphGetVariableBlock.
|
|
27
30
|
* @param config construction parameters
|
|
28
31
|
*/
|
|
29
|
-
constructor(config: IFlowGraphGetVariableBlockConfiguration);
|
|
32
|
+
constructor(config: IFlowGraphGetVariableBlockConfiguration<T>);
|
|
30
33
|
/**
|
|
31
34
|
* @internal
|
|
32
35
|
*/
|
|
33
36
|
_updateOutputs(context: FlowGraphContext): void;
|
|
34
|
-
/**
|
|
35
|
-
* Gets the class name of this block
|
|
36
|
-
* @returns the class name
|
|
37
|
-
*/
|
|
38
|
-
getClassName(): string;
|
|
39
37
|
/**
|
|
40
38
|
* Serializes this block
|
|
41
39
|
* @param serializationObject the object to serialize to
|
|
42
40
|
*/
|
|
43
41
|
serialize(serializationObject?: any): void;
|
|
44
|
-
|
|
45
|
-
* Class name of the block.
|
|
46
|
-
*/
|
|
47
|
-
static ClassName: string;
|
|
42
|
+
getClassName(): string;
|
|
48
43
|
}
|
|
@@ -3,7 +3,7 @@ import { RichTypeAny } from "../../flowGraphRichTypes.js";
|
|
|
3
3
|
import { RegisterClass } from "../../../Misc/typeStore.js";
|
|
4
4
|
/**
|
|
5
5
|
* A block that gets the value of a variable.
|
|
6
|
-
*
|
|
6
|
+
* Variables are an stored in the context of the flow graph.
|
|
7
7
|
*/
|
|
8
8
|
export class FlowGraphGetVariableBlock extends FlowGraphBlock {
|
|
9
9
|
/**
|
|
@@ -14,36 +14,28 @@ export class FlowGraphGetVariableBlock extends FlowGraphBlock {
|
|
|
14
14
|
super(config);
|
|
15
15
|
this.config = config;
|
|
16
16
|
// The output connection has to have the name of the variable.
|
|
17
|
-
this.
|
|
17
|
+
this.value = this.registerDataOutput("value", RichTypeAny, config.initialValue);
|
|
18
18
|
}
|
|
19
19
|
/**
|
|
20
20
|
* @internal
|
|
21
21
|
*/
|
|
22
22
|
_updateOutputs(context) {
|
|
23
|
-
const variableNameValue = this.config.
|
|
23
|
+
const variableNameValue = this.config.variable;
|
|
24
24
|
if (context.hasVariable(variableNameValue)) {
|
|
25
|
-
this.
|
|
25
|
+
this.value.setValue(context.getVariable(variableNameValue), context);
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
|
-
/**
|
|
29
|
-
* Gets the class name of this block
|
|
30
|
-
* @returns the class name
|
|
31
|
-
*/
|
|
32
|
-
getClassName() {
|
|
33
|
-
return FlowGraphGetVariableBlock.ClassName;
|
|
34
|
-
}
|
|
35
28
|
/**
|
|
36
29
|
* Serializes this block
|
|
37
30
|
* @param serializationObject the object to serialize to
|
|
38
31
|
*/
|
|
39
32
|
serialize(serializationObject) {
|
|
40
33
|
super.serialize(serializationObject);
|
|
41
|
-
serializationObject.config.
|
|
34
|
+
serializationObject.config.variable = this.config.variable;
|
|
35
|
+
}
|
|
36
|
+
getClassName() {
|
|
37
|
+
return "FlowGraphGetVariableBlock" /* FlowGraphBlockNames.GetVariable */;
|
|
42
38
|
}
|
|
43
39
|
}
|
|
44
|
-
|
|
45
|
-
* Class name of the block.
|
|
46
|
-
*/
|
|
47
|
-
FlowGraphGetVariableBlock.ClassName = "FGGetVariableBlock";
|
|
48
|
-
RegisterClass(FlowGraphGetVariableBlock.ClassName, FlowGraphGetVariableBlock);
|
|
40
|
+
RegisterClass("FlowGraphGetVariableBlock" /* FlowGraphBlockNames.GetVariable */, FlowGraphGetVariableBlock);
|
|
49
41
|
//# sourceMappingURL=flowGraphGetVariableBlock.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowGraphGetVariableBlock.js","sourceRoot":"","sources":["../../../../../../dev/core/src/FlowGraph/Blocks/Data/flowGraphGetVariableBlock.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAEtD,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;
|
|
1
|
+
{"version":3,"file":"flowGraphGetVariableBlock.js","sourceRoot":"","sources":["../../../../../../dev/core/src/FlowGraph/Blocks/Data/flowGraphGetVariableBlock.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAEtD,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAkBxD;;;GAGG;AACH,MAAM,OAAO,yBAA6B,SAAQ,cAAc;IAM5D;;;OAGG;IACH,YAA4B,MAAkD;QAC1E,KAAK,CAAC,MAAM,CAAC,CAAC;QADU,WAAM,GAAN,MAAM,CAA4C;QAG1E,8DAA8D;QAC9D,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,kBAAkB,CAAC,OAAO,EAAE,WAAW,EAAE,MAAM,CAAC,YAAY,CAAC,CAAC;IACpF,CAAC;IAED;;OAEG;IACa,cAAc,CAAC,OAAyB;QACpD,MAAM,iBAAiB,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC;QAC/C,IAAI,OAAO,CAAC,WAAW,CAAC,iBAAiB,CAAC,EAAE,CAAC;YACzC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,OAAO,CAAC,WAAW,CAAC,iBAAiB,CAAC,EAAE,OAAO,CAAC,CAAC;QACzE,CAAC;IACL,CAAC;IAED;;;OAGG;IACa,SAAS,CAAC,mBAAyB;QAC/C,KAAK,CAAC,SAAS,CAAC,mBAAmB,CAAC,CAAC;QACrC,mBAAmB,CAAC,MAAM,CAAC,QAAQ,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC;IAC/D,CAAC;IAEe,YAAY;QACxB,yEAAuC;IAC3C,CAAC;CACJ;AAED,aAAa,oEAAkC,yBAAyB,CAAC,CAAC","sourcesContent":["import type { FlowGraphContext } from \"../../flowGraphContext\";\r\nimport type { IFlowGraphBlockConfiguration } from \"../../flowGraphBlock\";\r\nimport { FlowGraphBlock } from \"../../flowGraphBlock\";\r\nimport type { FlowGraphDataConnection } from \"../../flowGraphDataConnection\";\r\nimport { RichTypeAny } from \"../../flowGraphRichTypes\";\r\nimport { RegisterClass } from \"../../../Misc/typeStore\";\r\nimport { FlowGraphBlockNames } from \"../flowGraphBlockNames\";\r\n\r\n/**\r\n * The configuration of the FlowGraphGetVariableBlock.\r\n */\r\nexport interface IFlowGraphGetVariableBlockConfiguration<T> extends IFlowGraphBlockConfiguration {\r\n /**\r\n * The name of the variable to get.\r\n */\r\n variable: string;\r\n\r\n /**\r\n * The initial value of the variable.\r\n */\r\n initialValue?: T;\r\n}\r\n\r\n/**\r\n * A block that gets the value of a variable.\r\n * Variables are an stored in the context of the flow graph.\r\n */\r\nexport class FlowGraphGetVariableBlock<T> extends FlowGraphBlock {\r\n /**\r\n * Output connection: The value of the variable.\r\n */\r\n public readonly value: FlowGraphDataConnection<T>;\r\n\r\n /**\r\n * Construct a FlowGraphGetVariableBlock.\r\n * @param config construction parameters\r\n */\r\n constructor(public override config: IFlowGraphGetVariableBlockConfiguration<T>) {\r\n super(config);\r\n\r\n // The output connection has to have the name of the variable.\r\n this.value = this.registerDataOutput(\"value\", RichTypeAny, config.initialValue);\r\n }\r\n\r\n /**\r\n * @internal\r\n */\r\n public override _updateOutputs(context: FlowGraphContext): void {\r\n const variableNameValue = this.config.variable;\r\n if (context.hasVariable(variableNameValue)) {\r\n this.value.setValue(context.getVariable(variableNameValue), context);\r\n }\r\n }\r\n\r\n /**\r\n * Serializes this block\r\n * @param serializationObject the object to serialize to\r\n */\r\n public override serialize(serializationObject?: any): void {\r\n super.serialize(serializationObject);\r\n serializationObject.config.variable = this.config.variable;\r\n }\r\n\r\n public override getClassName(): string {\r\n return FlowGraphBlockNames.GetVariable;\r\n }\r\n}\r\n\r\nRegisterClass(FlowGraphBlockNames.GetVariable, FlowGraphGetVariableBlock);\r\n"]}
|
|
@@ -4,7 +4,7 @@ import type { FlowGraphContext } from "../../flowGraphContext";
|
|
|
4
4
|
import type { IFlowGraphBlockConfiguration } from "../../flowGraphBlock";
|
|
5
5
|
import { FlowGraphCachedOperationBlock } from "./flowGraphCachedOperationBlock";
|
|
6
6
|
/**
|
|
7
|
-
* @
|
|
7
|
+
* @internal
|
|
8
8
|
* The base block for all ternary operation blocks.
|
|
9
9
|
*/
|
|
10
10
|
export declare class FlowGraphTernaryOperationBlock<T1, T2, T3, ResultT> extends FlowGraphCachedOperationBlock<ResultT> {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowGraphTernaryOperationBlock.js","sourceRoot":"","sources":["../../../../../../dev/core/src/FlowGraph/Blocks/Data/flowGraphTernaryOperationBlock.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,6BAA6B,EAAE,MAAM,iCAAiC,CAAC;AAChF;;;GAGG;AACH,MAAM,OAAO,8BAAoD,SAAQ,6BAAsC;IAc3G,YACI,MAAoB,EACpB,MAAoB,EACpB,MAAoB,EACpB,cAAiC,EACzB,UAA4C,EAC5C,UAAkB,EAC1B,MAAqC;QAErC,KAAK,CAAC,cAAc,EAAE,MAAM,CAAC,CAAC;QAJtB,eAAU,GAAV,UAAU,CAAkC;QAC5C,eAAU,GAAV,UAAU,CAAQ;QAI1B,IAAI,CAAC,CAAC,GAAG,IAAI,CAAC,iBAAiB,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC;QAC7C,IAAI,CAAC,CAAC,GAAG,IAAI,CAAC,iBAAiB,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC;QAC7C,IAAI,CAAC,CAAC,GAAG,IAAI,CAAC,iBAAiB,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC;IACjD,CAAC;IAED;;;;OAIG;IACa,YAAY,CAAC,OAAyB;QAClD,OAAO,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;IACzG,CAAC;IAED;;;OAGG;IACa,YAAY;QACxB,OAAO,IAAI,CAAC,UAAU,CAAC;IAC3B,CAAC;CACJ","sourcesContent":["import type { FlowGraphDataConnection } from \"../../flowGraphDataConnection\";\r\nimport type { RichType } from \"../../flowGraphRichTypes\";\r\nimport type { FlowGraphContext } from \"../../flowGraphContext\";\r\nimport type { IFlowGraphBlockConfiguration } from \"../../flowGraphBlock\";\r\nimport { FlowGraphCachedOperationBlock } from \"./flowGraphCachedOperationBlock\";\r\n/**\r\n * @
|
|
1
|
+
{"version":3,"file":"flowGraphTernaryOperationBlock.js","sourceRoot":"","sources":["../../../../../../dev/core/src/FlowGraph/Blocks/Data/flowGraphTernaryOperationBlock.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,6BAA6B,EAAE,MAAM,iCAAiC,CAAC;AAChF;;;GAGG;AACH,MAAM,OAAO,8BAAoD,SAAQ,6BAAsC;IAc3G,YACI,MAAoB,EACpB,MAAoB,EACpB,MAAoB,EACpB,cAAiC,EACzB,UAA4C,EAC5C,UAAkB,EAC1B,MAAqC;QAErC,KAAK,CAAC,cAAc,EAAE,MAAM,CAAC,CAAC;QAJtB,eAAU,GAAV,UAAU,CAAkC;QAC5C,eAAU,GAAV,UAAU,CAAQ;QAI1B,IAAI,CAAC,CAAC,GAAG,IAAI,CAAC,iBAAiB,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC;QAC7C,IAAI,CAAC,CAAC,GAAG,IAAI,CAAC,iBAAiB,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC;QAC7C,IAAI,CAAC,CAAC,GAAG,IAAI,CAAC,iBAAiB,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC;IACjD,CAAC;IAED;;;;OAIG;IACa,YAAY,CAAC,OAAyB;QAClD,OAAO,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;IACzG,CAAC;IAED;;;OAGG;IACa,YAAY;QACxB,OAAO,IAAI,CAAC,UAAU,CAAC;IAC3B,CAAC;CACJ","sourcesContent":["import type { FlowGraphDataConnection } from \"../../flowGraphDataConnection\";\r\nimport type { RichType } from \"../../flowGraphRichTypes\";\r\nimport type { FlowGraphContext } from \"../../flowGraphContext\";\r\nimport type { IFlowGraphBlockConfiguration } from \"../../flowGraphBlock\";\r\nimport { FlowGraphCachedOperationBlock } from \"./flowGraphCachedOperationBlock\";\r\n/**\r\n * @internal\r\n * The base block for all ternary operation blocks.\r\n */\r\nexport class FlowGraphTernaryOperationBlock<T1, T2, T3, ResultT> extends FlowGraphCachedOperationBlock<ResultT> {\r\n /**\r\n * First input of this block\r\n */\r\n a: FlowGraphDataConnection<T1>;\r\n /**\r\n * Second input of this block\r\n */\r\n b: FlowGraphDataConnection<T2>;\r\n /**\r\n * Third input of this block\r\n */\r\n c: FlowGraphDataConnection<T3>;\r\n\r\n constructor(\r\n t1Type: RichType<T1>,\r\n t2Type: RichType<T2>,\r\n t3Type: RichType<T3>,\r\n resultRichType: RichType<ResultT>,\r\n private _operation: (a: T1, b: T2, c: T3) => ResultT,\r\n private _className: string,\r\n config?: IFlowGraphBlockConfiguration\r\n ) {\r\n super(resultRichType, config);\r\n this.a = this.registerDataInput(\"a\", t1Type);\r\n this.b = this.registerDataInput(\"b\", t2Type);\r\n this.c = this.registerDataInput(\"c\", t3Type);\r\n }\r\n\r\n /**\r\n * the operation performed by this block\r\n * @param context the graph context\r\n * @returns the result of the operation\r\n */\r\n public override _doOperation(context: FlowGraphContext): ResultT {\r\n return this._operation(this.a.getValue(context), this.b.getValue(context), this.c.getValue(context));\r\n }\r\n\r\n /**\r\n * Gets the class name of this block\r\n * @returns the class name\r\n */\r\n public override getClassName(): string {\r\n return this._className;\r\n }\r\n}\r\n"]}
|
|
@@ -5,10 +5,9 @@ import { Vector3 } from "../../../Maths/math.vector";
|
|
|
5
5
|
import type { TransformNode } from "../../../Meshes/transformNode";
|
|
6
6
|
import type { IFlowGraphBlockConfiguration } from "../../flowGraphBlock";
|
|
7
7
|
/**
|
|
8
|
-
* @experimental
|
|
9
8
|
* This blocks transforms a vector from one coordinate system to another.
|
|
10
9
|
*/
|
|
11
|
-
export declare class
|
|
10
|
+
export declare class FlowGraphTransformCoordinatesSystemBlock extends FlowGraphBlock {
|
|
12
11
|
/**
|
|
13
12
|
* Input connection: The source coordinate system.
|
|
14
13
|
*/
|
|
@@ -3,10 +3,9 @@ import { RichTypeAny, RichTypeVector3 } from "../../flowGraphRichTypes.js";
|
|
|
3
3
|
import { TmpVectors, Vector3 } from "../../../Maths/math.vector.js";
|
|
4
4
|
import { RegisterClass } from "../../../Misc/typeStore.js";
|
|
5
5
|
/**
|
|
6
|
-
* @experimental
|
|
7
6
|
* This blocks transforms a vector from one coordinate system to another.
|
|
8
7
|
*/
|
|
9
|
-
export class
|
|
8
|
+
export class FlowGraphTransformCoordinatesSystemBlock extends FlowGraphBlock {
|
|
10
9
|
/**
|
|
11
10
|
* Creates a new FlowGraphCoordinateTransformBlock
|
|
12
11
|
* @param config optional configuration for this block
|
|
@@ -40,8 +39,8 @@ export class FlowGraphCoordinateTransformBlock extends FlowGraphBlock {
|
|
|
40
39
|
* @returns the class name
|
|
41
40
|
*/
|
|
42
41
|
getClassName() {
|
|
43
|
-
return "
|
|
42
|
+
return "FlowGraphTransformCoordinatesSystemBlock" /* FlowGraphBlockNames.TransformCoordinatesSystem */;
|
|
44
43
|
}
|
|
45
44
|
}
|
|
46
|
-
RegisterClass("
|
|
47
|
-
//# sourceMappingURL=
|
|
45
|
+
RegisterClass("FlowGraphTransformCoordinatesSystemBlock" /* FlowGraphBlockNames.TransformCoordinatesSystem */, FlowGraphTransformCoordinatesSystemBlock);
|
|
46
|
+
//# sourceMappingURL=flowGraphTransformCoordinatesSystemBlock.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"flowGraphTransformCoordinatesSystemBlock.js","sourceRoot":"","sources":["../../../../../../dev/core/src/FlowGraph/Blocks/Data/flowGraphTransformCoordinatesSystemBlock.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAGtD,OAAO,EAAE,WAAW,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AACxE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAC;AAGjE,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAGxD;;GAEG;AACH,MAAM,OAAO,wCAAyC,SAAQ,cAAc;IAkBxE;;;OAGG;IACH,YAAY,MAAqC;QAC7C,KAAK,CAAC,MAAM,CAAC,CAAC;QAEd,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,iBAAiB,CAAC,cAAc,EAAE,WAAW,CAAC,CAAC;QACxE,IAAI,CAAC,iBAAiB,GAAG,IAAI,CAAC,iBAAiB,CAAC,mBAAmB,EAAE,WAAW,CAAC,CAAC;QAClF,IAAI,CAAC,gBAAgB,GAAG,IAAI,CAAC,iBAAiB,CAAC,kBAAkB,EAAE,eAAe,CAAC,CAAC;QACpF,IAAI,CAAC,iBAAiB,GAAG,IAAI,CAAC,kBAAkB,CAAC,mBAAmB,EAAE,eAAe,CAAC,CAAC;IAC3F,CAAC;IAEe,cAAc,CAAC,QAA0B;QACrD,MAAM,iBAAiB,GAAG,IAAI,CAAC,YAAY,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;QAC/D,MAAM,sBAAsB,GAAG,IAAI,CAAC,iBAAiB,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;QACzE,MAAM,qBAAqB,GAAG,IAAI,CAAC,gBAAgB,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;QAEvE,qDAAqD;QACrD,MAAM,WAAW,GAAG,iBAAiB,CAAC,cAAc,EAAE,CAAC;QACvD,0DAA0D;QAC1D,MAAM,gBAAgB,GAAG,sBAAsB,CAAC,cAAc,EAAE,CAAC;QACjE,MAAM,uBAAuB,GAAG,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,gBAAgB,CAAC,CAAC;QAChF,0DAA0D;QAC1D,uBAAuB,CAAC,MAAM,EAAE,CAAC;QAEjC,MAAM,mBAAmB,GAAG,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;QACjD,0EAA0E;QAC1E,uBAAuB,CAAC,aAAa,CAAC,WAAW,EAAE,mBAAmB,CAAC,CAAC;QACxE,MAAM,sBAAsB,GAAG,IAAI,CAAC,iBAAiB,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;QAEzE,OAAO,CAAC,yBAAyB,CAAC,qBAAqB,EAAE,mBAAmB,EAAE,sBAAsB,CAAC,CAAC;IAC1G,CAAC;IAED;;;OAGG;IACa,YAAY;QACxB,uGAAsD;IAC1D,CAAC;CACJ;AACD,aAAa,kGAAiD,wCAAwC,CAAC,CAAC","sourcesContent":["import { FlowGraphBlock } from \"../../flowGraphBlock\";\r\nimport type { FlowGraphContext } from \"../../flowGraphContext\";\r\nimport type { FlowGraphDataConnection } from \"../../flowGraphDataConnection\";\r\nimport { RichTypeAny, RichTypeVector3 } from \"../../flowGraphRichTypes\";\r\nimport { TmpVectors, Vector3 } from \"../../../Maths/math.vector\";\r\nimport type { TransformNode } from \"../../../Meshes/transformNode\";\r\nimport type { IFlowGraphBlockConfiguration } from \"../../flowGraphBlock\";\r\nimport { RegisterClass } from \"../../../Misc/typeStore\";\r\nimport { FlowGraphBlockNames } from \"../flowGraphBlockNames\";\r\n\r\n/**\r\n * This blocks transforms a vector from one coordinate system to another.\r\n */\r\nexport class FlowGraphTransformCoordinatesSystemBlock extends FlowGraphBlock {\r\n /**\r\n * Input connection: The source coordinate system.\r\n */\r\n public readonly sourceSystem: FlowGraphDataConnection<TransformNode>;\r\n /**\r\n * Input connection: The destination coordinate system.\r\n */\r\n public readonly destinationSystem: FlowGraphDataConnection<TransformNode>;\r\n /**\r\n * Input connection: The coordinates to transform.\r\n */\r\n public readonly inputCoordinates: FlowGraphDataConnection<Vector3>;\r\n /**\r\n * Output connection: The transformed coordinates.\r\n */\r\n public readonly outputCoordinates: FlowGraphDataConnection<Vector3>;\r\n\r\n /**\r\n * Creates a new FlowGraphCoordinateTransformBlock\r\n * @param config optional configuration for this block\r\n */\r\n constructor(config?: IFlowGraphBlockConfiguration) {\r\n super(config);\r\n\r\n this.sourceSystem = this.registerDataInput(\"sourceSystem\", RichTypeAny);\r\n this.destinationSystem = this.registerDataInput(\"destinationSystem\", RichTypeAny);\r\n this.inputCoordinates = this.registerDataInput(\"inputCoordinates\", RichTypeVector3);\r\n this.outputCoordinates = this.registerDataOutput(\"outputCoordinates\", RichTypeVector3);\r\n }\r\n\r\n public override _updateOutputs(_context: FlowGraphContext): void {\r\n const sourceSystemValue = this.sourceSystem.getValue(_context);\r\n const destinationSystemValue = this.destinationSystem.getValue(_context);\r\n const inputCoordinatesValue = this.inputCoordinates.getValue(_context);\r\n\r\n // takes coordinates from source space to world space\r\n const sourceWorld = sourceSystemValue.getWorldMatrix();\r\n // takes coordinates from destination space to world space\r\n const destinationWorld = destinationSystemValue.getWorldMatrix();\r\n const destinationWorldInverse = TmpVectors.Matrix[0].copyFrom(destinationWorld);\r\n // takes coordinates from world space to destination space\r\n destinationWorldInverse.invert();\r\n\r\n const sourceToDestination = TmpVectors.Matrix[1];\r\n // takes coordinates from source space to world space to destination space\r\n destinationWorldInverse.multiplyToRef(sourceWorld, sourceToDestination);\r\n const outputCoordinatesValue = this.outputCoordinates.getValue(_context);\r\n\r\n Vector3.TransformCoordinatesToRef(inputCoordinatesValue, sourceToDestination, outputCoordinatesValue);\r\n }\r\n\r\n /**\r\n * Gets the class name of this block\r\n * @returns the class name\r\n */\r\n public override getClassName(): string {\r\n return FlowGraphBlockNames.TransformCoordinatesSystem;\r\n }\r\n}\r\nRegisterClass(FlowGraphBlockNames.TransformCoordinatesSystem, FlowGraphTransformCoordinatesSystemBlock);\r\n"]}
|
|
@@ -4,7 +4,7 @@ import type { RichType } from "../../flowGraphRichTypes";
|
|
|
4
4
|
import type { FlowGraphContext } from "../../flowGraphContext";
|
|
5
5
|
import { FlowGraphCachedOperationBlock } from "./flowGraphCachedOperationBlock";
|
|
6
6
|
/**
|
|
7
|
-
* @
|
|
7
|
+
* @internal
|
|
8
8
|
* The base block for all unary operation blocks. Receives an input of type InputT, and outputs a value of type ResultT.
|
|
9
9
|
*/
|
|
10
10
|
export declare class FlowGraphUnaryOperationBlock<InputT, ResultT> extends FlowGraphCachedOperationBlock<ResultT> {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FlowGraphCachedOperationBlock } from "./flowGraphCachedOperationBlock.js";
|
|
2
2
|
/**
|
|
3
|
-
* @
|
|
3
|
+
* @internal
|
|
4
4
|
* The base block for all unary operation blocks. Receives an input of type InputT, and outputs a value of type ResultT.
|
|
5
5
|
*/
|
|
6
6
|
export class FlowGraphUnaryOperationBlock extends FlowGraphCachedOperationBlock {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flowGraphUnaryOperationBlock.js","sourceRoot":"","sources":["../../../../../../dev/core/src/FlowGraph/Blocks/Data/flowGraphUnaryOperationBlock.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,6BAA6B,EAAE,MAAM,iCAAiC,CAAC;AAEhF;;;GAGG;AACH,MAAM,OAAO,4BAA8C,SAAQ,6BAAsC;IAMrG,YACI,aAA+B,EAC/B,cAAiC,EACzB,UAAsC,EACtC,UAAkB,EAC1B,MAAqC;QAErC,KAAK,CAAC,cAAc,EAAE,MAAM,CAAC,CAAC;QAJtB,eAAU,GAAV,UAAU,CAA4B;QACtC,eAAU,GAAV,UAAU,CAAQ;QAI1B,IAAI,CAAC,CAAC,GAAG,IAAI,CAAC,iBAAiB,CAAC,GAAG,EAAE,aAAa,CAAC,CAAC;IACxD,CAAC;IAED;;;;OAIG;IACa,YAAY,CAAC,OAAyB;QAClD,OAAO,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;IACrD,CAAC;IAED;;;OAGG;IACa,YAAY;QACxB,OAAO,IAAI,CAAC,UAAU,CAAC;IAC3B,CAAC;CACJ","sourcesContent":["import type { FlowGraphDataConnection } from \"../../flowGraphDataConnection\";\r\nimport type { IFlowGraphBlockConfiguration } from \"../../flowGraphBlock\";\r\nimport type { RichType } from \"../../flowGraphRichTypes\";\r\nimport type { FlowGraphContext } from \"../../flowGraphContext\";\r\nimport { FlowGraphCachedOperationBlock } from \"./flowGraphCachedOperationBlock\";\r\n\r\n/**\r\n * @
|
|
1
|
+
{"version":3,"file":"flowGraphUnaryOperationBlock.js","sourceRoot":"","sources":["../../../../../../dev/core/src/FlowGraph/Blocks/Data/flowGraphUnaryOperationBlock.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,6BAA6B,EAAE,MAAM,iCAAiC,CAAC;AAEhF;;;GAGG;AACH,MAAM,OAAO,4BAA8C,SAAQ,6BAAsC;IAMrG,YACI,aAA+B,EAC/B,cAAiC,EACzB,UAAsC,EACtC,UAAkB,EAC1B,MAAqC;QAErC,KAAK,CAAC,cAAc,EAAE,MAAM,CAAC,CAAC;QAJtB,eAAU,GAAV,UAAU,CAA4B;QACtC,eAAU,GAAV,UAAU,CAAQ;QAI1B,IAAI,CAAC,CAAC,GAAG,IAAI,CAAC,iBAAiB,CAAC,GAAG,EAAE,aAAa,CAAC,CAAC;IACxD,CAAC;IAED;;;;OAIG;IACa,YAAY,CAAC,OAAyB;QAClD,OAAO,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;IACrD,CAAC;IAED;;;OAGG;IACa,YAAY;QACxB,OAAO,IAAI,CAAC,UAAU,CAAC;IAC3B,CAAC;CACJ","sourcesContent":["import type { FlowGraphDataConnection } from \"../../flowGraphDataConnection\";\r\nimport type { IFlowGraphBlockConfiguration } from \"../../flowGraphBlock\";\r\nimport type { RichType } from \"../../flowGraphRichTypes\";\r\nimport type { FlowGraphContext } from \"../../flowGraphContext\";\r\nimport { FlowGraphCachedOperationBlock } from \"./flowGraphCachedOperationBlock\";\r\n\r\n/**\r\n * @internal\r\n * The base block for all unary operation blocks. Receives an input of type InputT, and outputs a value of type ResultT.\r\n */\r\nexport class FlowGraphUnaryOperationBlock<InputT, ResultT> extends FlowGraphCachedOperationBlock<ResultT> {\r\n /**\r\n * the input of this block\r\n */\r\n a: FlowGraphDataConnection<InputT>;\r\n\r\n constructor(\r\n inputRichType: RichType<InputT>,\r\n resultRichType: RichType<ResultT>,\r\n private _operation: (input: InputT) => ResultT,\r\n private _className: string,\r\n config?: IFlowGraphBlockConfiguration\r\n ) {\r\n super(resultRichType, config);\r\n this.a = this.registerDataInput(\"a\", inputRichType);\r\n }\r\n\r\n /**\r\n * the operation performed by this block\r\n * @param context the graph context\r\n * @returns the result of the operation\r\n */\r\n public override _doOperation(context: FlowGraphContext): ResultT {\r\n return this._operation(this.a.getValue(context));\r\n }\r\n\r\n /**\r\n * Gets the class name of this block\r\n * @returns the class name\r\n */\r\n public override getClassName(): string {\r\n return this._className;\r\n }\r\n}\r\n"]}
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
export * from "./flowGraphConditionalDataBlock";
|
|
2
2
|
export * from "./flowGraphGetVariableBlock";
|
|
3
|
-
export * from "
|
|
4
|
-
export * from "./
|
|
3
|
+
export * from "../Execution/flowGraphSetVariableBlock";
|
|
4
|
+
export * from "./flowGraphTransformCoordinatesSystemBlock";
|
|
5
5
|
export * from "./flowGraphGetPropertyBlock";
|
|
6
|
-
export * from "
|
|
6
|
+
export * from "../Execution/flowGraphSetPropertyBlock";
|
|
7
|
+
export * from "./flowGraphConstantBlock";
|
|
8
|
+
export * from "./flowGraphGetAssetBlock";
|
|
7
9
|
export * from "./Math/index";
|
|
10
|
+
export * from "./Transformers/index";
|
|
11
|
+
export * from "./Utils/index";
|
|
@@ -1,10 +1,15 @@
|
|
|
1
1
|
export * from "./flowGraphConditionalDataBlock.js";
|
|
2
2
|
export * from "./flowGraphGetVariableBlock.js";
|
|
3
|
-
export * from "
|
|
4
|
-
export * from "./
|
|
3
|
+
export * from "../Execution/flowGraphSetVariableBlock.js";
|
|
4
|
+
export * from "./flowGraphTransformCoordinatesSystemBlock.js";
|
|
5
5
|
export * from "./flowGraphGetPropertyBlock.js";
|
|
6
|
-
|
|
7
|
-
export * from "./
|
|
6
|
+
export * from "../Execution/flowGraphSetPropertyBlock.js";
|
|
7
|
+
export * from "./flowGraphConstantBlock.js";
|
|
8
|
+
export * from "./flowGraphGetAssetBlock.js";
|
|
8
9
|
// eslint-disable-next-line import/no-internal-modules
|
|
9
10
|
export * from "./Math/index.js";
|
|
11
|
+
// eslint-disable-next-line import/no-internal-modules
|
|
12
|
+
export * from "./Transformers/index.js";
|
|
13
|
+
// eslint-disable-next-line import/no-internal-modules
|
|
14
|
+
export * from "./Utils/index.js";
|
|
10
15
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../dev/core/src/FlowGraph/Blocks/Data/index.ts"],"names":[],"mappings":"AAAA,cAAc,iCAAiC,CAAC;AAChD,cAAc,6BAA6B,CAAC;AAC5C,cAAc,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../dev/core/src/FlowGraph/Blocks/Data/index.ts"],"names":[],"mappings":"AAAA,cAAc,iCAAiC,CAAC;AAChD,cAAc,6BAA6B,CAAC;AAC5C,cAAc,wCAAwC,CAAC;AACvD,cAAc,4CAA4C,CAAC;AAC3D,cAAc,6BAA6B,CAAC;AAC5C,cAAc,wCAAwC,CAAC;AACvD,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,sDAAsD;AACtD,cAAc,cAAc,CAAC;AAC7B,sDAAsD;AACtD,cAAc,sBAAsB,CAAC;AACrC,sDAAsD;AACtD,cAAc,eAAe,CAAC","sourcesContent":["export * from \"./flowGraphConditionalDataBlock\";\r\nexport * from \"./flowGraphGetVariableBlock\";\r\nexport * from \"../Execution/flowGraphSetVariableBlock\";\r\nexport * from \"./flowGraphTransformCoordinatesSystemBlock\";\r\nexport * from \"./flowGraphGetPropertyBlock\";\r\nexport * from \"../Execution/flowGraphSetPropertyBlock\";\r\nexport * from \"./flowGraphConstantBlock\";\r\nexport * from \"./flowGraphGetAssetBlock\";\r\n// eslint-disable-next-line import/no-internal-modules\r\nexport * from \"./Math/index\";\r\n// eslint-disable-next-line import/no-internal-modules\r\nexport * from \"./Transformers/index\";\r\n// eslint-disable-next-line import/no-internal-modules\r\nexport * from \"./Utils/index\";\r\n"]}
|