@plastic-software/three 0.178.0 → 0.180.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/build/three.cjs +950 -230
- package/build/three.core.js +754 -138
- package/build/three.core.min.js +1 -1
- package/build/three.module.js +197 -96
- package/build/three.module.min.js +1 -1
- package/build/three.tsl.js +99 -25
- package/build/three.tsl.min.js +1 -1
- package/build/three.webgpu.js +4586 -1499
- package/build/three.webgpu.min.js +1 -1
- package/build/three.webgpu.nodes.js +4544 -1499
- package/build/three.webgpu.nodes.min.js +1 -1
- package/examples/jsm/Addons.js +2 -3
- package/examples/jsm/capabilities/WebGPU.js +1 -1
- package/examples/jsm/controls/ArcballControls.js +7 -7
- package/examples/jsm/controls/DragControls.js +6 -56
- package/examples/jsm/controls/FirstPersonControls.js +2 -2
- package/examples/jsm/controls/PointerLockControls.js +0 -8
- package/examples/jsm/csm/CSMShadowNode.js +4 -4
- package/examples/jsm/environments/RoomEnvironment.js +8 -3
- package/examples/jsm/exporters/GLTFExporter.js +30 -22
- package/examples/jsm/exporters/KTX2Exporter.js +4 -2
- package/examples/jsm/exporters/PLYExporter.js +1 -1
- package/examples/jsm/exporters/USDZExporter.js +676 -299
- package/examples/jsm/geometries/RoundedBoxGeometry.js +47 -8
- package/examples/jsm/interactive/HTMLMesh.js +5 -3
- package/examples/jsm/libs/ktx-parse.module.js +1 -1
- package/examples/jsm/libs/meshopt_decoder.module.js +75 -58
- package/examples/jsm/lights/LightProbeGenerator.js +14 -3
- package/examples/jsm/lines/Line2.js +3 -3
- package/examples/jsm/lines/LineGeometry.js +1 -1
- package/examples/jsm/lines/LineSegments2.js +2 -2
- package/examples/jsm/lines/Wireframe.js +2 -2
- package/examples/jsm/lines/WireframeGeometry2.js +1 -1
- package/examples/jsm/lines/webgpu/LineSegments2.js +1 -1
- package/examples/jsm/lines/webgpu/Wireframe.js +1 -1
- package/examples/jsm/loaders/ColladaLoader.js +1 -1
- package/examples/jsm/loaders/EXRLoader.js +210 -22
- package/examples/jsm/loaders/FBXLoader.js +1 -1
- package/examples/jsm/loaders/GLTFLoader.js +9 -5
- package/examples/jsm/loaders/HDRCubeTextureLoader.js +5 -5
- package/examples/jsm/loaders/HDRLoader.js +486 -0
- package/examples/jsm/loaders/KTX2Loader.js +112 -32
- package/examples/jsm/loaders/MaterialXLoader.js +212 -30
- package/examples/jsm/loaders/RGBELoader.js +7 -473
- package/examples/jsm/loaders/TTFLoader.js +13 -1
- package/examples/jsm/loaders/USDLoader.js +219 -0
- package/examples/jsm/loaders/USDZLoader.js +4 -892
- package/examples/jsm/loaders/UltraHDRLoader.js +1 -1
- package/examples/jsm/loaders/lwo/IFFParser.js +1 -1
- package/examples/jsm/loaders/usd/USDAParser.js +741 -0
- package/examples/jsm/loaders/usd/USDCParser.js +17 -0
- package/examples/jsm/materials/WoodNodeMaterial.js +533 -0
- package/examples/jsm/math/ColorSpaces.js +19 -1
- package/examples/jsm/math/ConvexHull.js +2 -2
- package/examples/jsm/math/Lut.js +2 -2
- package/examples/jsm/misc/MD2CharacterComplex.js +1 -1
- package/examples/jsm/misc/ProgressiveLightMap.js +1 -1
- package/examples/jsm/misc/Volume.js +1 -1
- package/examples/jsm/objects/LensflareMesh.js +3 -3
- package/examples/jsm/objects/SkyMesh.js +2 -2
- package/examples/jsm/physics/RapierPhysics.js +14 -5
- package/examples/jsm/postprocessing/GTAOPass.js +10 -9
- package/examples/jsm/postprocessing/OutlinePass.js +17 -17
- package/examples/jsm/postprocessing/SSAOPass.js +10 -9
- package/examples/jsm/postprocessing/SSRPass.js +37 -8
- package/examples/jsm/shaders/UnpackDepthRGBAShader.js +11 -2
- package/examples/jsm/transpiler/GLSLDecoder.js +23 -20
- package/examples/jsm/transpiler/TSLEncoder.js +2 -10
- package/examples/jsm/transpiler/WGSLEncoder.js +24 -0
- package/examples/jsm/tsl/display/AnamorphicNode.js +27 -4
- package/examples/jsm/tsl/display/BloomNode.js +7 -6
- package/examples/jsm/tsl/display/ChromaticAberrationNode.js +2 -1
- package/examples/jsm/tsl/display/DepthOfFieldNode.js +439 -90
- package/examples/jsm/tsl/display/GTAONode.js +8 -0
- package/examples/jsm/tsl/display/GaussianBlurNode.js +51 -41
- package/examples/jsm/tsl/display/OutlineNode.js +2 -2
- package/examples/jsm/tsl/display/SSRNode.js +180 -65
- package/examples/jsm/tsl/display/{TRAAPassNode.js → TRAANode.js} +181 -172
- package/examples/jsm/tsl/display/boxBlur.js +64 -0
- package/examples/jsm/tsl/display/hashBlur.js +15 -18
- package/examples/jsm/tsl/lighting/TiledLightsNode.js +1 -1
- package/examples/jsm/utils/BufferGeometryUtils.js +1 -1
- package/examples/jsm/utils/ShadowMapViewerGPU.js +12 -5
- package/examples/jsm/webxr/OculusHandModel.js +1 -1
- package/package.json +1 -1
- package/src/Three.Core.js +2 -0
- package/src/Three.TSL.js +98 -24
- package/src/animation/AnimationClip.js +17 -2
- package/src/animation/KeyframeTrack.js +1 -1
- package/src/animation/tracks/BooleanKeyframeTrack.js +1 -1
- package/src/animation/tracks/StringKeyframeTrack.js +1 -1
- package/src/cameras/Camera.js +14 -0
- package/src/cameras/OrthographicCamera.js +1 -1
- package/src/cameras/PerspectiveCamera.js +1 -1
- package/src/constants.js +11 -3
- package/src/core/BufferGeometry.js +2 -2
- package/{examples/jsm/misc → src/core}/Timer.js +4 -42
- package/src/extras/PMREMGenerator.js +11 -0
- package/src/extras/TextureUtils.js +2 -1
- package/src/extras/lib/earcut.js +1 -1
- package/src/helpers/CameraHelper.js +41 -11
- package/src/helpers/SkeletonHelper.js +35 -6
- package/src/lights/LightShadow.js +21 -8
- package/src/lights/PointLightShadow.js +1 -1
- package/src/lights/webgpu/ProjectorLight.js +1 -1
- package/src/loaders/FileLoader.js +25 -2
- package/src/loaders/ImageBitmapLoader.js +23 -0
- package/src/loaders/Loader.js +14 -0
- package/src/loaders/LoadingManager.js +23 -0
- package/src/materials/Material.js +12 -0
- package/src/materials/MeshBasicMaterial.js +1 -1
- package/src/materials/MeshDistanceMaterial.js +1 -1
- package/src/materials/nodes/Line2NodeMaterial.js +0 -8
- package/src/materials/nodes/NodeMaterial.js +1 -1
- package/src/materials/nodes/PointsNodeMaterial.js +86 -28
- package/src/materials/nodes/SpriteNodeMaterial.js +3 -15
- package/src/materials/nodes/manager/NodeMaterialObserver.js +87 -2
- package/src/math/ColorManagement.js +7 -1
- package/src/math/Frustum.js +19 -8
- package/src/math/FrustumArray.js +10 -5
- package/src/math/Line3.js +129 -2
- package/src/math/Matrix4.js +48 -27
- package/src/math/Spherical.js +2 -2
- package/src/nodes/Nodes.js +4 -0
- package/src/nodes/TSL.js +4 -0
- package/src/nodes/accessors/BufferNode.js +1 -1
- package/src/nodes/accessors/Camera.js +142 -16
- package/src/nodes/accessors/ClippingNode.js +6 -5
- package/src/nodes/accessors/CubeTextureNode.js +2 -2
- package/src/nodes/accessors/InstanceNode.js +3 -1
- package/src/nodes/accessors/Normal.js +11 -11
- package/src/nodes/accessors/Object3DNode.js +1 -1
- package/src/nodes/accessors/ReferenceBaseNode.js +1 -1
- package/src/nodes/accessors/ReferenceNode.js +19 -4
- package/src/nodes/accessors/SceneNode.js +1 -1
- package/src/nodes/accessors/StorageTextureNode.js +1 -1
- package/src/nodes/accessors/Texture3DNode.js +13 -0
- package/src/nodes/accessors/TextureNode.js +83 -19
- package/src/nodes/code/FunctionCallNode.js +19 -0
- package/src/nodes/code/FunctionNode.js +23 -0
- package/src/nodes/core/ArrayNode.js +12 -0
- package/src/nodes/core/AssignNode.js +6 -2
- package/src/nodes/core/ContextNode.js +44 -1
- package/src/nodes/core/Node.js +30 -22
- package/src/nodes/core/NodeBuilder.js +71 -32
- package/src/nodes/core/NodeFrame.js +1 -1
- package/src/nodes/core/NodeUniform.js +1 -1
- package/src/nodes/core/NodeUtils.js +5 -3
- package/src/nodes/core/StackNode.js +71 -4
- package/src/nodes/core/StructNode.js +5 -5
- package/src/nodes/core/StructTypeNode.js +1 -0
- package/src/nodes/core/SubBuildNode.js +2 -2
- package/src/nodes/core/UniformNode.js +79 -14
- package/src/nodes/core/VarNode.js +83 -15
- package/src/nodes/display/FrontFacingNode.js +4 -8
- package/src/nodes/display/PassNode.js +148 -2
- package/src/nodes/display/ScreenNode.js +42 -13
- package/src/nodes/display/ViewportDepthTextureNode.js +16 -4
- package/src/nodes/display/ViewportSharedTextureNode.js +12 -0
- package/src/nodes/display/ViewportTextureNode.js +94 -4
- package/src/nodes/functions/PhysicalLightingModel.js +2 -2
- package/src/nodes/gpgpu/AtomicFunctionNode.js +1 -1
- package/src/nodes/gpgpu/ComputeNode.js +67 -23
- package/src/nodes/gpgpu/SubgroupFunctionNode.js +430 -0
- package/src/nodes/gpgpu/WorkgroupInfoNode.js +28 -3
- package/src/nodes/lighting/LightsNode.js +1 -1
- package/src/nodes/lighting/ProjectorLightNode.js +19 -6
- package/src/nodes/lighting/ShadowFilterNode.js +1 -1
- package/src/nodes/materialx/MaterialXNodes.js +131 -2
- package/src/nodes/materialx/lib/mx_noise.js +165 -1
- package/src/nodes/math/BitcastNode.js +156 -0
- package/src/nodes/math/ConditionalNode.js +19 -3
- package/src/nodes/math/MathNode.js +72 -60
- package/src/nodes/math/OperatorNode.js +26 -25
- package/src/nodes/tsl/TSLCore.js +477 -142
- package/src/nodes/utils/DebugNode.js +1 -1
- package/src/nodes/utils/EventNode.js +83 -0
- package/src/nodes/utils/JoinNode.js +3 -1
- package/src/nodes/utils/MemberNode.js +58 -7
- package/src/nodes/utils/RTTNode.js +10 -1
- package/src/nodes/utils/ReflectorNode.js +51 -7
- package/src/nodes/utils/SampleNode.js +12 -2
- package/src/nodes/utils/SplitNode.js +11 -0
- package/src/nodes/utils/Timer.js +0 -47
- package/src/objects/BatchedMesh.js +6 -4
- package/src/objects/LOD.js +1 -1
- package/src/objects/Sprite.js +2 -2
- package/src/renderers/WebGLRenderer.js +21 -31
- package/src/renderers/common/Attributes.js +1 -1
- package/src/renderers/common/Backend.js +19 -1
- package/src/renderers/common/Bindings.js +21 -18
- package/src/renderers/common/ChainMap.js +1 -1
- package/src/renderers/common/Color4.js +2 -2
- package/src/renderers/common/DataMap.js +1 -1
- package/src/renderers/common/Pipelines.js +1 -1
- package/src/renderers/common/PostProcessing.js +60 -5
- package/src/renderers/common/RenderContext.js +2 -2
- package/src/renderers/common/RenderObject.js +14 -2
- package/src/renderers/common/Renderer.js +55 -32
- package/src/renderers/common/SampledTexture.js +4 -72
- package/src/renderers/common/Sampler.js +91 -0
- package/src/renderers/common/Storage3DTexture.js +21 -0
- package/src/renderers/common/StorageArrayTexture.js +21 -0
- package/src/renderers/common/StorageTexture.js +19 -0
- package/src/renderers/common/Textures.js +52 -14
- package/src/renderers/common/TimestampQueryPool.js +3 -3
- package/src/renderers/common/XRManager.js +51 -17
- package/src/renderers/common/nodes/NodeBuilderState.js +1 -1
- package/src/renderers/common/nodes/NodeLibrary.js +5 -5
- package/src/renderers/common/nodes/NodeSampledTexture.js +0 -12
- package/src/renderers/shaders/ShaderChunk/logdepthbuf_fragment.glsl.js +1 -1
- package/src/renderers/shaders/ShaderChunk/logdepthbuf_pars_fragment.glsl.js +1 -1
- package/src/renderers/shaders/ShaderChunk/logdepthbuf_pars_vertex.glsl.js +1 -1
- package/src/renderers/shaders/ShaderChunk/logdepthbuf_vertex.glsl.js +1 -1
- package/src/renderers/shaders/ShaderChunk/shadowmap_pars_fragment.glsl.js +21 -11
- package/src/renderers/shaders/ShaderLib/depth.glsl.js +11 -2
- package/src/renderers/webgl/WebGLCapabilities.js +2 -2
- package/src/renderers/webgl/WebGLMaterials.js +6 -6
- package/src/renderers/webgl/WebGLProgram.js +24 -18
- package/src/renderers/webgl/WebGLPrograms.js +4 -4
- package/src/renderers/webgl/WebGLShadowMap.js +11 -1
- package/src/renderers/webgl/WebGLTextures.js +20 -7
- package/src/renderers/webgl/WebGLUtils.js +3 -2
- package/src/renderers/webgl-fallback/WebGLBackend.js +207 -146
- package/src/renderers/webgl-fallback/nodes/GLSLNodeBuilder.js +112 -19
- package/src/renderers/webgl-fallback/utils/WebGLState.js +1 -1
- package/src/renderers/webgl-fallback/utils/WebGLTextureUtils.js +52 -3
- package/src/renderers/webgl-fallback/utils/WebGLTimestampQueryPool.js +9 -10
- package/src/renderers/webgl-fallback/utils/WebGLUtils.js +3 -2
- package/src/renderers/webgpu/WebGPUBackend.js +87 -44
- package/src/renderers/webgpu/nodes/WGSLNodeBuilder.js +169 -99
- package/src/renderers/webgpu/utils/WebGPUBindingUtils.js +35 -31
- package/src/renderers/webgpu/utils/WebGPUConstants.js +2 -2
- package/src/renderers/webgpu/utils/WebGPUPipelineUtils.js +10 -19
- package/src/renderers/webgpu/utils/WebGPUTextureUtils.js +120 -84
- package/src/renderers/webgpu/utils/WebGPUTimestampQueryPool.js +3 -3
- package/src/renderers/webgpu/utils/WebGPUUtils.js +2 -17
- package/src/renderers/webxr/WebXRDepthSensing.js +6 -10
- package/src/renderers/webxr/WebXRManager.js +86 -11
- package/src/textures/ExternalTexture.js +56 -0
- package/src/textures/FramebufferTexture.js +2 -2
- package/src/textures/Source.js +12 -2
- package/src/textures/VideoTexture.js +27 -2
- package/examples/jsm/loaders/RGBMLoader.js +0 -1148
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { WebGLCoordinateSystem } from '../../constants.js';
|
|
2
2
|
import TempNode from '../core/TempNode.js';
|
|
3
|
-
import { addMethodChaining, Fn, int,
|
|
3
|
+
import { addMethodChaining, Fn, int, nodeProxyIntent } from '../tsl/TSLCore.js';
|
|
4
4
|
|
|
5
5
|
const _vectorOperators = {
|
|
6
6
|
'==': 'equal',
|
|
@@ -103,9 +103,10 @@ class OperatorNode extends TempNode {
|
|
|
103
103
|
* and the input node types.
|
|
104
104
|
*
|
|
105
105
|
* @param {NodeBuilder} builder - The current node builder.
|
|
106
|
+
* @param {?string} [output=null] - The output type.
|
|
106
107
|
* @return {string} The node type.
|
|
107
108
|
*/
|
|
108
|
-
getNodeType( builder ) {
|
|
109
|
+
getNodeType( builder, output = null ) {
|
|
109
110
|
|
|
110
111
|
const op = this.op;
|
|
111
112
|
|
|
@@ -117,7 +118,7 @@ class OperatorNode extends TempNode {
|
|
|
117
118
|
|
|
118
119
|
if ( typeA === 'void' || typeB === 'void' ) {
|
|
119
120
|
|
|
120
|
-
return 'void';
|
|
121
|
+
return output || 'void';
|
|
121
122
|
|
|
122
123
|
} else if ( op === '%' ) {
|
|
123
124
|
|
|
@@ -193,7 +194,7 @@ class OperatorNode extends TempNode {
|
|
|
193
194
|
|
|
194
195
|
const { aNode, bNode } = this;
|
|
195
196
|
|
|
196
|
-
const type = this.getNodeType( builder );
|
|
197
|
+
const type = this.getNodeType( builder, output );
|
|
197
198
|
|
|
198
199
|
let typeA = null;
|
|
199
200
|
let typeB = null;
|
|
@@ -419,7 +420,7 @@ export default OperatorNode;
|
|
|
419
420
|
* @param {...Node} params - Additional input parameters.
|
|
420
421
|
* @returns {OperatorNode}
|
|
421
422
|
*/
|
|
422
|
-
export const add = /*@__PURE__*/
|
|
423
|
+
export const add = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '+' ).setParameterLength( 2, Infinity ).setName( 'add' );
|
|
423
424
|
|
|
424
425
|
/**
|
|
425
426
|
* Returns the subtraction of two or more value.
|
|
@@ -431,7 +432,7 @@ export const add = /*@__PURE__*/ nodeProxy( OperatorNode, '+' ).setParameterLeng
|
|
|
431
432
|
* @param {...Node} params - Additional input parameters.
|
|
432
433
|
* @returns {OperatorNode}
|
|
433
434
|
*/
|
|
434
|
-
export const sub = /*@__PURE__*/
|
|
435
|
+
export const sub = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '-' ).setParameterLength( 2, Infinity ).setName( 'sub' );
|
|
435
436
|
|
|
436
437
|
/**
|
|
437
438
|
* Returns the multiplication of two or more value.
|
|
@@ -443,7 +444,7 @@ export const sub = /*@__PURE__*/ nodeProxy( OperatorNode, '-' ).setParameterLeng
|
|
|
443
444
|
* @param {...Node} params - Additional input parameters.
|
|
444
445
|
* @returns {OperatorNode}
|
|
445
446
|
*/
|
|
446
|
-
export const mul = /*@__PURE__*/
|
|
447
|
+
export const mul = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '*' ).setParameterLength( 2, Infinity ).setName( 'mul' );
|
|
447
448
|
|
|
448
449
|
/**
|
|
449
450
|
* Returns the division of two or more value.
|
|
@@ -455,7 +456,7 @@ export const mul = /*@__PURE__*/ nodeProxy( OperatorNode, '*' ).setParameterLeng
|
|
|
455
456
|
* @param {...Node} params - Additional input parameters.
|
|
456
457
|
* @returns {OperatorNode}
|
|
457
458
|
*/
|
|
458
|
-
export const div = /*@__PURE__*/
|
|
459
|
+
export const div = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '/' ).setParameterLength( 2, Infinity ).setName( 'div' );
|
|
459
460
|
|
|
460
461
|
/**
|
|
461
462
|
* Computes the remainder of dividing the first node by the second one.
|
|
@@ -466,7 +467,7 @@ export const div = /*@__PURE__*/ nodeProxy( OperatorNode, '/' ).setParameterLeng
|
|
|
466
467
|
* @param {Node} b - The second input.
|
|
467
468
|
* @returns {OperatorNode}
|
|
468
469
|
*/
|
|
469
|
-
export const mod = /*@__PURE__*/
|
|
470
|
+
export const mod = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '%' ).setParameterLength( 2 ).setName( 'mod' );
|
|
470
471
|
|
|
471
472
|
/**
|
|
472
473
|
* Checks if two nodes are equal.
|
|
@@ -477,7 +478,7 @@ export const mod = /*@__PURE__*/ nodeProxy( OperatorNode, '%' ).setParameterLeng
|
|
|
477
478
|
* @param {Node} b - The second input.
|
|
478
479
|
* @returns {OperatorNode}
|
|
479
480
|
*/
|
|
480
|
-
export const equal = /*@__PURE__*/
|
|
481
|
+
export const equal = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '==' ).setParameterLength( 2 ).setName( 'equal' );
|
|
481
482
|
|
|
482
483
|
/**
|
|
483
484
|
* Checks if two nodes are not equal.
|
|
@@ -488,7 +489,7 @@ export const equal = /*@__PURE__*/ nodeProxy( OperatorNode, '==' ).setParameterL
|
|
|
488
489
|
* @param {Node} b - The second input.
|
|
489
490
|
* @returns {OperatorNode}
|
|
490
491
|
*/
|
|
491
|
-
export const notEqual = /*@__PURE__*/
|
|
492
|
+
export const notEqual = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '!=' ).setParameterLength( 2 ).setName( 'notEqual' );
|
|
492
493
|
|
|
493
494
|
/**
|
|
494
495
|
* Checks if the first node is less than the second.
|
|
@@ -499,7 +500,7 @@ export const notEqual = /*@__PURE__*/ nodeProxy( OperatorNode, '!=' ).setParamet
|
|
|
499
500
|
* @param {Node} b - The second input.
|
|
500
501
|
* @returns {OperatorNode}
|
|
501
502
|
*/
|
|
502
|
-
export const lessThan = /*@__PURE__*/
|
|
503
|
+
export const lessThan = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '<' ).setParameterLength( 2 ).setName( 'lessThan' );
|
|
503
504
|
|
|
504
505
|
/**
|
|
505
506
|
* Checks if the first node is greater than the second.
|
|
@@ -510,7 +511,7 @@ export const lessThan = /*@__PURE__*/ nodeProxy( OperatorNode, '<' ).setParamete
|
|
|
510
511
|
* @param {Node} b - The second input.
|
|
511
512
|
* @returns {OperatorNode}
|
|
512
513
|
*/
|
|
513
|
-
export const greaterThan = /*@__PURE__*/
|
|
514
|
+
export const greaterThan = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '>' ).setParameterLength( 2 ).setName( 'greaterThan' );
|
|
514
515
|
|
|
515
516
|
/**
|
|
516
517
|
* Checks if the first node is less than or equal to the second.
|
|
@@ -521,7 +522,7 @@ export const greaterThan = /*@__PURE__*/ nodeProxy( OperatorNode, '>' ).setParam
|
|
|
521
522
|
* @param {Node} b - The second input.
|
|
522
523
|
* @returns {OperatorNode}
|
|
523
524
|
*/
|
|
524
|
-
export const lessThanEqual = /*@__PURE__*/
|
|
525
|
+
export const lessThanEqual = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '<=' ).setParameterLength( 2 ).setName( 'lessThanEqual' );
|
|
525
526
|
|
|
526
527
|
/**
|
|
527
528
|
* Checks if the first node is greater than or equal to the second.
|
|
@@ -532,7 +533,7 @@ export const lessThanEqual = /*@__PURE__*/ nodeProxy( OperatorNode, '<=' ).setPa
|
|
|
532
533
|
* @param {Node} b - The second input.
|
|
533
534
|
* @returns {OperatorNode}
|
|
534
535
|
*/
|
|
535
|
-
export const greaterThanEqual = /*@__PURE__*/
|
|
536
|
+
export const greaterThanEqual = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '>=' ).setParameterLength( 2 ).setName( 'greaterThanEqual' );
|
|
536
537
|
|
|
537
538
|
/**
|
|
538
539
|
* Performs a logical AND operation on multiple nodes.
|
|
@@ -542,7 +543,7 @@ export const greaterThanEqual = /*@__PURE__*/ nodeProxy( OperatorNode, '>=' ).se
|
|
|
542
543
|
* @param {...Node} nodes - The input nodes to be combined using AND.
|
|
543
544
|
* @returns {OperatorNode}
|
|
544
545
|
*/
|
|
545
|
-
export const and = /*@__PURE__*/
|
|
546
|
+
export const and = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '&&' ).setParameterLength( 2, Infinity ).setName( 'and' );
|
|
546
547
|
|
|
547
548
|
/**
|
|
548
549
|
* Performs a logical OR operation on multiple nodes.
|
|
@@ -552,7 +553,7 @@ export const and = /*@__PURE__*/ nodeProxy( OperatorNode, '&&' ).setParameterLen
|
|
|
552
553
|
* @param {...Node} nodes - The input nodes to be combined using OR.
|
|
553
554
|
* @returns {OperatorNode}
|
|
554
555
|
*/
|
|
555
|
-
export const or = /*@__PURE__*/
|
|
556
|
+
export const or = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '||' ).setParameterLength( 2, Infinity ).setName( 'or' );
|
|
556
557
|
|
|
557
558
|
/**
|
|
558
559
|
* Performs logical NOT on a node.
|
|
@@ -562,7 +563,7 @@ export const or = /*@__PURE__*/ nodeProxy( OperatorNode, '||' ).setParameterLeng
|
|
|
562
563
|
* @param {Node} value - The value.
|
|
563
564
|
* @returns {OperatorNode}
|
|
564
565
|
*/
|
|
565
|
-
export const not = /*@__PURE__*/
|
|
566
|
+
export const not = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '!' ).setParameterLength( 1 ).setName( 'not' );
|
|
566
567
|
|
|
567
568
|
/**
|
|
568
569
|
* Performs logical XOR on two nodes.
|
|
@@ -573,7 +574,7 @@ export const not = /*@__PURE__*/ nodeProxy( OperatorNode, '!' ).setParameterLeng
|
|
|
573
574
|
* @param {Node} b - The second input.
|
|
574
575
|
* @returns {OperatorNode}
|
|
575
576
|
*/
|
|
576
|
-
export const xor = /*@__PURE__*/
|
|
577
|
+
export const xor = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '^^' ).setParameterLength( 2 ).setName( 'xor' );
|
|
577
578
|
|
|
578
579
|
/**
|
|
579
580
|
* Performs bitwise AND on two nodes.
|
|
@@ -584,7 +585,7 @@ export const xor = /*@__PURE__*/ nodeProxy( OperatorNode, '^^' ).setParameterLen
|
|
|
584
585
|
* @param {Node} b - The second input.
|
|
585
586
|
* @returns {OperatorNode}
|
|
586
587
|
*/
|
|
587
|
-
export const bitAnd = /*@__PURE__*/
|
|
588
|
+
export const bitAnd = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '&' ).setParameterLength( 2 ).setName( 'bitAnd' );
|
|
588
589
|
|
|
589
590
|
/**
|
|
590
591
|
* Performs bitwise NOT on a node.
|
|
@@ -595,7 +596,7 @@ export const bitAnd = /*@__PURE__*/ nodeProxy( OperatorNode, '&' ).setParameterL
|
|
|
595
596
|
* @param {Node} b - The second input.
|
|
596
597
|
* @returns {OperatorNode}
|
|
597
598
|
*/
|
|
598
|
-
export const bitNot = /*@__PURE__*/
|
|
599
|
+
export const bitNot = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '~' ).setParameterLength( 2 ).setName( 'bitNot' );
|
|
599
600
|
|
|
600
601
|
/**
|
|
601
602
|
* Performs bitwise OR on two nodes.
|
|
@@ -606,7 +607,7 @@ export const bitNot = /*@__PURE__*/ nodeProxy( OperatorNode, '~' ).setParameterL
|
|
|
606
607
|
* @param {Node} b - The second input.
|
|
607
608
|
* @returns {OperatorNode}
|
|
608
609
|
*/
|
|
609
|
-
export const bitOr = /*@__PURE__*/
|
|
610
|
+
export const bitOr = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '|' ).setParameterLength( 2 ).setName( 'bitOr' );
|
|
610
611
|
|
|
611
612
|
/**
|
|
612
613
|
* Performs bitwise XOR on two nodes.
|
|
@@ -617,7 +618,7 @@ export const bitOr = /*@__PURE__*/ nodeProxy( OperatorNode, '|' ).setParameterLe
|
|
|
617
618
|
* @param {Node} b - The second input.
|
|
618
619
|
* @returns {OperatorNode}
|
|
619
620
|
*/
|
|
620
|
-
export const bitXor = /*@__PURE__*/
|
|
621
|
+
export const bitXor = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '^' ).setParameterLength( 2 ).setName( 'bitXor' );
|
|
621
622
|
|
|
622
623
|
/**
|
|
623
624
|
* Shifts a node to the left.
|
|
@@ -628,7 +629,7 @@ export const bitXor = /*@__PURE__*/ nodeProxy( OperatorNode, '^' ).setParameterL
|
|
|
628
629
|
* @param {Node} b - The value to shift.
|
|
629
630
|
* @returns {OperatorNode}
|
|
630
631
|
*/
|
|
631
|
-
export const shiftLeft = /*@__PURE__*/
|
|
632
|
+
export const shiftLeft = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '<<' ).setParameterLength( 2 ).setName( 'shiftLeft' );
|
|
632
633
|
|
|
633
634
|
/**
|
|
634
635
|
* Shifts a node to the right.
|
|
@@ -639,7 +640,7 @@ export const shiftLeft = /*@__PURE__*/ nodeProxy( OperatorNode, '<<' ).setParame
|
|
|
639
640
|
* @param {Node} b - The value to shift.
|
|
640
641
|
* @returns {OperatorNode}
|
|
641
642
|
*/
|
|
642
|
-
export const shiftRight = /*@__PURE__*/
|
|
643
|
+
export const shiftRight = /*@__PURE__*/ nodeProxyIntent( OperatorNode, '>>' ).setParameterLength( 2 ).setName( 'shiftRight' );
|
|
643
644
|
|
|
644
645
|
/**
|
|
645
646
|
* Increments a node by 1.
|