@types/three 0.180.0 → 0.182.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.
- three/README.md +1 -1
- three/examples/jsm/controls/ArcballControls.d.ts +1 -1
- three/examples/jsm/controls/DragControls.d.ts +1 -1
- three/examples/jsm/controls/FirstPersonControls.d.ts +1 -1
- three/examples/jsm/controls/FlyControls.d.ts +1 -1
- three/examples/jsm/controls/OrbitControls.d.ts +1 -1
- three/examples/jsm/controls/PointerLockControls.d.ts +1 -1
- three/examples/jsm/controls/TrackballControls.d.ts +1 -1
- three/examples/jsm/controls/TransformControls.d.ts +1 -1
- three/examples/jsm/geometries/TextGeometry.d.ts +2 -0
- three/examples/jsm/gpgpu/BitonicSort.d.ts +21 -0
- three/examples/jsm/inspector/Inspector.d.ts +10 -0
- three/examples/jsm/inspector/RendererInspector.d.ts +4 -0
- three/examples/jsm/inspector/tabs/Parameters.d.ts +95 -0
- three/examples/jsm/inspector/ui/Tab.d.ts +3 -0
- three/examples/jsm/inspector/ui/Values.d.ts +80 -0
- three/examples/jsm/interactive/SelectionBox.d.ts +9 -9
- three/examples/jsm/lighting/TiledLighting.d.ts +1 -2
- three/examples/jsm/loaders/FontLoader.d.ts +1 -1
- three/examples/jsm/loaders/KTX2Loader.d.ts +3 -0
- three/examples/jsm/loaders/UltraHDRLoader.d.ts +7 -0
- three/examples/jsm/loaders/VOXLoader.d.ts +22 -5
- three/examples/jsm/math/Octree.d.ts +36 -14
- three/examples/jsm/objects/SkyMesh.d.ts +11 -7
- three/examples/jsm/objects/WaterMesh.d.ts +2 -2
- three/examples/jsm/physics/AmmoPhysics.d.ts +1 -1
- three/examples/jsm/postprocessing/OutputPass.d.ts +10 -6
- three/examples/jsm/postprocessing/RenderPass.d.ts +15 -10
- three/examples/jsm/renderers/CSS2DRenderer.d.ts +15 -10
- three/examples/jsm/transpiler/AST.d.ts +17 -0
- three/examples/jsm/transpiler/TSLEncoder.d.ts +2 -0
- three/examples/jsm/tsl/display/AfterImageNode.d.ts +4 -5
- three/examples/jsm/tsl/display/AnaglyphPassNode.d.ts +1 -2
- three/examples/jsm/tsl/display/AnamorphicNode.d.ts +1 -2
- three/examples/jsm/tsl/display/BleachBypass.d.ts +1 -2
- three/examples/jsm/tsl/display/BloomNode.d.ts +2 -3
- three/examples/jsm/tsl/display/ChromaticAberrationNode.d.ts +1 -2
- three/examples/jsm/tsl/display/DenoiseNode.d.ts +1 -2
- three/examples/jsm/tsl/display/DepthOfFieldNode.d.ts +1 -2
- three/examples/jsm/tsl/display/DotScreenNode.d.ts +1 -2
- three/examples/jsm/tsl/display/FXAANode.d.ts +1 -2
- three/examples/jsm/tsl/display/FilmNode.d.ts +1 -2
- three/examples/jsm/tsl/display/GTAONode.d.ts +11 -10
- three/examples/jsm/tsl/display/GaussianBlurNode.d.ts +2 -3
- three/examples/jsm/tsl/display/LensflareNode.d.ts +6 -7
- three/examples/jsm/tsl/display/Lut3DNode.d.ts +2 -3
- three/examples/jsm/tsl/display/MotionBlur.d.ts +1 -2
- three/examples/jsm/tsl/display/OutlineNode.d.ts +6 -7
- three/examples/jsm/tsl/display/ParallaxBarrierPassNode.d.ts +1 -2
- three/examples/jsm/tsl/display/PixelationPassNode.d.ts +1 -2
- three/examples/jsm/tsl/display/RGBShiftNode.d.ts +1 -2
- three/examples/jsm/tsl/display/SMAANode.d.ts +1 -2
- three/examples/jsm/tsl/display/SSAAPassNode.d.ts +1 -2
- three/examples/jsm/tsl/display/SSGINode.d.ts +30 -0
- three/examples/jsm/tsl/display/SSRNode.d.ts +12 -13
- three/examples/jsm/tsl/display/SSSNode.d.ts +20 -0
- three/examples/jsm/tsl/display/Sepia.d.ts +1 -2
- three/examples/jsm/tsl/display/SobelOperatorNode.d.ts +1 -2
- three/examples/jsm/tsl/display/StereoPassNode.d.ts +1 -2
- three/examples/jsm/tsl/display/TRAANode.d.ts +6 -2
- three/examples/jsm/tsl/display/TransitionNode.d.ts +1 -2
- three/examples/jsm/tsl/display/boxBlur.d.ts +1 -2
- three/examples/jsm/tsl/display/hashBlur.d.ts +1 -2
- three/examples/jsm/tsl/display/radialBlur.d.ts +12 -0
- three/examples/jsm/tsl/lighting/TiledLightsNode.d.ts +3 -4
- three/examples/jsm/tsl/math/Bayer.d.ts +1 -2
- three/examples/jsm/tsl/utils/Raymarching.d.ts +2 -3
- three/package.json +3 -3
- three/src/Three.Core.d.ts +1 -1
- three/src/Three.TSL.d.ts +21 -3
- three/src/Three.WebGPU.Nodes.d.ts +2 -0
- three/src/Three.WebGPU.d.ts +2 -0
- three/src/animation/AnimationMixer.d.ts +45 -3
- three/src/animation/AnimationUtils.d.ts +3 -8
- three/src/constants.d.ts +14 -0
- three/src/core/BufferGeometry.d.ts +3 -1
- three/src/extras/Controls.d.ts +3 -3
- three/src/lights/DirectionalLight.d.ts +10 -3
- three/src/lights/HemisphereLight.d.ts +8 -1
- three/src/lights/Light.d.ts +8 -12
- three/src/lights/LightProbe.d.ts +7 -3
- three/src/lights/PointLight.d.ts +12 -1
- three/src/lights/PointLightShadow.d.ts +1 -8
- three/src/lights/SpotLight.d.ts +17 -2
- three/src/loaders/ObjectLoader.d.ts +3 -3
- three/src/loaders/TextureLoader.d.ts +3 -3
- three/src/materials/Material.d.ts +3 -2
- three/src/materials/MeshLambertMaterial.d.ts +1 -1
- three/src/materials/MeshMatcapMaterial.d.ts +14 -0
- three/src/materials/MeshPhongMaterial.d.ts +1 -1
- three/src/materials/MeshPhysicalMaterial.d.ts +1 -1
- three/src/materials/MeshStandardMaterial.d.ts +7 -7
- three/src/materials/PointsMaterial.d.ts +1 -1
- three/src/materials/ShaderMaterial.d.ts +26 -11
- three/src/materials/nodes/MeshSSSNodeMaterial.d.ts +1 -1
- three/src/materials/nodes/NodeMaterial.d.ts +9 -3
- three/src/materials/nodes/VolumeNodeMaterial.d.ts +1 -2
- three/src/math/Vector3.d.ts +2 -2
- three/src/nodes/Nodes.d.ts +1 -1
- three/src/nodes/TSL.d.ts +5 -2
- three/src/nodes/accessors/AccessorsUtils.d.ts +4 -5
- three/src/nodes/accessors/Arrays.d.ts +2 -3
- three/src/nodes/accessors/BatchNode.d.ts +1 -2
- three/src/nodes/accessors/Bitangent.d.ts +4 -5
- three/src/nodes/accessors/BufferAttributeNode.d.ts +17 -17
- three/src/nodes/accessors/BufferNode.d.ts +2 -2
- three/src/nodes/accessors/BuiltinNode.d.ts +1 -2
- three/src/nodes/accessors/Camera.d.ts +10 -11
- three/src/nodes/accessors/ClippingNode.d.ts +3 -6
- three/src/nodes/accessors/CubeTextureNode.d.ts +8 -9
- three/src/nodes/accessors/InstanceNode.d.ts +8 -8
- three/src/nodes/accessors/InstancedMeshNode.d.ts +1 -2
- three/src/nodes/accessors/Lights.d.ts +6 -7
- three/src/nodes/accessors/MaterialNode.d.ts +38 -39
- three/src/nodes/accessors/MaterialProperties.d.ts +3 -4
- three/src/nodes/accessors/MaterialReferenceNode.d.ts +2 -2
- three/src/nodes/accessors/ModelNode.d.ts +12 -13
- three/src/nodes/accessors/ModelViewProjectionNode.d.ts +1 -2
- three/src/nodes/accessors/MorphNode.d.ts +1 -2
- three/src/nodes/accessors/Normal.d.ts +13 -14
- three/src/nodes/accessors/Object3DNode.d.ts +6 -7
- three/src/nodes/accessors/PointUVNode.d.ts +1 -2
- three/src/nodes/accessors/Position.d.ts +7 -8
- three/src/nodes/accessors/ReferenceBaseNode.d.ts +2 -3
- three/src/nodes/accessors/ReferenceNode.d.ts +2 -3
- three/src/nodes/accessors/ReflectVector.d.ts +4 -5
- three/src/nodes/accessors/RendererReferenceNode.d.ts +1 -2
- three/src/nodes/accessors/SceneNode.d.ts +3 -4
- three/src/nodes/accessors/SkinningNode.d.ts +5 -6
- three/src/nodes/accessors/StorageBufferNode.d.ts +5 -5
- three/src/nodes/accessors/StorageTextureNode.d.ts +7 -4
- three/src/nodes/accessors/Tangent.d.ts +4 -6
- three/src/nodes/accessors/TangentUtils.d.ts +2 -3
- three/src/nodes/accessors/Texture3DNode.d.ts +15 -4
- three/src/nodes/accessors/TextureBicubic.d.ts +2 -3
- three/src/nodes/accessors/TextureNode.d.ts +29 -24
- three/src/nodes/accessors/TextureSizeNode.d.ts +1 -2
- three/src/nodes/accessors/UV.d.ts +1 -2
- three/src/nodes/accessors/UniformArrayNode.d.ts +2 -3
- three/src/nodes/accessors/UserDataNode.d.ts +1 -2
- three/src/nodes/accessors/VelocityNode.d.ts +1 -2
- three/src/nodes/accessors/VertexColorNode.d.ts +1 -2
- three/src/nodes/code/CodeNode.d.ts +4 -5
- three/src/nodes/code/ExpressionNode.d.ts +1 -2
- three/src/nodes/code/FunctionCallNode.d.ts +6 -5
- three/src/nodes/code/FunctionNode.d.ts +4 -6
- three/src/nodes/code/ScriptableNode.d.ts +1 -2
- three/src/nodes/code/ScriptableValueNode.d.ts +1 -2
- three/src/nodes/core/ArrayNode.d.ts +6 -6
- three/src/nodes/core/AssignNode.d.ts +1 -8
- three/src/nodes/core/AttributeNode.d.ts +1 -2
- three/src/nodes/core/BypassNode.d.ts +5 -5
- three/src/nodes/core/ContextNode.d.ts +42 -14
- three/src/nodes/core/IndexNode.d.ts +10 -7
- three/src/nodes/core/InspectorNode.d.ts +16 -0
- three/src/nodes/core/IsolateNode.d.ts +36 -0
- three/src/nodes/core/MRTNode.d.ts +3 -4
- three/src/nodes/core/Node.d.ts +18 -2
- three/src/nodes/core/NodeUtils.d.ts +1 -11
- three/src/nodes/core/OutputStructNode.d.ts +1 -2
- three/src/nodes/core/ParameterNode.d.ts +1 -2
- three/src/nodes/core/PropertyNode.d.ts +32 -31
- three/src/nodes/core/StackNode.d.ts +1 -4
- three/src/nodes/core/StructNode.d.ts +3 -4
- three/src/nodes/core/SubBuildNode.d.ts +1 -2
- three/src/nodes/core/UniformNode.d.ts +3 -6
- three/src/nodes/core/VarNode.d.ts +12 -8
- three/src/nodes/core/VaryingNode.d.ts +12 -10
- three/src/nodes/display/BlendModes.d.ts +11 -12
- three/src/nodes/display/BumpMapNode.d.ts +1 -2
- three/src/nodes/display/ColorAdjustment.d.ts +7 -8
- three/src/nodes/display/ColorSpaceFunctions.d.ts +2 -3
- three/src/nodes/display/ColorSpaceNode.d.ts +19 -9
- three/src/nodes/display/FrontFacingNode.d.ts +3 -4
- three/src/nodes/display/NormalMapNode.d.ts +4 -3
- three/src/nodes/display/PassNode.d.ts +28 -11
- three/src/nodes/display/PosterizeNode.d.ts +1 -2
- three/src/nodes/display/RenderOutputNode.d.ts +11 -6
- three/src/nodes/display/ScreenNode.d.ts +9 -10
- three/src/nodes/display/ToneMappingFunctions.d.ts +6 -7
- three/src/nodes/display/ToneMappingNode.d.ts +9 -8
- three/src/nodes/display/ToonOutlinePassNode.d.ts +1 -2
- three/src/nodes/display/ViewportDepthNode.d.ts +3 -4
- three/src/nodes/display/ViewportDepthTextureNode.d.ts +1 -2
- three/src/nodes/display/ViewportSharedTextureNode.d.ts +1 -2
- three/src/nodes/display/ViewportTextureNode.d.ts +2 -3
- three/src/nodes/fog/Fog.d.ts +5 -6
- three/src/nodes/functions/BSDF/BRDF_GGX.d.ts +4 -5
- three/src/nodes/functions/BSDF/BRDF_GGX_Multiscatter.d.ts +14 -0
- three/src/nodes/functions/BSDF/BRDF_Lambert.d.ts +1 -2
- three/src/nodes/functions/BSDF/BRDF_Sheen.d.ts +1 -2
- three/src/nodes/functions/BSDF/DFGLUT.d.ts +12 -0
- three/src/nodes/functions/BSDF/D_GGX.d.ts +1 -2
- three/src/nodes/functions/BSDF/D_GGX_Anisotropic.d.ts +1 -2
- three/src/nodes/functions/BSDF/F_Schlick.d.ts +1 -2
- three/src/nodes/functions/BSDF/Schlick_to_F0.d.ts +1 -2
- three/src/nodes/functions/BSDF/V_GGX_SmithCorrelated.d.ts +1 -2
- three/src/nodes/functions/BSDF/V_GGX_SmithCorrelated_Anisotropic.d.ts +1 -2
- three/src/nodes/functions/PhysicalLightingModel.d.ts +8 -1
- three/src/nodes/functions/ShadowMaskModel.d.ts +1 -2
- three/src/nodes/functions/material/getAlphaHashThreshold.d.ts +1 -2
- three/src/nodes/functions/material/getGeometryRoughness.d.ts +1 -2
- three/src/nodes/functions/material/getParallaxCorrectNormal.d.ts +1 -2
- three/src/nodes/functions/material/getRoughness.d.ts +1 -2
- three/src/nodes/functions/material/getShIrradianceAt.d.ts +1 -2
- three/src/nodes/geometry/RangeNode.d.ts +1 -2
- three/src/nodes/gpgpu/AtomicFunctionNode.d.ts +10 -11
- three/src/nodes/gpgpu/BarrierNode.d.ts +3 -4
- three/src/nodes/gpgpu/ComputeBuiltinNode.d.ts +5 -6
- three/src/nodes/gpgpu/ComputeNode.d.ts +21 -13
- three/src/nodes/gpgpu/SubgroupFunctionNode.d.ts +25 -26
- three/src/nodes/gpgpu/WorkgroupInfoNode.d.ts +1 -2
- three/src/nodes/lighting/AnalyticLightNode.d.ts +3 -2
- three/src/nodes/lighting/LightUtils.d.ts +1 -2
- three/src/nodes/lighting/LightingContextNode.d.ts +1 -2
- three/src/nodes/lighting/LightsNode.d.ts +1 -2
- three/src/nodes/lighting/PointLightNode.d.ts +5 -6
- three/src/nodes/lighting/PointShadowNode.d.ts +12 -17
- three/src/nodes/lighting/ShadowBaseNode.d.ts +1 -2
- three/src/nodes/lighting/ShadowFilterNode.d.ts +6 -5
- three/src/nodes/lighting/ShadowNode.d.ts +1 -2
- three/src/nodes/lighting/SpotLightNode.d.ts +1 -2
- three/src/nodes/materialx/MaterialXNodes.d.ts +41 -42
- three/src/nodes/materialx/lib/mx_hsv.d.ts +2 -3
- three/src/nodes/materialx/lib/mx_noise.d.ts +73 -74
- three/src/nodes/materialx/lib/mx_transform_color.d.ts +1 -2
- three/src/nodes/math/BitcastNode.d.ts +5 -6
- three/src/nodes/math/BitcountNode.d.ts +21 -0
- three/src/nodes/math/ConditionalNode.d.ts +11 -5
- three/src/nodes/math/Hash.d.ts +1 -2
- three/src/nodes/math/MathNode.d.ts +223 -77
- three/src/nodes/math/OperatorNode.d.ts +203 -59
- three/src/nodes/math/PackFloatNode.d.ts +19 -0
- three/src/nodes/math/TriNoise3D.d.ts +3 -4
- three/src/nodes/math/UnpackFloatNode.d.ts +18 -0
- three/src/nodes/pmrem/PMREMNode.d.ts +1 -2
- three/src/nodes/pmrem/PMREMUtils.d.ts +3 -4
- three/src/nodes/procedural/Checker.d.ts +1 -2
- three/src/nodes/shapes/Shapes.d.ts +1 -2
- three/src/nodes/tsl/TSLBase.d.ts +2 -1
- three/src/nodes/tsl/TSLCore.d.ts +235 -128
- three/src/nodes/utils/CubeMapNode.d.ts +1 -2
- three/src/nodes/utils/DebugNode.d.ts +9 -5
- three/src/nodes/utils/Discard.d.ts +6 -6
- three/src/nodes/utils/EquirectUV.d.ts +1 -2
- three/src/nodes/utils/EventNode.d.ts +8 -3
- three/src/nodes/utils/FunctionOverloadingNode.d.ts +1 -2
- three/src/nodes/utils/LoopNode.d.ts +7 -6
- three/src/nodes/utils/MatcapUV.d.ts +1 -2
- three/src/nodes/utils/MaxMipLevelNode.d.ts +1 -2
- three/src/nodes/utils/Oscillators.d.ts +4 -5
- three/src/nodes/utils/Packing.d.ts +3 -3
- three/src/nodes/utils/PostProcessingUtils.d.ts +7 -4
- three/src/nodes/utils/RTTNode.d.ts +2 -3
- three/src/nodes/utils/ReflectorNode.d.ts +2 -3
- three/src/nodes/utils/RemapNode.d.ts +29 -7
- three/src/nodes/utils/RotateNode.d.ts +1 -2
- three/src/nodes/utils/SampleNode.d.ts +1 -2
- three/src/nodes/utils/SpriteSheetUVNode.d.ts +1 -2
- three/src/nodes/utils/SpriteUtils.d.ts +1 -2
- three/src/nodes/utils/StorageArrayElementNode.d.ts +1 -2
- three/src/nodes/utils/Timer.d.ts +3 -4
- three/src/nodes/utils/TriplanarTextures.d.ts +2 -3
- three/src/nodes/utils/UVUtils.d.ts +5 -3
- three/src/nodes/utils/ViewportUtils.d.ts +1 -2
- three/src/objects/LOD.d.ts +1 -1
- three/src/objects/Skeleton.d.ts +4 -2
- three/src/renderers/WebGLRenderer.d.ts +22 -4
- three/src/renderers/common/Animation.d.ts +4 -1
- three/src/renderers/common/Binding.d.ts +6 -0
- three/src/renderers/common/Bindings.d.ts +12 -0
- three/src/renderers/common/Buffer.d.ts +24 -0
- three/src/renderers/common/CanvasTarget.d.ts +142 -0
- three/src/renderers/common/ChainMap.d.ts +8 -1
- three/src/renderers/common/Geometries.d.ts +8 -0
- three/src/renderers/common/InspectorBase.d.ts +105 -0
- three/src/renderers/common/PostProcessing.d.ts +3 -0
- three/src/renderers/common/QuadMesh.d.ts +3 -0
- three/src/renderers/common/RenderContexts.d.ts +6 -2
- three/src/renderers/common/RenderObject.d.ts +6 -0
- three/src/renderers/common/Renderer.d.ts +145 -46
- three/src/renderers/common/SampledTexture.d.ts +2 -0
- three/src/renderers/common/Sampler.d.ts +2 -0
- three/src/renderers/common/Textures.d.ts +20 -0
- three/src/renderers/common/TimestampQueryPool.d.ts +24 -1
- three/src/renderers/common/UniformsGroup.d.ts +1 -0
- three/src/renderers/common/extras/PMREMGenerator.d.ts +19 -1
- three/src/renderers/common/nodes/NodeLibrary.d.ts +3 -7
- three/src/renderers/common/nodes/Nodes.d.ts +13 -14
- three/src/renderers/shaders/ShaderLib.d.ts +1 -1
- three/src/renderers/webgl/WebGLCapabilities.d.ts +2 -2
- three/src/renderers/webgl/WebGLPrograms.d.ts +0 -1
- three/src/renderers/webgpu/utils/WebGPUConstants.d.ts +5 -0
- three/src/scenes/Scene.d.ts +2 -2
- three/src/textures/CanvasTexture.d.ts +3 -3
- three/src/textures/CompressedArrayTexture.d.ts +6 -9
- three/src/textures/CompressedCubeTexture.d.ts +3 -3
- three/src/textures/CompressedTexture.d.ts +6 -8
- three/src/textures/CubeDepthTexture.d.ts +41 -0
- three/src/textures/CubeTexture.d.ts +4 -11
- three/src/textures/Data3DTexture.d.ts +5 -10
- three/src/textures/DataArrayTexture.d.ts +10 -10
- three/src/textures/DataTexture.d.ts +4 -11
- three/src/textures/DepthTexture.d.ts +7 -8
- three/src/textures/ExternalTexture.d.ts +3 -1
- three/src/textures/FramebufferTexture.d.ts +6 -1
- three/src/textures/Source.d.ts +3 -3
- three/src/textures/Texture.d.ts +8 -8
- three/src/textures/VideoFrameTexture.d.ts +1 -1
- three/src/textures/VideoTexture.d.ts +2 -2
- three/src/utils.d.ts +30 -2
- three/src/nodes/core/CacheNode.d.ts +0 -21
- three/src/nodes/functions/BSDF/DFGApprox.d.ts +0 -11
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
2
|
import TempNode from "../core/TempNode.js";
|
|
3
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
4
3
|
|
|
5
4
|
declare class CubeMapNode extends TempNode {
|
|
6
5
|
envNode: Node;
|
|
@@ -10,4 +9,4 @@ declare class CubeMapNode extends TempNode {
|
|
|
10
9
|
|
|
11
10
|
export default CubeMapNode;
|
|
12
11
|
|
|
13
|
-
export const cubeMapNode: (envNode: Node) =>
|
|
12
|
+
export const cubeMapNode: (envNode: Node) => CubeMapNode;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
2
|
import NodeBuilder from "../core/NodeBuilder.js";
|
|
3
3
|
import TempNode from "../core/TempNode.js";
|
|
4
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
5
4
|
|
|
6
5
|
declare class DebugNode extends TempNode {
|
|
7
6
|
constructor(node: Node, callback?: ((code: string) => void) | null);
|
|
@@ -12,10 +11,15 @@ export default DebugNode;
|
|
|
12
11
|
export const debug: (
|
|
13
12
|
node: Node,
|
|
14
13
|
callback?: ((node: NodeBuilder, code: string) => void) | null,
|
|
15
|
-
) =>
|
|
14
|
+
) => DebugNode;
|
|
16
15
|
|
|
17
|
-
declare module "../
|
|
18
|
-
interface
|
|
19
|
-
debug:
|
|
16
|
+
declare module "../Nodes.js" {
|
|
17
|
+
interface Node {
|
|
18
|
+
debug: (
|
|
19
|
+
callback?: ((node: NodeBuilder, code: string) => void) | null,
|
|
20
|
+
) => DebugNode;
|
|
21
|
+
debugAssign: (
|
|
22
|
+
callback?: ((node: NodeBuilder, code: string) => void) | null,
|
|
23
|
+
) => this;
|
|
20
24
|
}
|
|
21
25
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
3
2
|
|
|
4
|
-
export const Discard: (conditional?: Node) =>
|
|
5
|
-
export const Return: () =>
|
|
3
|
+
export const Discard: (conditional?: Node) => Node;
|
|
4
|
+
export const Return: () => Node;
|
|
6
5
|
|
|
7
|
-
declare module "../
|
|
8
|
-
interface
|
|
9
|
-
discard:
|
|
6
|
+
declare module "../Nodes.js" {
|
|
7
|
+
interface Node {
|
|
8
|
+
discard: () => Node;
|
|
9
|
+
discardAssign: () => this;
|
|
10
10
|
}
|
|
11
11
|
}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
2
|
import NodeFrame from "../core/NodeFrame.js";
|
|
3
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
4
3
|
|
|
5
4
|
export type EventNodeType = typeof EventNode.OBJECT | typeof EventNode.MATERIAL;
|
|
6
5
|
|
|
@@ -12,10 +11,16 @@ declare class EventNode extends Node {
|
|
|
12
11
|
|
|
13
12
|
static OBJECT: "object";
|
|
14
13
|
static MATERIAL: "material";
|
|
14
|
+
static BEFORE_OBJECT: "beforeObject";
|
|
15
|
+
static BEFORE_MATERIAL: "beforeMaterial";
|
|
15
16
|
}
|
|
16
17
|
|
|
17
18
|
export default EventNode;
|
|
18
19
|
|
|
19
|
-
export const OnObjectUpdate: (callback: (frame: NodeFrame) => void) =>
|
|
20
|
+
export const OnObjectUpdate: (callback: (frame: NodeFrame) => void) => Node;
|
|
20
21
|
|
|
21
|
-
export const OnMaterialUpdate: (callback: (frame: NodeFrame) => void) =>
|
|
22
|
+
export const OnMaterialUpdate: (callback: (frame: NodeFrame) => void) => Node;
|
|
23
|
+
|
|
24
|
+
export const OnBeforeObjectUpdate: (callback: (frame: NodeFrame) => void) => Node;
|
|
25
|
+
|
|
26
|
+
export const OnBeforeMaterialUpdate: (callback: (frame: NodeFrame) => void) => Node;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
3
2
|
|
|
4
3
|
declare class FunctionOverloadingNode extends Node {
|
|
5
4
|
functionNodes: Node[];
|
|
@@ -10,4 +9,4 @@ declare class FunctionOverloadingNode extends Node {
|
|
|
10
9
|
|
|
11
10
|
export default FunctionOverloadingNode;
|
|
12
11
|
|
|
13
|
-
export const overloadingFn: (functionNodes: Node[]) => (...params: Node[]) =>
|
|
12
|
+
export const overloadingFn: (functionNodes: Node[]) => (...params: Node[]) => FunctionOverloadingNode;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
2
|
import NodeBuilder from "../core/NodeBuilder.js";
|
|
3
|
-
import {
|
|
3
|
+
import { VarNode } from "../Nodes.js";
|
|
4
4
|
|
|
5
5
|
interface LoopNodeObjectParameter {
|
|
6
6
|
// TODO Expand to other types and update loop function types appropriately
|
|
@@ -10,6 +10,7 @@ interface LoopNodeObjectParameter {
|
|
|
10
10
|
start: number | Node;
|
|
11
11
|
end: number | Node;
|
|
12
12
|
condition?: string;
|
|
13
|
+
update?: VarNode | number | string;
|
|
13
14
|
}
|
|
14
15
|
|
|
15
16
|
type LoopNodeParameter = Node | number | LoopNodeObjectParameter;
|
|
@@ -25,14 +26,14 @@ declare class LoopNode extends Node {
|
|
|
25
26
|
export default LoopNode;
|
|
26
27
|
|
|
27
28
|
interface Loop {
|
|
28
|
-
(i: LoopNodeParameter, func: (inputs: { readonly i:
|
|
29
|
+
(i: LoopNodeParameter, func: (inputs: { readonly i: Node }) => void): Node;
|
|
29
30
|
(
|
|
30
31
|
i: LoopNodeParameter,
|
|
31
32
|
j: LoopNodeParameter,
|
|
32
|
-
func: (inputs: { readonly i:
|
|
33
|
-
):
|
|
33
|
+
func: (inputs: { readonly i: Node; readonly j: Node }) => void,
|
|
34
|
+
): Node;
|
|
34
35
|
}
|
|
35
36
|
|
|
36
37
|
export const Loop: Loop;
|
|
37
|
-
export const Continue: () =>
|
|
38
|
-
export const Break: () =>
|
|
38
|
+
export const Continue: () => Node;
|
|
39
|
+
export const Break: () => Node;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { Texture } from "../../textures/Texture.js";
|
|
2
2
|
import TextureNode from "../accessors/TextureNode.js";
|
|
3
3
|
import UniformNode from "../core/UniformNode.js";
|
|
4
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
5
4
|
|
|
6
5
|
export default class MaxMipLevelNode extends UniformNode<0> {
|
|
7
6
|
constructor(textureNode: TextureNode);
|
|
@@ -11,4 +10,4 @@ export default class MaxMipLevelNode extends UniformNode<0> {
|
|
|
11
10
|
get texture(): Texture;
|
|
12
11
|
}
|
|
13
12
|
|
|
14
|
-
export const maxMipLevel: (texture: Texture) =>
|
|
13
|
+
export const maxMipLevel: (texture: Texture) => MaxMipLevelNode;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
3
2
|
|
|
4
|
-
export const oscSine: (timeNode?: Node) =>
|
|
5
|
-
export const oscSquare: (timeNode?: Node) =>
|
|
6
|
-
export const oscTriangle: (timeNode?: Node) =>
|
|
7
|
-
export const oscSawtooth: (timeNode?: Node) =>
|
|
3
|
+
export const oscSine: (timeNode?: Node) => Node;
|
|
4
|
+
export const oscSquare: (timeNode?: Node) => Node;
|
|
5
|
+
export const oscTriangle: (timeNode?: Node) => Node;
|
|
6
|
+
export const oscSawtooth: (timeNode?: Node) => Node;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
3
2
|
|
|
4
|
-
export const directionToColor: (node: Node) =>
|
|
5
|
-
export const colorToDirection: (node: Node) =>
|
|
3
|
+
export const directionToColor: (node: Node) => Node;
|
|
4
|
+
export const colorToDirection: (node: Node) => Node;
|
|
5
|
+
export const unpackNormal: (xy: Node) => Node;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
3
2
|
|
|
4
3
|
/**
|
|
5
4
|
* Computes a position in view space based on a fragment's screen position expressed as uv coordinates, the fragments
|
|
@@ -14,7 +13,7 @@ export const getViewPosition: (
|
|
|
14
13
|
screenPosition: Node,
|
|
15
14
|
depth: Node,
|
|
16
15
|
projectionMatrixInverse: Node,
|
|
17
|
-
) =>
|
|
16
|
+
) => Node;
|
|
18
17
|
|
|
19
18
|
/**
|
|
20
19
|
* Computes a screen position expressed as uv coordinates based on a fragment's position in view space and the camera's
|
|
@@ -27,7 +26,7 @@ export const getViewPosition: (
|
|
|
27
26
|
export const getScreenPosition: (
|
|
28
27
|
viewPosition: Node,
|
|
29
28
|
projectionMatrix: Node,
|
|
30
|
-
) =>
|
|
29
|
+
) => Node;
|
|
31
30
|
|
|
32
31
|
/**
|
|
33
32
|
* Computes a normal vector based on depth data. Can be used as a fallback when no normal render target is available or
|
|
@@ -42,4 +41,8 @@ export const getNormalFromDepth: (
|
|
|
42
41
|
uv: Node,
|
|
43
42
|
depthTexture: Node,
|
|
44
43
|
projectionMatrixInverse: Node,
|
|
45
|
-
) =>
|
|
44
|
+
) => Node;
|
|
45
|
+
|
|
46
|
+
export const interleavedGradientNoise: (position: Node) => Node;
|
|
47
|
+
|
|
48
|
+
export const vogelDiskSample: (sampleIndex: Node, samplesCount: Node, phi: Node) => Node;
|
|
@@ -2,7 +2,6 @@ import { TextureDataType } from "../../constants.js";
|
|
|
2
2
|
import { RenderTarget } from "../../core/RenderTarget.js";
|
|
3
3
|
import TextureNode from "../accessors/TextureNode.js";
|
|
4
4
|
import Node from "../core/Node.js";
|
|
5
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
6
5
|
|
|
7
6
|
export interface RTTNodeOptions {
|
|
8
7
|
type: TextureDataType;
|
|
@@ -38,10 +37,10 @@ export const rtt: (
|
|
|
38
37
|
width?: number | null,
|
|
39
38
|
height?: number | null,
|
|
40
39
|
options?: RTTNodeOptions,
|
|
41
|
-
) =>
|
|
40
|
+
) => RTTNode;
|
|
42
41
|
export const convertToTexture: (
|
|
43
42
|
node: Node,
|
|
44
43
|
width?: number | null,
|
|
45
44
|
height?: number | null,
|
|
46
45
|
options?: RTTNodeOptions,
|
|
47
|
-
) =>
|
|
46
|
+
) => RTTNode;
|
|
@@ -3,7 +3,6 @@ import { Object3D } from "../../core/Object3D.js";
|
|
|
3
3
|
import { RenderTarget } from "../../core/RenderTarget.js";
|
|
4
4
|
import TextureNode from "../accessors/TextureNode.js";
|
|
5
5
|
import Node from "../core/Node.js";
|
|
6
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
7
6
|
|
|
8
7
|
export interface ReflectorNodeParameters {
|
|
9
8
|
target?: Object3D | undefined;
|
|
@@ -25,7 +24,7 @@ declare class ReflectorNode extends TextureNode {
|
|
|
25
24
|
|
|
26
25
|
get target(): Object3D;
|
|
27
26
|
|
|
28
|
-
getDepthNode():
|
|
27
|
+
getDepthNode(): ReflectorNode;
|
|
29
28
|
}
|
|
30
29
|
|
|
31
30
|
declare class ReflectorBaseNode extends Node {
|
|
@@ -57,6 +56,6 @@ declare class ReflectorBaseNode extends Node {
|
|
|
57
56
|
set resolution(value: number);
|
|
58
57
|
}
|
|
59
58
|
|
|
60
|
-
export const reflector: (parameters?: ReflectorNodeParameters) =>
|
|
59
|
+
export const reflector: (parameters?: ReflectorNodeParameters) => ReflectorNode;
|
|
61
60
|
|
|
62
61
|
export default ReflectorNode;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
3
2
|
|
|
4
3
|
export default class RemapNode extends Node {
|
|
5
4
|
node: Node;
|
|
@@ -19,18 +18,41 @@ export const remap: (
|
|
|
19
18
|
inHighNode: Node | number,
|
|
20
19
|
outLowNode?: Node | number,
|
|
21
20
|
outHighNode?: Node | number,
|
|
22
|
-
) =>
|
|
21
|
+
) => RemapNode;
|
|
23
22
|
export const remapClamp: (
|
|
24
23
|
node: Node,
|
|
25
24
|
inLowNode: Node | number,
|
|
26
25
|
inHighNode: Node | number,
|
|
27
26
|
outLowNode?: Node | number,
|
|
28
27
|
outHighNode?: Node | number,
|
|
29
|
-
) =>
|
|
28
|
+
) => RemapNode;
|
|
30
29
|
|
|
31
|
-
declare module "../
|
|
32
|
-
interface
|
|
33
|
-
remap:
|
|
34
|
-
|
|
30
|
+
declare module "../Nodes.js" {
|
|
31
|
+
interface Node {
|
|
32
|
+
remap: (
|
|
33
|
+
inLowNode: Node | number,
|
|
34
|
+
inHighNode: Node | number,
|
|
35
|
+
outLowNode?: Node | number,
|
|
36
|
+
outHighNode?: Node | number,
|
|
37
|
+
) => RemapNode;
|
|
38
|
+
remapAssign: (
|
|
39
|
+
inLowNode: Node | number,
|
|
40
|
+
inHighNode: Node | number,
|
|
41
|
+
outLowNode?: Node | number,
|
|
42
|
+
outHighNode?: Node | number,
|
|
43
|
+
) => this;
|
|
44
|
+
|
|
45
|
+
remapClamp: (
|
|
46
|
+
inLowNode: Node | number,
|
|
47
|
+
inHighNode: Node | number,
|
|
48
|
+
outLowNode?: Node | number,
|
|
49
|
+
outHighNode?: Node | number,
|
|
50
|
+
) => RemapNode;
|
|
51
|
+
remapClampAssign: (
|
|
52
|
+
inLowNode: Node | number,
|
|
53
|
+
inHighNode: Node | number,
|
|
54
|
+
outLowNode?: Node | number,
|
|
55
|
+
outHighNode?: Node | number,
|
|
56
|
+
) => this;
|
|
35
57
|
}
|
|
36
58
|
}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
2
|
import TempNode from "../core/TempNode.js";
|
|
3
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
4
3
|
|
|
5
4
|
export default class RotateNode extends TempNode {
|
|
6
5
|
positionNode: Node;
|
|
@@ -12,4 +11,4 @@ export default class RotateNode extends TempNode {
|
|
|
12
11
|
export const rotate: (
|
|
13
12
|
positionNode: Node,
|
|
14
13
|
rotationNode: Node | number,
|
|
15
|
-
) =>
|
|
14
|
+
) => RotateNode;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
3
2
|
|
|
4
3
|
declare class SampleNode extends Node {
|
|
5
4
|
callback: (uv: Node) => Node;
|
|
@@ -14,4 +13,4 @@ declare class SampleNode extends Node {
|
|
|
14
13
|
|
|
15
14
|
export default SampleNode;
|
|
16
15
|
|
|
17
|
-
export const sample: (callback: (uv: Node) => Node, uv?: Node | null) =>
|
|
16
|
+
export const sample: (callback: (uv: Node) => Node, uv?: Node | null) => SampleNode;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
3
2
|
|
|
4
3
|
export default class SpriteSheetUVNode extends Node {
|
|
5
4
|
countNode: Node;
|
|
@@ -13,4 +12,4 @@ export const spritesheetUV: (
|
|
|
13
12
|
countNode: Node,
|
|
14
13
|
uvNode: Node | null,
|
|
15
14
|
frameNode: Node | null,
|
|
16
|
-
) =>
|
|
15
|
+
) => SpriteSheetUVNode;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import StorageBufferNode from "../accessors/StorageBufferNode.js";
|
|
2
2
|
import Node from "../core/Node.js";
|
|
3
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
4
3
|
import ArrayElementNode from "./ArrayElementNode.js";
|
|
5
4
|
|
|
6
5
|
export default class StorageArrayElementNode extends ArrayElementNode {
|
|
@@ -17,4 +16,4 @@ export default class StorageArrayElementNode extends ArrayElementNode {
|
|
|
17
16
|
export const storageElement: (
|
|
18
17
|
storageBufferNode: Node,
|
|
19
18
|
indexNode: Node,
|
|
20
|
-
) =>
|
|
19
|
+
) => StorageArrayElementNode;
|
three/src/nodes/utils/Timer.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
3
2
|
|
|
4
|
-
export const time:
|
|
5
|
-
export const deltaTime:
|
|
6
|
-
export const frameId:
|
|
3
|
+
export const time: Node;
|
|
4
|
+
export const deltaTime: Node;
|
|
5
|
+
export const frameId: Node;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import Node from "../core/Node.js";
|
|
2
|
-
import { ShaderNodeObject } from "../tsl/TSLCore.js";
|
|
3
2
|
|
|
4
3
|
export const triplanarTextures: (
|
|
5
4
|
textureXNode: Node,
|
|
@@ -8,7 +7,7 @@ export const triplanarTextures: (
|
|
|
8
7
|
scaleNode?: Node,
|
|
9
8
|
positionNode?: Node,
|
|
10
9
|
normalNode?: Node,
|
|
11
|
-
) =>
|
|
10
|
+
) => Node;
|
|
12
11
|
|
|
13
12
|
export const triplanarTexture: (
|
|
14
13
|
textureXNode: Node,
|
|
@@ -17,4 +16,4 @@ export const triplanarTexture: (
|
|
|
17
16
|
scaleNode?: Node,
|
|
18
17
|
positionNode?: Node,
|
|
19
18
|
normalNode?: Node,
|
|
20
|
-
) =>
|
|
19
|
+
) => Node;
|
|
@@ -1,15 +1,17 @@
|
|
|
1
|
+
import ContextNode from "../core/ContextNode.js";
|
|
1
2
|
import Node from "../core/Node.js";
|
|
2
3
|
import OperatorNode from "../math/OperatorNode.js";
|
|
3
|
-
|
|
4
|
+
|
|
5
|
+
export function replaceDefaultUV(callback: (node: Node) => Node, node?: Node | null): ContextNode;
|
|
4
6
|
|
|
5
7
|
export const rotateUV: (
|
|
6
8
|
uv: Node,
|
|
7
9
|
rotation: Node,
|
|
8
10
|
center?: Node,
|
|
9
|
-
) =>
|
|
11
|
+
) => OperatorNode;
|
|
10
12
|
|
|
11
13
|
export const spherizeUV: (
|
|
12
14
|
uv: Node,
|
|
13
15
|
strength: Node | number,
|
|
14
16
|
center?: Node,
|
|
15
|
-
) =>
|
|
17
|
+
) => OperatorNode;
|
three/src/objects/LOD.d.ts
CHANGED
|
@@ -57,7 +57,7 @@ export class LOD<TEventMap extends Object3DEventMap = Object3DEventMap> extends
|
|
|
57
57
|
/**
|
|
58
58
|
* An array of level objects
|
|
59
59
|
*/
|
|
60
|
-
levels: Array<{
|
|
60
|
+
readonly levels: Array<{
|
|
61
61
|
/** The Object3D to display at this level. */
|
|
62
62
|
object: Object3D;
|
|
63
63
|
/** The distance at which to display this level of detail. Expects a `Float`. */
|
three/src/objects/Skeleton.d.ts
CHANGED
|
@@ -61,12 +61,14 @@ export class Skeleton {
|
|
|
61
61
|
/**
|
|
62
62
|
* The array buffer holding the bone data when using a vertex texture.
|
|
63
63
|
*/
|
|
64
|
-
boneMatrices: Float32Array;
|
|
64
|
+
boneMatrices: Float32Array | null;
|
|
65
|
+
|
|
66
|
+
previousBoneMatrices: Float32Array | null;
|
|
65
67
|
|
|
66
68
|
/**
|
|
67
69
|
* The {@link THREE.DataTexture | DataTexture} holding the bone data when using a vertex texture.
|
|
68
70
|
*/
|
|
69
|
-
boneTexture:
|
|
71
|
+
boneTexture: DataTexture | null;
|
|
70
72
|
|
|
71
73
|
frame: number;
|
|
72
74
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Camera } from "../cameras/Camera.js";
|
|
2
|
-
import { CullFace, ShadowMapType, ToneMapping, WebGLCoordinateSystem } from "../constants.js";
|
|
2
|
+
import { CullFace, ShadowMapType, TextureDataType, ToneMapping, WebGLCoordinateSystem } from "../constants.js";
|
|
3
3
|
import { TypedArray } from "../core/BufferAttribute.js";
|
|
4
4
|
import { BufferGeometry } from "../core/BufferGeometry.js";
|
|
5
5
|
import { Object3D } from "../core/Object3D.js";
|
|
@@ -76,6 +76,11 @@ export interface WebGLRendererParameters extends WebGLCapabilitiesParameters {
|
|
|
76
76
|
* default is false.
|
|
77
77
|
*/
|
|
78
78
|
failIfMajorPerformanceCaveat?: boolean | undefined;
|
|
79
|
+
|
|
80
|
+
/**
|
|
81
|
+
* @default UnsignedByteType
|
|
82
|
+
*/
|
|
83
|
+
outputBufferType?: TextureDataType | undefined;
|
|
79
84
|
}
|
|
80
85
|
|
|
81
86
|
export interface WebGLDebug {
|
|
@@ -100,6 +105,17 @@ export interface WebGLDebug {
|
|
|
100
105
|
| null;
|
|
101
106
|
}
|
|
102
107
|
|
|
108
|
+
export interface Effect {
|
|
109
|
+
setSize(width: number, height: number): void;
|
|
110
|
+
render(
|
|
111
|
+
renderer: WebGLRenderer,
|
|
112
|
+
writeBuffer: WebGLRenderTarget,
|
|
113
|
+
readBuffer: WebGLRenderTarget,
|
|
114
|
+
deltaTime: number,
|
|
115
|
+
maskActive: boolean,
|
|
116
|
+
): void;
|
|
117
|
+
}
|
|
118
|
+
|
|
103
119
|
/**
|
|
104
120
|
* The WebGL renderer displays your beautifully crafted scenes using WebGL, if your device supports it.
|
|
105
121
|
* This renderer has way better performance than CanvasRenderer.
|
|
@@ -228,9 +244,6 @@ export class WebGLRenderer {
|
|
|
228
244
|
getPixelRatio(): number;
|
|
229
245
|
setPixelRatio(value: number): void;
|
|
230
246
|
|
|
231
|
-
getDrawingBufferSize(target: Vector2): Vector2;
|
|
232
|
-
setDrawingBufferSize(width: number, height: number, pixelRatio: number): void;
|
|
233
|
-
|
|
234
247
|
getSize(target: Vector2): Vector2;
|
|
235
248
|
|
|
236
249
|
/**
|
|
@@ -238,6 +251,11 @@ export class WebGLRenderer {
|
|
|
238
251
|
*/
|
|
239
252
|
setSize(width: number, height: number, updateStyle?: boolean): void;
|
|
240
253
|
|
|
254
|
+
getDrawingBufferSize(target: Vector2): Vector2;
|
|
255
|
+
setDrawingBufferSize(width: number, height: number, pixelRatio: number): void;
|
|
256
|
+
|
|
257
|
+
setEffects(effects: Effect[] | null): void;
|
|
258
|
+
|
|
241
259
|
getCurrentViewport(target: Vector4): Vector4;
|
|
242
260
|
|
|
243
261
|
/**
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import Info from "./Info.js";
|
|
2
2
|
import Nodes from "./nodes/Nodes.js";
|
|
3
|
+
import Renderer from "./Renderer.js";
|
|
3
4
|
export interface AnimationContext {
|
|
4
5
|
requestAnimationFrame(callback: FrameRequestCallback, xrFrame?: XRFrame): number;
|
|
5
6
|
cancelAnimationFrame(handle: number): void;
|
|
@@ -10,6 +11,7 @@ export interface AnimationContext {
|
|
|
10
11
|
* @private
|
|
11
12
|
*/
|
|
12
13
|
declare class Animation {
|
|
14
|
+
renderer: Renderer;
|
|
13
15
|
nodes: Nodes;
|
|
14
16
|
info: Info;
|
|
15
17
|
_context: AnimationContext | null;
|
|
@@ -18,10 +20,11 @@ declare class Animation {
|
|
|
18
20
|
/**
|
|
19
21
|
* Constructs a new animation loop management component.
|
|
20
22
|
*
|
|
23
|
+
* @param {Renderer} renderer - A reference to the main renderer.
|
|
21
24
|
* @param {Nodes} nodes - Renderer component for managing nodes related logic.
|
|
22
25
|
* @param {Info} info - Renderer component for managing metrics and monitoring data.
|
|
23
26
|
*/
|
|
24
|
-
constructor(nodes: Nodes, info: Info);
|
|
27
|
+
constructor(renderer: Renderer, nodes: Nodes, info: Info);
|
|
25
28
|
/**
|
|
26
29
|
* Starts the internal animation loop.
|
|
27
30
|
*/
|
|
@@ -22,6 +22,12 @@ declare class Binding {
|
|
|
22
22
|
* @param {number} visibility - The shader stage.
|
|
23
23
|
*/
|
|
24
24
|
setVisibility(visibility: number): void;
|
|
25
|
+
/**
|
|
26
|
+
* The shader stages in which the binding's resource is visible.
|
|
27
|
+
*
|
|
28
|
+
* @return {number} The visibility bitmask.
|
|
29
|
+
*/
|
|
30
|
+
getVisibility(): number;
|
|
25
31
|
/**
|
|
26
32
|
* Clones the binding.
|
|
27
33
|
*
|
|
@@ -73,6 +73,18 @@ declare class Bindings extends DataMap<{
|
|
|
73
73
|
* @param {RenderObject} renderObject - The render object.
|
|
74
74
|
*/
|
|
75
75
|
updateForRender(renderObject: RenderObject): void;
|
|
76
|
+
/**
|
|
77
|
+
* Deletes the bindings for the given compute node.
|
|
78
|
+
*
|
|
79
|
+
* @param {Node} computeNode - The compute node.
|
|
80
|
+
*/
|
|
81
|
+
deleteForCompute(computeNode: ComputeNode): void;
|
|
82
|
+
/**
|
|
83
|
+
* Deletes the bindings for the given renderObject node.
|
|
84
|
+
*
|
|
85
|
+
* @param {RenderObject} renderObject - The renderObject.
|
|
86
|
+
*/
|
|
87
|
+
deleteForRender(renderObject: RenderObject): void;
|
|
76
88
|
/**
|
|
77
89
|
* Updates the given array of bindings.
|
|
78
90
|
*
|
|
@@ -10,6 +10,10 @@ declare class Buffer extends Binding {
|
|
|
10
10
|
readonly isBuffer: true;
|
|
11
11
|
bytesPerElement: number;
|
|
12
12
|
_buffer: Float32Array | null;
|
|
13
|
+
_updateRanges: {
|
|
14
|
+
start: number;
|
|
15
|
+
count: number;
|
|
16
|
+
}[];
|
|
13
17
|
/**
|
|
14
18
|
* Constructs a new buffer.
|
|
15
19
|
*
|
|
@@ -17,6 +21,26 @@ declare class Buffer extends Binding {
|
|
|
17
21
|
* @param {TypedArray} [buffer=null] - The buffer.
|
|
18
22
|
*/
|
|
19
23
|
constructor(name?: string, buffer?: Float32Array | null);
|
|
24
|
+
/**
|
|
25
|
+
* The array of update ranges.
|
|
26
|
+
*
|
|
27
|
+
* @type {Array<{start: number, count: number}>}
|
|
28
|
+
*/
|
|
29
|
+
get updateRanges(): {
|
|
30
|
+
start: number;
|
|
31
|
+
count: number;
|
|
32
|
+
}[];
|
|
33
|
+
/**
|
|
34
|
+
* Adds an update range.
|
|
35
|
+
*
|
|
36
|
+
* @param {number} start - The start index.
|
|
37
|
+
* @param {number} count - The number of elements.
|
|
38
|
+
*/
|
|
39
|
+
addUpdateRange(start: number, count: number): void;
|
|
40
|
+
/**
|
|
41
|
+
* Clears all update ranges.
|
|
42
|
+
*/
|
|
43
|
+
clearUpdateRanges(): void;
|
|
20
44
|
/**
|
|
21
45
|
* The buffer's byte length.
|
|
22
46
|
*
|