@zephyr3d/scene 0.7.1 → 0.8.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.
Files changed (74) hide show
  1. package/dist/animation/animation.js +0 -18
  2. package/dist/animation/animation.js.map +1 -1
  3. package/dist/animation/animationset.js +2 -2
  4. package/dist/animation/animationset.js.map +1 -1
  5. package/dist/animation/ik/ccd_solver.js +372 -0
  6. package/dist/animation/ik/ccd_solver.js.map +1 -0
  7. package/dist/animation/ik/fabrik_solver.js +399 -0
  8. package/dist/animation/ik/fabrik_solver.js.map +1 -0
  9. package/dist/animation/ik/ik_angle_constraint.js +181 -0
  10. package/dist/animation/ik/ik_angle_constraint.js.map +1 -0
  11. package/dist/animation/ik/ik_chain.js +163 -0
  12. package/dist/animation/ik/ik_chain.js.map +1 -0
  13. package/dist/animation/ik/ik_chain_builder.js +68 -0
  14. package/dist/animation/ik/ik_chain_builder.js.map +1 -0
  15. package/dist/animation/ik/ik_constraint.js +25 -0
  16. package/dist/animation/ik/ik_constraint.js.map +1 -0
  17. package/dist/animation/ik/ik_pole_constraint.js +123 -0
  18. package/dist/animation/ik/ik_pole_constraint.js.map +1 -0
  19. package/dist/animation/ik/ik_solver.js +48 -0
  20. package/dist/animation/ik/ik_solver.js.map +1 -0
  21. package/dist/animation/ik/ik_track.js +96 -0
  22. package/dist/animation/ik/ik_track.js.map +1 -0
  23. package/dist/animation/ik/ik_utils.js +270 -0
  24. package/dist/animation/ik/ik_utils.js.map +1 -0
  25. package/dist/animation/ik/two_bone_ik_solver.js +332 -0
  26. package/dist/animation/ik/two_bone_ik_solver.js.map +1 -0
  27. package/dist/animation/ik_modifier.js +61 -0
  28. package/dist/animation/ik_modifier.js.map +1 -0
  29. package/dist/animation/ik_postprocessor.js +71 -0
  30. package/dist/animation/ik_postprocessor.js.map +1 -0
  31. package/dist/animation/manual_transform_processor.js +156 -0
  32. package/dist/animation/manual_transform_processor.js.map +1 -0
  33. package/dist/animation/skeleton.js +55 -51
  34. package/dist/animation/skeleton.js.map +1 -1
  35. package/dist/animation/skeleton_modifier.js +38 -0
  36. package/dist/animation/skeleton_modifier.js.map +1 -0
  37. package/dist/animation/skeleton_postprocessor.js +50 -0
  38. package/dist/animation/skeleton_postprocessor.js.map +1 -0
  39. package/dist/animation/spring/multi_chain_spring_system.js +503 -0
  40. package/dist/animation/spring/multi_chain_spring_system.js.map +1 -0
  41. package/dist/animation/spring/spring_chain.js +103 -0
  42. package/dist/animation/spring/spring_chain.js.map +1 -0
  43. package/dist/animation/spring/spring_collider.js +247 -0
  44. package/dist/animation/spring/spring_collider.js.map +1 -0
  45. package/dist/animation/spring/spring_constraint.js +21 -0
  46. package/dist/animation/spring/spring_constraint.js.map +1 -0
  47. package/dist/animation/spring/spring_particle.js +20 -0
  48. package/dist/animation/spring/spring_particle.js.map +1 -0
  49. package/dist/animation/spring/spring_system.js +526 -0
  50. package/dist/animation/spring/spring_system.js.map +1 -0
  51. package/dist/animation/spring_modifier.js +45 -0
  52. package/dist/animation/spring_modifier.js.map +1 -0
  53. package/dist/animation/spring_postprocessor.js +54 -0
  54. package/dist/animation/spring_postprocessor.js.map +1 -0
  55. package/dist/app/screen.js +1 -1
  56. package/dist/app/screen.js.map +1 -1
  57. package/dist/asset/model.js +8 -4
  58. package/dist/asset/model.js.map +1 -1
  59. package/dist/camera/perspectivecamera.js +3 -3
  60. package/dist/camera/perspectivecamera.js.map +1 -1
  61. package/dist/index.d.ts +1385 -4
  62. package/dist/index.js +16 -0
  63. package/dist/index.js.map +1 -1
  64. package/dist/material/mixins/lightmodel/blinnphong.js +66 -4
  65. package/dist/material/mixins/lightmodel/blinnphong.js.map +1 -1
  66. package/dist/material/shader/helper.js +5 -3
  67. package/dist/material/shader/helper.js.map +1 -1
  68. package/dist/scene/mesh.js +15 -23
  69. package/dist/scene/mesh.js.map +1 -1
  70. package/dist/utility/serialization/scene/animation.js +21 -20
  71. package/dist/utility/serialization/scene/animation.js.map +1 -1
  72. package/dist/utility/serialization/scene/material.js +62 -0
  73. package/dist/utility/serialization/scene/material.js.map +1 -1
  74. package/package.json +2 -2
package/dist/index.d.ts CHANGED
@@ -2229,6 +2229,9 @@ declare class LambertMaterial extends LambertMaterial_base implements Clonable<L
2229
2229
  */
2230
2230
  type IMixinBlinnPhong = {
2231
2231
  shininess: number;
2232
+ scatterWrap: number;
2233
+ scatterWidth: number;
2234
+ scatterColor: Vector4;
2232
2235
  blinnPhongLight(scope: PBInsideFunctionScope, worldPos: PBShaderExp, normal: PBShaderExp, viewVec: PBShaderExp, albedo: PBShaderExp, outRoughness?: PBShaderExp): PBShaderExp;
2233
2236
  } & IMixinLight;
2234
2237
  /**
@@ -4919,7 +4922,11 @@ declare class AssetSkeleton extends NamedObject {
4919
4922
  /** Inverse of the binding matrices of the joints */
4920
4923
  inverseBindMatrices: Matrix4x4[];
4921
4924
  /** Binding pose matrices of the joints */
4922
- bindPoseMatrices: Matrix4x4[];
4925
+ bindPose: {
4926
+ position: Vector3;
4927
+ rotation: Quaternion;
4928
+ scale: Vector3;
4929
+ }[];
4923
4930
  /**
4924
4931
  * Creates an instance of AssetSkeleton
4925
4932
  * @param name - Name of the skeleton
@@ -12092,6 +12099,55 @@ declare class Scene extends Scene_base implements IRenderable {
12092
12099
  protected onDispose(): void;
12093
12100
  }
12094
12101
 
12102
+ /**
12103
+ * Abstract base class for skeleton post-processors.
12104
+ *
12105
+ * Post-processors are applied after the base animation/bind pose layer,
12106
+ * allowing procedural modifications like IK, spring physics, or manual overrides.
12107
+ *
12108
+ * @public
12109
+ */
12110
+ declare abstract class SkeletonModifier {
12111
+ /** Blend weight for this processor [0-1] */
12112
+ protected _weight: number;
12113
+ /** Whether this processor is enabled */
12114
+ protected _enabled: boolean;
12115
+ constructor(weight?: number);
12116
+ /**
12117
+ * Get the blend weight [0-1]
12118
+ */
12119
+ get weight(): number;
12120
+ /**
12121
+ * Set the blend weight [0-1]
12122
+ */
12123
+ set weight(value: number);
12124
+ /**
12125
+ * Get whether this processor is enabled
12126
+ */
12127
+ get enabled(): boolean;
12128
+ /**
12129
+ * Set whether this processor is enabled
12130
+ */
12131
+ set enabled(value: boolean);
12132
+ /**
12133
+ * Apply post-processing to skeleton joints.
12134
+ *
12135
+ * This method is called after the base animation/bind pose has been applied.
12136
+ * Implementations should modify joint transforms and blend with the current state
12137
+ * using the processor's weight.
12138
+ *
12139
+ * @param skeleton - The skeleton to process
12140
+ * @param deltaTime - Time elapsed since last frame (in seconds)
12141
+ */
12142
+ abstract apply(skeleton: Skeleton, deltaTime: number): void;
12143
+ /**
12144
+ * Reset the processor to its initial state.
12145
+ *
12146
+ * Called when the skeleton or animation state changes significantly.
12147
+ */
12148
+ abstract reset(): void;
12149
+ }
12150
+
12095
12151
  /**
12096
12152
  * Skinned bounding box information for a submesh.
12097
12153
  *
@@ -12149,9 +12205,9 @@ declare class Skeleton extends Disposable {
12149
12205
  * @param inverseBindMatrices - Inverse bind matrices for each joint.
12150
12206
  * @param bindPoseMatrices - Bind pose matrices for each joint (model-space).
12151
12207
  */
12152
- constructor(joints: SceneNode[], inverseBindMatrices: Matrix4x4[], bindPoseMatrices: Matrix4x4[], jointTransforms?: {
12153
- scale: Vector3;
12208
+ constructor(joints: SceneNode[], inverseBindMatrices: Matrix4x4[], bindPose: {
12154
12209
  rotation: Quaternion;
12210
+ scale: Vector3;
12155
12211
  position: Vector3;
12156
12212
  }[]);
12157
12213
  set playing(b: boolean);
@@ -12162,6 +12218,24 @@ declare class Skeleton extends Disposable {
12162
12218
  * Each matrix is stored in 4 texels (one row per texel, RGBA = 4 floats).
12163
12219
  */
12164
12220
  get jointTexture(): Texture2D<unknown>;
12221
+ /**
12222
+ * Get joint index by joint node
12223
+ * @param joint - joint node
12224
+ * @returns The index of the joint
12225
+ */
12226
+ getJointIndex(joint: SceneNode): number;
12227
+ /**
12228
+ * Get joint index by joint name
12229
+ * @param jointName - joint name
12230
+ * @returns The index of the joint
12231
+ */
12232
+ getJointIndexByName(jointName: string): number;
12233
+ /**
12234
+ * Get all modifiers attached to this skeleton.
12235
+ *
12236
+ * @public
12237
+ */
12238
+ get modifiers(): SkeletonModifier[];
12165
12239
  /**
12166
12240
  * Dispose GPU resources and references held by the skeleton.
12167
12241
  *
@@ -12875,6 +12949,1313 @@ declare class MorphTargetTrack extends AnimationTrack<MorphState> {
12875
12949
  reset(node: SceneNode): void;
12876
12950
  }
12877
12951
 
12952
+ /**
12953
+ * Represents a joint in an IK chain.
12954
+ *
12955
+ * @public
12956
+ */
12957
+ interface IKJoint {
12958
+ /** The scene node associated with this joint */
12959
+ node: SceneNode;
12960
+ /** Current position in world space (updated during solving) */
12961
+ position: Vector3;
12962
+ /** Original position before solving (for reference) */
12963
+ originalPosition: Vector3;
12964
+ /** Current rotation in world space */
12965
+ rotation: Quaternion;
12966
+ /** Original rotation before solving (for reference) */
12967
+ originalRotation: Quaternion;
12968
+ /** Length of the bone from this joint to the next (0 for end effector) */
12969
+ boneLength: number;
12970
+ /** Previous IK world rotation (for twist continuity across frames) */
12971
+ previousIKRotation?: Quaternion;
12972
+ /** Previous twist angle in radians (for twist smoothing) */
12973
+ previousTwist?: number;
12974
+ }
12975
+
12976
+ /**
12977
+ * Base class for IK constraints.
12978
+ *
12979
+ * Constraints are applied after each FABRIK iteration to enforce
12980
+ * joint limitations (angle limits, pole vectors, etc.).
12981
+ *
12982
+ * @public
12983
+ */
12984
+ declare abstract class IKConstraint {
12985
+ /** The joint index this constraint applies to */
12986
+ protected _jointIndex: number;
12987
+ /**
12988
+ * Create an IK constraint.
12989
+ *
12990
+ * @param jointIndex - Index of the joint in the chain (0 = root)
12991
+ */
12992
+ constructor(jointIndex: number);
12993
+ /**
12994
+ * Get the joint index this constraint applies to.
12995
+ */
12996
+ get jointIndex(): number;
12997
+ /**
12998
+ * Apply the constraint to the joint chain.
12999
+ *
13000
+ * This method modifies joint positions to satisfy the constraint.
13001
+ *
13002
+ * @param joints - Array of all joints in the chain
13003
+ */
13004
+ abstract apply(joints: IKJoint[]): void;
13005
+ }
13006
+ /**
13007
+ * Twist constraint configuration for a joint.
13008
+ *
13009
+ * @public
13010
+ */
13011
+ interface TwistConstraint {
13012
+ /** Minimum twist angle in radians */
13013
+ minTwist: number;
13014
+ /** Maximum twist angle in radians */
13015
+ maxTwist: number;
13016
+ /** Smoothing factor [0-1], 0 = no smoothing, 1 = full smoothing */
13017
+ smoothFactor: number;
13018
+ }
13019
+
13020
+ /**
13021
+ * Represents a chain of joints for IK solving.
13022
+ *
13023
+ * @public
13024
+ */
13025
+ declare class IKChain {
13026
+ /** Array of joints in the chain (root to end effector) */
13027
+ private _joints;
13028
+ /** Total length of the chain */
13029
+ private _totalLength;
13030
+ /** Constraints applied to joints */
13031
+ private _constraints;
13032
+ /**
13033
+ * Create an IK chain from an array of scene nodes.
13034
+ *
13035
+ * @param nodes - Array of scene nodes from root to end effector
13036
+ */
13037
+ constructor(nodes: SceneNode[]);
13038
+ /**
13039
+ * Create an IK chain by traversing from a start node to an end node.
13040
+ *
13041
+ * @remarks
13042
+ * This method walks up the parent chain from the end node until it
13043
+ * reaches the start node, building the joint chain in the process.
13044
+ *
13045
+ * @param startNode - The root joint of the chain
13046
+ * @param endNode - The end effector joint
13047
+ * @returns The created IK chain
13048
+ */
13049
+ static fromNodeHierarchy(startNode: SceneNode, endNode: SceneNode): IKChain;
13050
+ /**
13051
+ * Get all joints in the chain.
13052
+ */
13053
+ get joints(): IKJoint[];
13054
+ /**
13055
+ * Get the root joint (first joint in the chain).
13056
+ */
13057
+ get root(): IKJoint;
13058
+ /**
13059
+ * Get the end effector (last joint in the chain).
13060
+ */
13061
+ get endEffector(): IKJoint;
13062
+ /**
13063
+ * Get the total length of the chain.
13064
+ */
13065
+ get totalLength(): number;
13066
+ /**
13067
+ * Get the number of joints in the chain.
13068
+ */
13069
+ get length(): number;
13070
+ /**
13071
+ * Update joint positions from their scene nodes.
13072
+ */
13073
+ updateFromNodes(): void;
13074
+ /**
13075
+ * Store current positions as original positions.
13076
+ */
13077
+ storeOriginalPositions(): void;
13078
+ /**
13079
+ * Restore joints to their original positions.
13080
+ */
13081
+ restoreOriginalPositions(): void;
13082
+ /**
13083
+ * Add a constraint to a specific joint.
13084
+ *
13085
+ * @param constraint - The constraint to add
13086
+ */
13087
+ addConstraint(constraint: IKConstraint): void;
13088
+ /**
13089
+ * Remove a constraint from the chain.
13090
+ *
13091
+ * @param constraint - The constraint to remove
13092
+ * @returns True if the constraint was found and removed
13093
+ */
13094
+ removeConstraint(constraint: IKConstraint): boolean;
13095
+ /**
13096
+ * Clear all constraints from the chain.
13097
+ */
13098
+ clearConstraints(): void;
13099
+ /**
13100
+ * Get all constraints in the chain.
13101
+ */
13102
+ get constraints(): readonly IKConstraint[];
13103
+ /**
13104
+ * Apply all constraints to the joint chain.
13105
+ */
13106
+ applyConstraints(): void;
13107
+ }
13108
+
13109
+ /**
13110
+ * Base class for IK solvers.
13111
+ *
13112
+ * @public
13113
+ */
13114
+ declare abstract class IKSolver {
13115
+ /** The IK chain to solve */
13116
+ protected _chain: IKChain;
13117
+ /** Maximum number of iterations */
13118
+ protected _maxIterations: number;
13119
+ /** Convergence tolerance (distance threshold) */
13120
+ protected _tolerance: number;
13121
+ /**
13122
+ * Create an IK solver.
13123
+ *
13124
+ * @param chain - The IK chain to solve
13125
+ * @param maxIterations - Maximum number of iterations (default: 10)
13126
+ * @param tolerance - Convergence tolerance in world units (default: 0.001)
13127
+ */
13128
+ constructor(chain: IKChain, maxIterations?: number, tolerance?: number);
13129
+ /**
13130
+ * Get the IK chain.
13131
+ */
13132
+ get chain(): IKChain;
13133
+ /**
13134
+ * Set maximum number of iterations.
13135
+ */
13136
+ setMaxIterations(value: number): void;
13137
+ /**
13138
+ * Get maximum number of iterations.
13139
+ */
13140
+ getMaxIterations(): number;
13141
+ /**
13142
+ * Set convergence tolerance.
13143
+ */
13144
+ setTolerance(value: number): void;
13145
+ /**
13146
+ * Get convergence tolerance.
13147
+ */
13148
+ getTolerance(): number;
13149
+ /**
13150
+ * Solve the IK chain to reach the target position.
13151
+ *
13152
+ * @param target - Target position for the end effector
13153
+ * @returns True if converged, false otherwise
13154
+ */
13155
+ abstract solve(target: Vector3): boolean;
13156
+ /**
13157
+ * Apply the solved positions to the scene nodes as rotations.
13158
+ *
13159
+ * @param weight - Blend weight (0 = original, 1 = full IK)
13160
+ */
13161
+ abstract applyToNodes(weight?: number): void;
13162
+ }
13163
+
13164
+ /**
13165
+ * Skeleton modifier for IK solvers.
13166
+ *
13167
+ * Integrates IK solving into the skeleton post-processing pipeline.
13168
+ * The IK solver is executed each frame and results are blended with the base animation.
13169
+ *
13170
+ * @public
13171
+ */
13172
+ declare class IKModifier<Solver extends IKSolver = IKSolver> extends SkeletonModifier {
13173
+ private _solver;
13174
+ private _target;
13175
+ /**
13176
+ * Create an IK post-processor.
13177
+ *
13178
+ * @param solver - The IK solver to integrate
13179
+ * @param target - Target position for the end effector
13180
+ * @param weight - Blend weight [0-1] (default: 1.0)
13181
+ */
13182
+ constructor(solver: Solver, target: Vector3, weight?: number);
13183
+ /**
13184
+ * Get the IK solver.
13185
+ */
13186
+ get solver(): Solver;
13187
+ /**
13188
+ * Get the current target position.
13189
+ */
13190
+ get target(): Vector3;
13191
+ /**
13192
+ * Set the target position for the end effector.
13193
+ *
13194
+ * @param target - New target position (will be cloned)
13195
+ */
13196
+ setTarget(target: Vector3): void;
13197
+ /**
13198
+ * Apply IK solving to skeleton joints.
13199
+ */
13200
+ apply(_skeleton: Skeleton, _deltaTime: number): void;
13201
+ /**
13202
+ * Reset the IK solver to initial state.
13203
+ */
13204
+ reset(): void;
13205
+ }
13206
+
13207
+ /**
13208
+ * Represents a particle in the spring system
13209
+ *
13210
+ * @public
13211
+ */
13212
+ interface SpringParticle {
13213
+ /** Current position in world space */
13214
+ position: Vector3;
13215
+ /** Previous position for Verlet integration */
13216
+ prevPosition: Vector3;
13217
+ /** Original position for reset */
13218
+ originalPosition: Vector3;
13219
+ /** Original world rotation (for calculating rotation delta) */
13220
+ originalRotation: Quaternion | null;
13221
+ /** Mass of the particle (affects inertia) */
13222
+ mass: number;
13223
+ /** Damping coefficient [0-1] (0 = no damping, 1 = full damping) */
13224
+ damping: number;
13225
+ /** Whether this particle is fixed (anchor point) */
13226
+ fixed: boolean;
13227
+ /** Associated scene node (optional) */
13228
+ node: Nullable<SceneNode>;
13229
+ /** Previous frame position (used to calculate velocity for inertial forces) */
13230
+ lastFramePosition: Vector3;
13231
+ /** Position history for rotation center estimation (for fixed particles) */
13232
+ positionHistory?: Vector3[];
13233
+ }
13234
+ /**
13235
+ * Creates a new spring particle
13236
+ *
13237
+ * @public
13238
+ */
13239
+ declare function createSpringParticle(position: Vector3, options?: {
13240
+ mass?: number;
13241
+ damping?: number;
13242
+ fixed?: boolean;
13243
+ node?: SceneNode;
13244
+ originalRotation?: Quaternion;
13245
+ }): SpringParticle;
13246
+
13247
+ /**
13248
+ * Represents a spring constraint between two particles
13249
+ *
13250
+ * @public
13251
+ */
13252
+ interface SpringConstraint {
13253
+ /** Index of the first particle */
13254
+ particleA: number;
13255
+ /** Index of the second particle */
13256
+ particleB: number;
13257
+ /** Rest length of the spring */
13258
+ restLength: number;
13259
+ /** Stiffness coefficient [0-1] used by Verlet solver (0 = no constraint, 1 = rigid) */
13260
+ stiffness: number;
13261
+ /**
13262
+ * XPBD compliance (inverse stiffness) in m/N.
13263
+ * 0 = perfectly rigid, larger values = softer spring.
13264
+ * Typical ranges: 0 (rigid) ~ 1e-7 (very stiff) ~ 1e-3 (soft cloth) ~ 1e-1 (rubber band).
13265
+ * Only used when solver is 'xpbd'.
13266
+ */
13267
+ compliance: number;
13268
+ /**
13269
+ * XPBD Lagrange multiplier accumulator, reset to 0 at the start of each time step.
13270
+ * Managed internally by the solver — do not set manually.
13271
+ */
13272
+ lambda: number;
13273
+ }
13274
+ /**
13275
+ * Creates a new spring constraint
13276
+ *
13277
+ * @public
13278
+ */
13279
+ declare function createSpringConstraint(particleA: number, particleB: number, restLength: number, stiffness?: number, compliance?: number): SpringConstraint;
13280
+
13281
+ /**
13282
+ * Manages a chain of spring particles and constraints
13283
+ *
13284
+ * @public
13285
+ */
13286
+ declare class SpringChain {
13287
+ /** Array of particles in the chain */
13288
+ particles: SpringParticle[];
13289
+ /** Array of constraints between particles */
13290
+ constraints: SpringConstraint[];
13291
+ constructor();
13292
+ /**
13293
+ * Creates a spring chain from a bone hierarchy
13294
+ * @param startNode - Root node of the bone chain
13295
+ * @param endNode - End node of the bone chain (optional, if null uses all descendants)
13296
+ * @param options - Additional options
13297
+ * @returns A new SpringChain instance
13298
+ */
13299
+ static fromBoneChain(startNode: SceneNode, endNode?: SceneNode | null, options?: {
13300
+ mass?: number;
13301
+ damping?: number;
13302
+ stiffness?: number;
13303
+ }): SpringChain;
13304
+ /**
13305
+ * Adds a particle to the chain
13306
+ * @param particle - The particle to add
13307
+ * @returns The index of the added particle
13308
+ */
13309
+ addParticle(particle: SpringParticle): number;
13310
+ /**
13311
+ * Adds a constraint to the chain
13312
+ * @param constraint - The constraint to add
13313
+ */
13314
+ addConstraint(constraint: SpringConstraint): void;
13315
+ /**
13316
+ * Adds cross constraints between particles for cloth-like behavior
13317
+ * @param stiffness - Stiffness of the cross constraints
13318
+ * @param skipDistance - Distance between particles to connect (default: 2)
13319
+ */
13320
+ addCrossConstraints(stiffness?: number, skipDistance?: number): void;
13321
+ /**
13322
+ * Resets all particles to their original positions
13323
+ */
13324
+ reset(): void;
13325
+ }
13326
+
13327
+ /**
13328
+ * Base interface for spring collision shapes
13329
+ *
13330
+ * @public
13331
+ */
13332
+ interface SpringCollider {
13333
+ /** Type of collider */
13334
+ type: 'sphere' | 'capsule' | 'plane';
13335
+ /** Associated scene node (optional, for dynamic colliders) */
13336
+ node?: Nullable<SceneNode>;
13337
+ /** Whether this collider is enabled */
13338
+ enabled: boolean;
13339
+ }
13340
+ /**
13341
+ * Sphere collider for spring collision detection
13342
+ *
13343
+ * @public
13344
+ */
13345
+ interface SphereCollider extends SpringCollider {
13346
+ type: 'sphere';
13347
+ /** Center position in world space */
13348
+ center: Vector3;
13349
+ /** Radius of the sphere */
13350
+ radius: number;
13351
+ /** Local offset from node (if node is set) */
13352
+ localOffset?: Vector3;
13353
+ }
13354
+ /**
13355
+ * Capsule collider for spring collision detection
13356
+ *
13357
+ * @public
13358
+ */
13359
+ interface CapsuleCollider extends SpringCollider {
13360
+ type: 'capsule';
13361
+ /** Start point of the capsule axis in world space */
13362
+ start: Vector3;
13363
+ /** End point of the capsule axis in world space */
13364
+ end: Vector3;
13365
+ /** Radius of the capsule */
13366
+ radius: number;
13367
+ /** Local start offset from node (if node is set) */
13368
+ localStartOffset?: Vector3;
13369
+ /** Local end offset from node (if node is set) */
13370
+ localEndOffset?: Vector3;
13371
+ }
13372
+ /**
13373
+ * Plane collider for spring collision detection
13374
+ *
13375
+ * @public
13376
+ */
13377
+ interface PlaneCollider extends SpringCollider {
13378
+ type: 'plane';
13379
+ /** Point on the plane in world space */
13380
+ point: Vector3;
13381
+ /** Normal vector of the plane (should be normalized) */
13382
+ normal: Vector3;
13383
+ /** Local point offset from node (if node is set) */
13384
+ localPointOffset?: Vector3;
13385
+ /** Local normal direction (if node is set) */
13386
+ localNormal?: Vector3;
13387
+ }
13388
+ /**
13389
+ * Creates a sphere collider
13390
+ * @param centerOrOffset - Center position in world space, or local offset if node is provided
13391
+ * @param radius - Radius of the sphere
13392
+ * @param node - Optional scene node to attach to (if provided, centerOrOffset is treated as local offset)
13393
+ *
13394
+ * @public
13395
+ */
13396
+ declare function createSphereCollider(centerOrOffset: Vector3, radius: number, node?: SceneNode): SphereCollider;
13397
+ /**
13398
+ * Creates a capsule collider
13399
+ * @param startOrOffset - Start point in world space, or local offset if node is provided
13400
+ * @param endOrOffset - End point in world space, or local offset if node is provided
13401
+ * @param radius - Radius of the capsule
13402
+ * @param node - Optional scene node to attach to (if provided, offsets are treated as local)
13403
+ *
13404
+ * @public
13405
+ */
13406
+ declare function createCapsuleCollider(startOrOffset: Vector3, endOrOffset: Vector3, radius: number, node?: SceneNode): CapsuleCollider;
13407
+ /**
13408
+ * Creates a plane collider
13409
+ * @param pointOrOffset - Point on plane in world space, or local offset if node is provided
13410
+ * @param normal - Normal vector (will be normalized)
13411
+ * @param node - Optional scene node to attach to (if provided, pointOrOffset is treated as local offset)
13412
+ *
13413
+ * @public
13414
+ */
13415
+ declare function createPlaneCollider(pointOrOffset: Vector3, normal: Vector3, node?: SceneNode): PlaneCollider;
13416
+ /**
13417
+ * Resolves collision between a particle and a sphere collider
13418
+ * @returns true if collision occurred
13419
+ *
13420
+ * @public
13421
+ */
13422
+ declare function resolveSphereCollision(particlePos: Vector3, collider: SphereCollider): boolean;
13423
+ /**
13424
+ * Resolves collision between a particle and a capsule collider
13425
+ * @returns true if collision occurred
13426
+ *
13427
+ * @public
13428
+ */
13429
+ declare function resolveCapsuleCollision(particlePos: Vector3, collider: CapsuleCollider): boolean;
13430
+ /**
13431
+ * Resolves collision between a particle and a plane collider
13432
+ * @returns true if collision occurred
13433
+ *
13434
+ * @public
13435
+ */
13436
+ declare function resolvePlaneCollision(particlePos: Vector3, collider: PlaneCollider): boolean;
13437
+ /**
13438
+ * Updates collider position from its associated node
13439
+ *
13440
+ * @public
13441
+ */
13442
+ declare function updateColliderFromNode(collider: SpringCollider): void;
13443
+
13444
+ /**
13445
+ * Options for creating a SpringSystem
13446
+ *
13447
+ * @public
13448
+ */
13449
+ interface SpringSystemOptions {
13450
+ /** Number of constraint solver iterations (default: 5) */
13451
+ iterations?: number;
13452
+ /** Gravity force vector (default: (0, -9.8, 0)) */
13453
+ gravity?: Vector3;
13454
+ /** Wind force vector (default: (0, 0, 0)) */
13455
+ wind?: Vector3;
13456
+ /** Enable inertial forces (centrifugal/Coriolis) when root rotates (default: true) */
13457
+ enableInertialForces?: boolean;
13458
+ /** Centrifugal force multiplier (default: 1.0) */
13459
+ centrifugalScale?: number;
13460
+ /** Coriolis force multiplier (default: 1.0) */
13461
+ coriolisScale?: number;
13462
+ /**
13463
+ * Constraint solver type (default: 'verlet').
13464
+ * - 'verlet': Classic Verlet integration with iterative position correction.
13465
+ * stiffness [0-1] controls correction strength per iteration.
13466
+ * - 'xpbd': Extended Position-Based Dynamics (Müller et al. 2020).
13467
+ * Uses compliance (inverse stiffness in m/N) for physically correct,
13468
+ * iteration-count-independent constraint solving.
13469
+ */
13470
+ solver?: 'verlet' | 'xpbd';
13471
+ }
13472
+ /**
13473
+ * Physics engine for spring-based particle simulation
13474
+ * Uses Verlet integration and iterative constraint solving
13475
+ *
13476
+ * @public
13477
+ */
13478
+ declare class SpringSystem {
13479
+ private _chain;
13480
+ private _iterations;
13481
+ private _gravity;
13482
+ private _wind;
13483
+ private _enableInertialForces;
13484
+ private _centrifugalScale;
13485
+ private _coriolisScale;
13486
+ private _colliders;
13487
+ private _solver;
13488
+ constructor(chain: SpringChain, options?: SpringSystemOptions);
13489
+ /**
13490
+ * Updates the physics simulation
13491
+ * @param deltaTime - Time step in seconds
13492
+ */
13493
+ update(deltaTime: number): void;
13494
+ /**
13495
+ * Updates fixed particles to match their scene node positions
13496
+ */
13497
+ private updateFixedParticles;
13498
+ /**
13499
+ * Calculates global rotation parameters from fixed particle movements
13500
+ * Uses position history to estimate rotation center
13501
+ */
13502
+ private calculateGlobalRotation;
13503
+ /**
13504
+ * Estimates rotation center from a single particle's position history
13505
+ * Uses circular motion fitting
13506
+ */
13507
+ private estimateRotationCenterFromHistory;
13508
+ /**
13509
+ * Calculates the center of a circle passing through 3 points
13510
+ * Uses perpendicular bisector method
13511
+ */
13512
+ private calculateCircleCenter;
13513
+ /**
13514
+ * Calculates inertial acceleration for a particle in a rotating reference frame
13515
+ */
13516
+ private calculateInertialAcceleration;
13517
+ /**
13518
+ * Solves a single spring constraint using XPBD (Extended Position-Based Dynamics).
13519
+ *
13520
+ * Reference: Müller et al., "Detailed Rigid Body Simulation with Extended Position Based Dynamics", 2020.
13521
+ *
13522
+ * The XPBD correction for a distance constraint C(x) = |x_b - x_a| - L is:
13523
+ * α̃ = compliance / dt² (scaled compliance)
13524
+ * Δλ = (-C - α̃·λ) / (w_a + w_b + α̃)
13525
+ * λ += Δλ
13526
+ * Δx_a = -w_a · Δλ · n̂
13527
+ * Δx_b = +w_b · Δλ · n̂
13528
+ * where w = 1/mass (0 for fixed particles), n̂ = unit vector from a to b.
13529
+ */
13530
+ private solveConstraintXPBD;
13531
+ /**
13532
+ * Solves a single spring constraint (Verlet / PBD)
13533
+ */
13534
+ private solveConstraint;
13535
+ /**
13536
+ * Solves collisions for all particles
13537
+ */
13538
+ private solveCollisions;
13539
+ /**
13540
+ * Applies simulation results to scene nodes
13541
+ * @param weight - Blend weight [0-1] (default: 1.0)
13542
+ */
13543
+ applyToNodes(weight?: number): void;
13544
+ /**
13545
+ * Resets the simulation to initial state
13546
+ */
13547
+ reset(): void;
13548
+ /**
13549
+ * Gets the spring chain
13550
+ */
13551
+ get chain(): SpringChain;
13552
+ /**
13553
+ * Gets the current gravity
13554
+ */
13555
+ get gravity(): Vector3;
13556
+ set gravity(gravity: Vector3);
13557
+ /**
13558
+ * Gets the current wind
13559
+ */
13560
+ get wind(): Vector3;
13561
+ set wind(wind: Vector3);
13562
+ /**
13563
+ * Gets the number of iterations
13564
+ */
13565
+ get iterations(): number;
13566
+ set iterations(count: number);
13567
+ /**
13568
+ * Gets whether inertial forces are enabled
13569
+ */
13570
+ get enableInertialForces(): boolean;
13571
+ set enableInertialForces(enabled: boolean);
13572
+ /**
13573
+ * Gets the centrifugal force scale
13574
+ */
13575
+ get centrifugalScale(): number;
13576
+ set centrifugalScale(scale: number);
13577
+ /**
13578
+ * Gets the Coriolis force scale
13579
+ */
13580
+ get coriolisScale(): number;
13581
+ /**
13582
+ * Sets the Coriolis force scale
13583
+ */
13584
+ set coriolisScale(scale: number);
13585
+ /**
13586
+ * Gets the constraint solver type
13587
+ */
13588
+ get solver(): 'verlet' | 'xpbd';
13589
+ /**
13590
+ * Sets the constraint solver type.
13591
+ * Switching to 'xpbd' resets all Lagrange multipliers.
13592
+ */
13593
+ set solver(type: 'verlet' | 'xpbd');
13594
+ /**
13595
+ * Adds a collider to the system
13596
+ */
13597
+ addCollider(collider: SpringCollider): void;
13598
+ /**
13599
+ * Removes a collider from the system
13600
+ */
13601
+ removeCollider(collider: SpringCollider): boolean;
13602
+ /**
13603
+ * Clears all colliders
13604
+ */
13605
+ clearColliders(): void;
13606
+ /**
13607
+ * Gets all colliders
13608
+ */
13609
+ get colliders(): SpringCollider[];
13610
+ }
13611
+
13612
+ /**
13613
+ * Post-processor wrapper for spring physics systems.
13614
+ *
13615
+ * Integrates spring-based physics simulation into the skeleton post-processing pipeline.
13616
+ * The spring system is updated each frame and results are blended with the base animation.
13617
+ *
13618
+ * @public
13619
+ */
13620
+ declare class SpringModifier extends SkeletonModifier {
13621
+ private _springSystem;
13622
+ /**
13623
+ * Create a spring post-processor.
13624
+ *
13625
+ * @param springSystem - The spring system to integrate
13626
+ * @param weight - Blend weight [0-1] (default: 1.0)
13627
+ */
13628
+ constructor(springSystem: SpringSystem, weight?: number);
13629
+ /**
13630
+ * Get the spring system.
13631
+ */
13632
+ get springSystem(): SpringSystem;
13633
+ /**
13634
+ * Apply spring physics to skeleton joints.
13635
+ */
13636
+ apply(_skeleton: Skeleton, deltaTime: number): void;
13637
+ /**
13638
+ * Reset the spring system to initial state.
13639
+ */
13640
+ reset(): void;
13641
+ }
13642
+
13643
+ /**
13644
+ * FABRIK (Forward And Backward Reaching Inverse Kinematics) solver.
13645
+ *
13646
+ * @remarks
13647
+ * FABRIK is an iterative IK algorithm that alternates between:
13648
+ * 1. Forward pass: Move from end effector to root, pulling joints toward target
13649
+ * 2. Backward pass: Move from root to end effector, restoring root position
13650
+ *
13651
+ * Supports multiple pole vectors to control the bending direction of different joints.
13652
+ *
13653
+ * @public
13654
+ */
13655
+ declare class FABRIKSolver extends IKSolver {
13656
+ /** Map of joint index to pole vector configuration */
13657
+ private _poleVectors;
13658
+ /** Twist constraints for each joint (indexed by joint index) */
13659
+ private _twistConstraints;
13660
+ /**
13661
+ * Create a FABRIK solver.
13662
+ *
13663
+ * @param chain - The IK chain to solve
13664
+ * @param maxIterations - Maximum number of iterations (default: 15)
13665
+ * @param tolerance - Convergence tolerance in world units (default: 0.001)
13666
+ */
13667
+ constructor(chain: IKChain, maxIterations?: number, tolerance?: number);
13668
+ /**
13669
+ * Set twist constraint for a specific joint.
13670
+ *
13671
+ * @param jointIndex - Index of the joint
13672
+ * @param minTwist - Minimum twist angle in radians
13673
+ * @param maxTwist - Maximum twist angle in radians
13674
+ * @param smoothFactor - Smoothing factor [0-1] (default: 0.3)
13675
+ */
13676
+ setTwistConstraint(jointIndex: number, minTwist: number, maxTwist: number, smoothFactor?: number): void;
13677
+ /**
13678
+ * Get twist constraint for a specific joint.
13679
+ *
13680
+ * @param jointIndex - Index of the joint
13681
+ * @returns Twist constraint or undefined if not set
13682
+ */
13683
+ getTwistConstraint(jointIndex: number): TwistConstraint | undefined;
13684
+ /**
13685
+ * Remove twist constraint for a specific joint.
13686
+ *
13687
+ * @param jointIndex - Index of the joint
13688
+ * @returns True if a constraint was removed
13689
+ */
13690
+ removeTwistConstraint(jointIndex: number): boolean;
13691
+ /**
13692
+ * Clear all twist constraints.
13693
+ */
13694
+ clearTwistConstraints(): void;
13695
+ /**
13696
+ * Set pole vector for a specific joint.
13697
+ *
13698
+ * @param jointIndex - Index of the joint to apply pole vector to
13699
+ * @param poleVector - Pole vector position in world space
13700
+ * @param weight - Weight of the pole vector constraint (0-1, default: 1)
13701
+ */
13702
+ setPoleVector(jointIndex: number, poleVector: Vector3, weight?: number): void;
13703
+ /**
13704
+ * Remove pole vector for a specific joint.
13705
+ *
13706
+ * @param jointIndex - Index of the joint to remove pole vector from
13707
+ * @returns True if a pole vector was removed, false if none existed
13708
+ */
13709
+ removePoleVector(jointIndex: number): boolean;
13710
+ /**
13711
+ * Clear all pole vectors.
13712
+ */
13713
+ clearPoleVectors(): void;
13714
+ /**
13715
+ * Get pole vector configuration for a specific joint.
13716
+ *
13717
+ * @param jointIndex - Index of the joint
13718
+ * @returns Pole vector configuration or undefined if not set
13719
+ */
13720
+ getPoleVector(jointIndex: number): {
13721
+ position: Vector3;
13722
+ weight: number;
13723
+ } | undefined;
13724
+ /**
13725
+ * Check if a joint has a pole vector.
13726
+ *
13727
+ * @param jointIndex - Index of the joint
13728
+ * @returns True if the joint has a pole vector
13729
+ */
13730
+ hasPoleVector(jointIndex: number): boolean;
13731
+ /**
13732
+ * Solve the IK chain to reach the target position using FABRIK algorithm.
13733
+ *
13734
+ * @param target - Target position for the end effector
13735
+ * @returns True if converged within tolerance, false otherwise
13736
+ */
13737
+ solve(target: Vector3): boolean;
13738
+ /**
13739
+ * Apply the solved joint positions to scene nodes as rotations.
13740
+ *
13741
+ * @param weight - Blend weight (0 = original, 1 = full IK, default: 1)
13742
+ */
13743
+ applyToNodes(weight?: number): void;
13744
+ /**
13745
+ * Forward pass: move from end effector toward root.
13746
+ * Each joint is pulled toward its child, maintaining bone length.
13747
+ * Constraints are applied immediately after each joint adjustment.
13748
+ *
13749
+ * @param target - Target position for end effector
13750
+ */
13751
+ private _forwardPass;
13752
+ /**
13753
+ * Backward pass: move from root toward end effector.
13754
+ * Each joint is pulled toward its parent, maintaining bone length.
13755
+ * Constraints are applied immediately after each joint adjustment.
13756
+ *
13757
+ * @param rootPos - Original root position to restore
13758
+ */
13759
+ private _backwardPass;
13760
+ /**
13761
+ * Apply constraints for a specific joint.
13762
+ * This is called during the FABRIK passes to integrate constraints into the algorithm.
13763
+ *
13764
+ * @param jointIndex - Index of the joint to apply constraints to
13765
+ */
13766
+ private _applyConstraintsForJoint;
13767
+ /**
13768
+ * Apply pole vector twist to a specific joint.
13769
+ *
13770
+ * @remarks
13771
+ * This method adjusts the joint position to align with the pole vector.
13772
+ * It uses the same algorithm as IKPoleVectorConstraint but is integrated
13773
+ * into the solver for better performance and control.
13774
+ *
13775
+ * @param jointIndex - Index of the pole joint
13776
+ * @param poleVector - Pole vector position in world space
13777
+ * @param weight - Weight of the pole vector constraint (0-1)
13778
+ */
13779
+ private _applyPoleVectorTwist;
13780
+ /**
13781
+ * Stretch the chain toward an unreachable target.
13782
+ * All joints are aligned in a straight line toward the target.
13783
+ *
13784
+ * @param target - Unreachable target position
13785
+ */
13786
+ private _stretchToward;
13787
+ }
13788
+
13789
+ /**
13790
+ * Two Bone IK solver for chains with exactly 3 joints (2 bones).
13791
+ *
13792
+ * @remarks
13793
+ * This solver uses an analytical solution specifically optimized for
13794
+ * two-bone chains like arms (shoulder-elbow-wrist) or legs (hip-knee-ankle).
13795
+ * It's faster and more stable than iterative methods like FABRIK for this case.
13796
+ *
13797
+ * The solver supports an optional pole vector to control the bending direction
13798
+ * of the middle joint (elbow/knee).
13799
+ *
13800
+ * @public
13801
+ */
13802
+ declare class TwoBoneIKSolver extends IKSolver {
13803
+ /** Optional pole vector position in world space */
13804
+ private _poleVector;
13805
+ /** Weight of the pole vector constraint (0-1) */
13806
+ private _poleWeight;
13807
+ /** Twist constraints for each joint (indexed by joint index) */
13808
+ private _twistConstraints;
13809
+ /**
13810
+ * Create a Two Bone IK solver.
13811
+ *
13812
+ * @param chain - The IK chain to solve (must have exactly 3 joints)
13813
+ * @param poleVector - Optional pole vector position in world space
13814
+ * @param poleWeight - Weight of the pole vector constraint (0-1, default: 1)
13815
+ */
13816
+ constructor(chain: IKChain, poleVector?: Vector3 | null, poleWeight?: number);
13817
+ /**
13818
+ * Set twist constraint for a specific joint.
13819
+ *
13820
+ * @param jointIndex - Index of the joint (0 = root, 1 = middle)
13821
+ * @param minTwist - Minimum twist angle in radians
13822
+ * @param maxTwist - Maximum twist angle in radians
13823
+ * @param smoothFactor - Smoothing factor [0-1] (default: 0.3)
13824
+ */
13825
+ setTwistConstraint(jointIndex: number, minTwist: number, maxTwist: number, smoothFactor?: number): void;
13826
+ /**
13827
+ * Get twist constraint for a specific joint.
13828
+ *
13829
+ * @param jointIndex - Index of the joint
13830
+ * @returns Twist constraint or undefined if not set
13831
+ */
13832
+ getTwistConstraint(jointIndex: number): TwistConstraint | undefined;
13833
+ /**
13834
+ * Remove twist constraint for a specific joint.
13835
+ *
13836
+ * @param jointIndex - Index of the joint
13837
+ * @returns True if a constraint was removed
13838
+ */
13839
+ removeTwistConstraint(jointIndex: number): boolean;
13840
+ /**
13841
+ * Clear all twist constraints.
13842
+ */
13843
+ clearTwistConstraints(): void;
13844
+ /**
13845
+ * Get the pole vector position.
13846
+ */
13847
+ get poleVector(): Vector3 | null;
13848
+ /**
13849
+ * Set the pole vector position.
13850
+ */
13851
+ set poleVector(value: Vector3 | null);
13852
+ /**
13853
+ * Get the pole vector weight.
13854
+ */
13855
+ get poleWeight(): number;
13856
+ /**
13857
+ * Set the pole vector weight (0-1).
13858
+ */
13859
+ set poleWeight(value: number);
13860
+ /**
13861
+ * Solve the IK chain to reach the target position using Two Bone IK algorithm.
13862
+ *
13863
+ * @param target - Target position for the end effector
13864
+ * @returns True if the target is reachable, false if stretched to maximum
13865
+ */
13866
+ solve(target: Vector3): boolean;
13867
+ /**
13868
+ * Apply all constraints to the joint chain.
13869
+ * After applying constraints, we need to restore bone lengths.
13870
+ */
13871
+ private _applyConstraints;
13872
+ /**
13873
+ * Restore bone lengths after constraints have been applied.
13874
+ * This ensures that the chain maintains correct bone lengths.
13875
+ */
13876
+ private _restoreBoneLengths;
13877
+ /**
13878
+ * Apply the solved joint positions to scene nodes as rotations.
13879
+ *
13880
+ * @param weight - Blend weight (0 = original, 1 = full IK, default: 1)
13881
+ */
13882
+ applyToNodes(weight?: number): void;
13883
+ /**
13884
+ * Get a default bend normal when no pole vector is specified.
13885
+ * This tries to find a reasonable perpendicular direction.
13886
+ *
13887
+ * @param rootToTarget - Direction from root to target
13888
+ * @returns A normalized perpendicular vector
13889
+ */
13890
+ private _getDefaultBendNormal;
13891
+ }
13892
+
13893
+ /**
13894
+ * CCD (Cyclic Coordinate Descent) IK solver.
13895
+ *
13896
+ * @remarks
13897
+ * CCD is an iterative IK algorithm that works by:
13898
+ * 1. Starting from the joint closest to the end effector
13899
+ * 2. Rotating each joint to point the end effector toward the target
13900
+ * 3. Moving backward through the chain to the root
13901
+ * 4. Repeating until convergence or max iterations
13902
+ *
13903
+ * CCD is generally faster than FABRIK and works well for chains of any length.
13904
+ * It's particularly good for tentacles, tails, and other flexible chains.
13905
+ *
13906
+ * Supports multiple pole vectors to control the bending direction of different joints.
13907
+ *
13908
+ * @public
13909
+ */
13910
+ declare class CCDSolver extends IKSolver {
13911
+ /** Map of joint index to pole vector configuration */
13912
+ private _poleVectors;
13913
+ /** Twist constraints for each joint (indexed by joint index) */
13914
+ private _twistConstraints;
13915
+ /**
13916
+ * Create a CCD solver.
13917
+ *
13918
+ * @param chain - The IK chain to solve
13919
+ * @param maxIterations - Maximum number of iterations (default: 10)
13920
+ * @param tolerance - Convergence tolerance in world units (default: 0.001)
13921
+ */
13922
+ constructor(chain: IKChain, maxIterations?: number, tolerance?: number);
13923
+ /**
13924
+ * Set twist constraint for a specific joint.
13925
+ *
13926
+ * @param jointIndex - Index of the joint
13927
+ * @param minTwist - Minimum twist angle in radians
13928
+ * @param maxTwist - Maximum twist angle in radians
13929
+ * @param smoothFactor - Smoothing factor [0-1] (default: 0.3)
13930
+ */
13931
+ setTwistConstraint(jointIndex: number, minTwist: number, maxTwist: number, smoothFactor?: number): void;
13932
+ /**
13933
+ * Get twist constraint for a specific joint.
13934
+ *
13935
+ * @param jointIndex - Index of the joint
13936
+ * @returns Twist constraint or undefined if not set
13937
+ */
13938
+ getTwistConstraint(jointIndex: number): TwistConstraint | undefined;
13939
+ /**
13940
+ * Remove twist constraint for a specific joint.
13941
+ *
13942
+ * @param jointIndex - Index of the joint
13943
+ * @returns True if a constraint was removed
13944
+ */
13945
+ removeTwistConstraint(jointIndex: number): boolean;
13946
+ /**
13947
+ * Clear all twist constraints.
13948
+ */
13949
+ clearTwistConstraints(): void;
13950
+ /**
13951
+ * Set pole vector for a specific joint.
13952
+ *
13953
+ * @param jointIndex - Index of the joint to apply pole vector to
13954
+ * @param poleVector - Pole vector position in world space
13955
+ * @param weight - Weight of the pole vector constraint (0-1, default: 1)
13956
+ */
13957
+ setPoleVector(jointIndex: number, poleVector: Vector3, weight?: number): void;
13958
+ /**
13959
+ * Remove pole vector for a specific joint.
13960
+ *
13961
+ * @param jointIndex - Index of the joint to remove pole vector from
13962
+ * @returns True if a pole vector was removed, false if none existed
13963
+ */
13964
+ removePoleVector(jointIndex: number): boolean;
13965
+ /**
13966
+ * Clear all pole vectors.
13967
+ */
13968
+ clearPoleVectors(): void;
13969
+ /**
13970
+ * Get pole vector configuration for a specific joint.
13971
+ *
13972
+ * @param jointIndex - Index of the joint
13973
+ * @returns Pole vector configuration or undefined if not set
13974
+ */
13975
+ getPoleVector(jointIndex: number): {
13976
+ position: Vector3;
13977
+ weight: number;
13978
+ } | undefined;
13979
+ /**
13980
+ * Check if a joint has a pole vector.
13981
+ *
13982
+ * @param jointIndex - Index of the joint
13983
+ * @returns True if the joint has a pole vector
13984
+ */
13985
+ hasPoleVector(jointIndex: number): boolean;
13986
+ /**
13987
+ * Solve the IK chain to reach the target position using CCD algorithm.
13988
+ *
13989
+ * @param target - Target position for the end effector
13990
+ * @returns True if converged within tolerance, false otherwise
13991
+ */
13992
+ solve(target: Vector3): boolean;
13993
+ /**
13994
+ * Rotate all joints from the given index to the end effector around a pivot point.
13995
+ *
13996
+ * @param startIndex - Index of the joint to start rotating from
13997
+ * @param rotation - Rotation to apply
13998
+ * @param pivot - Pivot point for rotation (position of the joint being adjusted)
13999
+ */
14000
+ private _rotateJointsFromIndex;
14001
+ /**
14002
+ * Apply all pole vector constraints.
14003
+ *
14004
+ * @remarks
14005
+ * This method applies all configured pole vectors to their respective joints.
14006
+ * Pole vectors are applied in reverse order (from end to root) to minimize
14007
+ * interference between multiple pole vectors. This ensures that pole vectors
14008
+ * closer to the end effector are not affected by pole vectors closer to the root.
14009
+ */
14010
+ private _applyAllPoleVectors;
14011
+ /**
14012
+ * Apply pole vector twist to a specific joint.
14013
+ *
14014
+ * @remarks
14015
+ * This method is called after the base CCD rotation has been applied.
14016
+ * It adds an additional twist rotation around the joint-to-end axis
14017
+ * to make the next joint (child) bend toward the pole vector.
14018
+ *
14019
+ * @param jointIndex - Index of the pole joint
14020
+ * @param poleVector - Pole vector position in world space
14021
+ * @param weight - Weight of the pole vector constraint (0-1)
14022
+ */
14023
+ private _applyPoleVectorTwist;
14024
+ /**
14025
+ * Apply constraints for a specific joint.
14026
+ *
14027
+ * @param jointIndex - Index of the joint to apply constraints to
14028
+ */
14029
+ private _applyConstraintsForJoint;
14030
+ /**
14031
+ * Apply the solved joint positions to scene nodes as rotations.
14032
+ *
14033
+ * @param weight - Blend weight (0 = original, 1 = full IK, default: 1)
14034
+ */
14035
+ applyToNodes(weight?: number): void;
14036
+ }
14037
+
14038
+ /**
14039
+ * Angle constraint for IK joints.
14040
+ *
14041
+ * Limits the angle between the bone from parent to this joint
14042
+ * and the bone from this joint to child.
14043
+ *
14044
+ * @remarks
14045
+ * This is useful for joints like elbows and knees that have
14046
+ * limited range of motion.
14047
+ *
14048
+ * @public
14049
+ */
14050
+ declare class IKAngleConstraint extends IKConstraint {
14051
+ /** Minimum angle in degrees */
14052
+ private _minAngle;
14053
+ /** Maximum angle in degrees */
14054
+ private _maxAngle;
14055
+ /**
14056
+ * Create an angle constraint.
14057
+ *
14058
+ * @param jointIndex - Index of the joint in the chain
14059
+ * @param minAngle - Minimum angle in degrees (0 = straight)
14060
+ * @param maxAngle - Maximum angle in degrees (180 = fully bent)
14061
+ */
14062
+ constructor(jointIndex: number, minAngle: number, maxAngle: number);
14063
+ /**
14064
+ * Get the minimum angle in degrees.
14065
+ */
14066
+ get minAngle(): number;
14067
+ /**
14068
+ * Set the minimum angle in degrees.
14069
+ */
14070
+ set minAngle(value: number);
14071
+ /**
14072
+ * Get the maximum angle in degrees.
14073
+ */
14074
+ get maxAngle(): number;
14075
+ /**
14076
+ * Set the maximum angle in degrees.
14077
+ */
14078
+ set maxAngle(value: number);
14079
+ /**
14080
+ * Apply the angle constraint to limit joint bending.
14081
+ */
14082
+ apply(joints: IKJoint[]): void;
14083
+ /**
14084
+ * Apply constraint to end effector joint.
14085
+ */
14086
+ private _applyEndEffectorConstraint;
14087
+ /**
14088
+ * Apply constraint to regular joint.
14089
+ */
14090
+ private _applyRegularConstraint;
14091
+ /**
14092
+ * Adjust joint angle by rotating the outgoing bone.
14093
+ */
14094
+ private _adjustJointAngle;
14095
+ }
14096
+
14097
+ /**
14098
+ * Constraint between particles in different chains
14099
+ *
14100
+ * @public
14101
+ */
14102
+ interface InterChainConstraint {
14103
+ /** Index of the first chain */
14104
+ chainAIndex: number;
14105
+ /** Index of the second chain */
14106
+ chainBIndex: number;
14107
+ /** Index of particle in chain A */
14108
+ particleAIndex: number;
14109
+ /** Index of particle in chain B */
14110
+ particleBIndex: number;
14111
+ /** Desired distance between particles */
14112
+ restLength: number;
14113
+ /** Constraint strength [0-1], used by Verlet solver */
14114
+ stiffness: number;
14115
+ /**
14116
+ * XPBD compliance (inverse stiffness) in m/N.
14117
+ * Only used when solver is 'xpbd'.
14118
+ */
14119
+ compliance: number;
14120
+ /** XPBD Lagrange multiplier accumulator, reset each time step. */
14121
+ lambda: number;
14122
+ }
14123
+ /**
14124
+ * Options for creating a MultiChainSpringSystem
14125
+ *
14126
+ * @public
14127
+ */
14128
+ interface MultiChainSpringSystemOptions {
14129
+ /** Number of constraint solver iterations (default: 5) */
14130
+ iterations?: number;
14131
+ /** Gravity force vector (default: (0, -9.8, 0)) */
14132
+ gravity?: Vector3;
14133
+ /** Wind force vector (default: (0, 0, 0)) */
14134
+ wind?: Vector3;
14135
+ /** Enable inertial forces (centrifugal/Coriolis) when root rotates (default: true) */
14136
+ enableInertialForces?: boolean;
14137
+ /** Centrifugal force multiplier (default: 1.0) */
14138
+ centrifugalScale?: number;
14139
+ /** Coriolis force multiplier (default: 1.0) */
14140
+ coriolisScale?: number;
14141
+ /**
14142
+ * Constraint solver type (default: 'verlet').
14143
+ * - 'verlet': stiffness [0-1] controls per-iteration correction strength.
14144
+ * - 'xpbd': compliance (m/N) gives physically correct, iteration-independent results.
14145
+ */
14146
+ solver?: 'verlet' | 'xpbd';
14147
+ }
14148
+ /**
14149
+ * Physics engine for multiple spring chains with inter-chain constraints
14150
+ * Suitable for cloth, skirts, capes, and other multi-chain simulations
14151
+ *
14152
+ * @public
14153
+ */
14154
+ declare class MultiChainSpringSystem {
14155
+ private _chains;
14156
+ private _interChainConstraints;
14157
+ private _iterations;
14158
+ private _gravity;
14159
+ private _wind;
14160
+ private _enableInertialForces;
14161
+ private _centrifugalScale;
14162
+ private _coriolisScale;
14163
+ private _solver;
14164
+ constructor(options?: MultiChainSpringSystemOptions);
14165
+ /**
14166
+ * Adds a spring chain to the system
14167
+ * @param chain - The chain to add
14168
+ * @returns The index of the added chain
14169
+ */
14170
+ addChain(chain: SpringChain): number;
14171
+ /**
14172
+ * Adds an inter-chain constraint
14173
+ * @param constraint - The constraint to add
14174
+ */
14175
+ addInterChainConstraint(constraint: InterChainConstraint): void;
14176
+ /**
14177
+ * Creates radial constraints between adjacent chains
14178
+ * Useful for skirts, capes, and other radial multi-chain structures
14179
+ * @param options - Configuration options
14180
+ */
14181
+ createRadialConstraints(options: {
14182
+ /** Constraint stiffness [0-1], used by Verlet solver */
14183
+ stiffness: number;
14184
+ /** Maximum distance to create constraints (particles further apart are not connected) */
14185
+ maxDistance: number;
14186
+ /** Skip first N rows of particles (e.g., anchor points at waist) */
14187
+ skipRows?: number;
14188
+ /** Connect to next N chains (default: 1, only adjacent chains) */
14189
+ connectDistance?: number;
14190
+ /** XPBD compliance in m/N (default: 0 = rigid). Only used when solver is 'xpbd'. */
14191
+ compliance?: number;
14192
+ }): void;
14193
+ /**
14194
+ * Updates the physics simulation for all chains
14195
+ * @param deltaTime - Time step in seconds
14196
+ */
14197
+ update(deltaTime: number): void;
14198
+ private updateFixedParticles;
14199
+ private calculateGlobalRotation;
14200
+ private estimateRotationCenterFromHistory;
14201
+ private calculateCircleCenter;
14202
+ private calculateInertialAcceleration;
14203
+ private solveConstraint;
14204
+ private solveInterChainConstraint;
14205
+ private solveConstraintXPBD;
14206
+ private solveInterChainConstraintXPBD;
14207
+ /**
14208
+ * Applies simulation results to scene nodes
14209
+ * @param weight - Blend weight [0-1] (default: 1.0)
14210
+ */
14211
+ applyToNodes(weight?: number): void;
14212
+ private applyChainToNodes;
14213
+ /**
14214
+ * Resets the simulation to initial state
14215
+ */
14216
+ reset(): void;
14217
+ /**
14218
+ * Gets the spring chains
14219
+ */
14220
+ get chains(): SpringChain[];
14221
+ /**
14222
+ * Gets the inter-chain constraints
14223
+ */
14224
+ get interChainConstraints(): InterChainConstraint[];
14225
+ /**
14226
+ * Gets the current gravity
14227
+ */
14228
+ get gravity(): Vector3;
14229
+ set gravity(gravity: Vector3);
14230
+ /**
14231
+ * Gets the current wind
14232
+ */
14233
+ get wind(): Vector3;
14234
+ set wind(wind: Vector3);
14235
+ /**
14236
+ * Gets the number of iterations
14237
+ */
14238
+ get iterations(): number;
14239
+ set iterations(count: number);
14240
+ /**
14241
+ * Gets whether inertial forces are enabled
14242
+ */
14243
+ get enableInertialForces(): boolean;
14244
+ set enableInertialForces(enabled: boolean);
14245
+ /**
14246
+ * Gets the centrifugal force scale
14247
+ */
14248
+ get centrifugalScale(): number;
14249
+ set centrifugalScale(scale: number);
14250
+ /**
14251
+ * Gets the Coriolis force scale
14252
+ */
14253
+ get coriolisScale(): number;
14254
+ set coriolisScale(scale: number);
14255
+ get solver(): 'verlet' | 'xpbd';
14256
+ set solver(type: 'verlet' | 'xpbd');
14257
+ }
14258
+
12878
14259
  /**
12879
14260
  * Manages serialization and deserialization of engine objects to/from JSON,
12880
14261
  * including asset resolution via a virtual file system (VFS) and asset manager.
@@ -18961,4 +20342,4 @@ declare const ATMOSPHERIC_FOG_BIT: number;
18961
20342
  */
18962
20343
  declare const HEIGHT_FOG_BIT: number;
18963
20344
 
18964
- export { AABBTree, ABufferOIT, ATMOSPHERIC_FOG_BIT, AbsNode, AbstractPostEffect, AllConditionNode, AnimationClip, AnimationSet, AnimationTrack, AnyConditionNode, type AppCreationOptions, type AppOptions, Application, ArcCosNode, ArcSinNode, ArcTan2Node, ArcTanNode, ArccosineHNode, ArcsineHNode, ArctangentHNode, type AssetAnimationData, type AssetAnimationTrack, AssetHierarchyNode, AssetManager, type AssetMaterial, type AssetMaterialClearcoat, type AssetMaterialCommon, type AssetMaterialIridescence, type AssetMaterialSheen, type AssetMaterialTransmission, type AssetMeshData, type AssetPBRMaterialCommon, type AssetPBRMaterialMR, type AssetPBRMaterialSG, type AssetRotationTrack, type AssetScaleTrack, AssetScene, type AssetSkeletalAnimationTrack, AssetSkeleton, type AssetSubMeshData, type AssetTranslationTrack, type AssetUnlitMaterial, BUILTIN_ASSET_TEST_CUBEMAP, BUILTIN_ASSET_TEXTURE_SHEEN_LUT, BaseCameraController, BaseGraphNode, BaseLight, BaseSprite, BaseTextureNode, type BatchDrawable, BatchGroup, BillboardMatrixNode, type BlendMode, BlinnMaterial, type BlitType, Blitter, Bloom, type BluePrintEditorState, type BluePrintUniformTexture, type BluePrintUniformValue, type BlueprintDAG, BoundingBox, type BoundingVolume, type BoxCreationOptions, BoxFilterBlitter, BoxFrameShape, BoxShape, type CachedBindGroup, Camera, type CameraHistoryData, CameraNearFarNode, CameraPositionNode, CeilNode, ClampNode, ClipmapTerrain, ClipmapTerrainMaterial, CompAddNode, CompComparisonNode, CompDivNode, CompMulNode, CompSubNode, type ComparisonMode, Compositor, type CompositorContext, ConstantBVec2Node, ConstantBVec3Node, ConstantBVec4Node, ConstantBooleanNode, ConstantScalarNode, ConstantTexture2DArrayNode, ConstantTexture2DNode, ConstantTextureCubeNode, ConstantVec2Node, ConstantVec3Node, ConstantVec4Node, CopyBlitter, CosHNode, CosNode, CrossProductNode, CubemapSHProjector, CullVisitor, type CylinderCreationOptions, CylinderShape, DDXNode, DDYNode, Degrees2RadiansNode, DepthPass, DirectionalLight, DistanceNode, DotProductNode, DracoMeshDecoder, type DrawContext, type Drawable, type DrawableInstanceInfo, type EditorMode, ElapsedTimeNode, type EmitterBehavior, type EmitterShape, Engine, EnvConstantAmbient, EnvHemisphericAmbient, type EnvLightType, EnvLightWrapper, EnvShIBL, Environment, EnvironmentLighting, EqualNode, Exp2Node, ExpNode, type ExtractMixinReturnType, type ExtractMixinType, FBMWaveGenerator, FFTWaveGenerator, FPSCameraController, type FPSCameraControllerOptions, FWidthNode, FXAA, FaceForwardNode, FloorNode, FmaNode, type FogType, FractNode, FunctionCallNode, FunctionInputNode, FunctionOutputNode, GaussianBlurBlitter, GenericMathNode, GerstnerWaveGenerator, GraphNode, type GraphNodeInput, type GraphNodeOutput, type GraphStructure, type GrassInstanceInfo, GrassLayer, GrassMaterial, GrassRenderer, Grayscale, HEIGHT_FOG_BIT, Hash1Node, Hash2Node, Hash3Node, type Host, type IAttachedScript, type IBaseEvent, type IControllerKeyboardEvent, type IControllerKeydownEvent, type IControllerKeypressEvent, type IControllerKeyupEvent, type IControllerMouseEvent, type IControllerPointerCancelEvent, type IControllerPointerDownEvent, type IControllerPointerMoveEvent, type IControllerPointerUpEvent, type IControllerWheelEvent, type IGraphNode, type IMixinAlbedoColor, type IMixinBlinnPhong, type IMixinFoliage, type IMixinLambert, type IMixinLight, type IMixinPBRBluePrint, type IMixinPBRCommon, type IMixinPBRMetallicRoughness, type IMixinPBRSpecularGlossiness, type IMixinVertexColor, type IModKey, type IRUniformTexture, type IRUniformValue, type IRenderHook, type IRenderable, type InputEventHandler, InputManager, InstanceBindGroupAllocator, type InstanceData, type InstanceUniformType, InvProjMatrixNode, InvSqrtNode, InvViewProjMatrixNode, LIGHT_TYPE_DIRECTIONAL, LIGHT_TYPE_NONE, LIGHT_TYPE_POINT, LIGHT_TYPE_SPOT, LambertMaterial, LengthNode, Log2Node, type LogMode, LogNode, LogicallyAndNode, LogicallyOrNode, MAX_CLUSTERED_LIGHTS, MAX_GERSTNER_WAVE_COUNT, MAX_MORPH_ATTRIBUTES, MAX_MORPH_TARGETS, MAX_TERRAIN_MIPMAP_LEVELS, MORPH_ATTRIBUTE_VECTOR_COUNT, MORPH_TARGET_COLOR, MORPH_TARGET_NORMAL, MORPH_TARGET_POSITION, MORPH_TARGET_TANGENT, MORPH_TARGET_TEX0, MORPH_TARGET_TEX1, MORPH_TARGET_TEX2, MORPH_TARGET_TEX3, MORPH_WEIGHTS_VECTOR_COUNT, MakeVectorNode, Material, MaterialBlueprintIR, type MaterialBlueprintIRBehaviors, type MaterialTextureInfo, MaterialVaryingFlags, MaxNode, Mesh, MeshMaterial, type Metadata, MinNode, MixNode, ModNode, type ModelFetchOptions, type ModelInfo, type MorphData, type MorphInfo, type MorphState, MorphTargetTrack, NamedObject, type NodeConnection, NodeEulerRotationTrack, type NodeIterateFunc, NodeRotationTrack, NodeScaleTrack, NodeTranslationTrack, NormalizeNode, NotEqualNode, type OIT, Octree, OctreeNode, OctreeNodeChunk, OctreePlacement, OrbitCameraController, type OrbitCameraControllerOptions, OrthoCamera, PBRBlockNode, PBRBluePrintMaterial, PBRMetallicRoughnessMaterial, PBRSpecularGlossinessMaterial, ParticleMaterial, ParticleSystem, PerlinNoise2DNode, PerspectiveCamera, type PickResult, type PickTarget, type PlaneCreationOptions, PlaneShape, type PlayAnimationOptions, PointLight, type PointTransform, PostEffectLayer, PowNode, Primitive, ProjectionMatrixNode, type PropEdit, type PropertyAccessor, type PropertyAccessorOptions, type PropertyToType, PropertyTrack, type PropertyType, type PropertyValue, PunctualLight, QUEUE_OPAQUE, QUEUE_TRANSPARENT, RENDER_PASS_TYPE_DEPTH, RENDER_PASS_TYPE_LIGHT, RENDER_PASS_TYPE_OBJECT_COLOR, RENDER_PASS_TYPE_SHADOWMAP, Radians2DegreesNode, ReflectNode, RefractNode, RenderContext, type RenderItemList, type RenderItemListBundle, type RenderItemListInfo, RenderPass, RenderQueue, type RenderQueueItem, type RenderQueueRef, RenderTarget, type ResolutionTransform, ResolveVertexNormalNode, ResolveVertexPositionNode, ResolveVertexTangentNode, ResourceManager, RuntimeScript, SAO, type SamplerType, SaturateNode, Scene, SceneNode, type SceneNodeVisible, ScreenAdapter, type ScreenConfig, ScreenRenderTarget, type ScreenScaleMode, ScriptRegistry, ScriptingSystem, type ScriptingSystemOptions, SelectionNode, type SerializableClass, ShaderHelper, ShadowMapPass, ShadowMapper, type ShadowMode, Shape, type ShapeCreationOptions, type ShapeOptionType, type ShapeType, SharedModel, SignNode, SimplexNoise2DNode, SinHNode, SinNode, Skeleton, type SkinnedBoundingBox, SkyEnvTextureNode, SkyRenderer, type SkyType, SmoothStepNode, type SphereCreationOptions, SphereShape, SpotLight, Sprite, SpriteBlockNode, SpriteBlueprintMaterial, SpriteMaterial, SqrtNode, StandardSpriteMaterial, StepNode, type StopAnimationOptions, SwizzleNode, TanHNode, TanNode, type TerrainDebugMode, type TetrahedronCreationOptions, TetrahedronFrameShape, TetrahedronShape, type TextureFetchOptions, type TextureMixinInstanceTypes, type TextureMixinTypes, type TextureProp, type TexturePropUniforms, TextureSampleGrad, TextureSampleNode, type ToMixedTextureType, Tonemap, type TorusCreationOptions, TorusShape, TransformNode, UnlitMaterial, VertexBinormalNode, VertexBlockNode, VertexColorNode, VertexNormalNode, VertexPositionNode, VertexTangentNode, VertexUVNode, ViewMatrixNode, ViewProjMatrixNode, type Visitor, Water, type WaveGenerator, WeightedBlendedOIT, applyMaterialMixins, decode2HalfFromRGBA, decodeFloatFromRGBA, decodeNormalizedFloatFromRGBA, decodeRGBM, defineProps, encode2HalfToRGBA, encodeFloatToRGBA, encodeNormalizedFloatToRGBA, encodeRGBM, fetchSampler, gammaToLinear, getApp, getDevice, getEngine, getInput, gradient, hash11, hash12, hash13, hash21, hash22, hash23, hash31, hash32, hash33, interleavedGradientNoise, linearToGamma, mixinAlbedoColor, mixinBlinnPhong, mixinFoliage, mixinLambert, mixinLight, mixinPBRBluePrint, mixinPBRCommon, mixinPBRMetallicRoughness, mixinPBRSpecularGlossness, mixinTextureProps, mixinVertexColor, noise3D, panoramaToCubemap, perlinNoise2D, perlinNoise3D, prefilterCubemap, smoothNoise3D, temporalResolve, tryGetApp, valueNoise, whiteNoise, worleyFBM, worleyNoise };
20345
+ export { AABBTree, ABufferOIT, ATMOSPHERIC_FOG_BIT, AbsNode, AbstractPostEffect, AllConditionNode, AnimationClip, AnimationSet, AnimationTrack, AnyConditionNode, type AppCreationOptions, type AppOptions, Application, ArcCosNode, ArcSinNode, ArcTan2Node, ArcTanNode, ArccosineHNode, ArcsineHNode, ArctangentHNode, type AssetAnimationData, type AssetAnimationTrack, AssetHierarchyNode, AssetManager, type AssetMaterial, type AssetMaterialClearcoat, type AssetMaterialCommon, type AssetMaterialIridescence, type AssetMaterialSheen, type AssetMaterialTransmission, type AssetMeshData, type AssetPBRMaterialCommon, type AssetPBRMaterialMR, type AssetPBRMaterialSG, type AssetRotationTrack, type AssetScaleTrack, AssetScene, type AssetSkeletalAnimationTrack, AssetSkeleton, type AssetSubMeshData, type AssetTranslationTrack, type AssetUnlitMaterial, BUILTIN_ASSET_TEST_CUBEMAP, BUILTIN_ASSET_TEXTURE_SHEEN_LUT, BaseCameraController, BaseGraphNode, BaseLight, BaseSprite, BaseTextureNode, type BatchDrawable, BatchGroup, BillboardMatrixNode, type BlendMode, BlinnMaterial, type BlitType, Blitter, Bloom, type BluePrintEditorState, type BluePrintUniformTexture, type BluePrintUniformValue, type BlueprintDAG, BoundingBox, type BoundingVolume, type BoxCreationOptions, BoxFilterBlitter, BoxFrameShape, BoxShape, CCDSolver, type CachedBindGroup, Camera, type CameraHistoryData, CameraNearFarNode, CameraPositionNode, type CapsuleCollider, CeilNode, ClampNode, ClipmapTerrain, ClipmapTerrainMaterial, CompAddNode, CompComparisonNode, CompDivNode, CompMulNode, CompSubNode, type ComparisonMode, Compositor, type CompositorContext, ConstantBVec2Node, ConstantBVec3Node, ConstantBVec4Node, ConstantBooleanNode, ConstantScalarNode, ConstantTexture2DArrayNode, ConstantTexture2DNode, ConstantTextureCubeNode, ConstantVec2Node, ConstantVec3Node, ConstantVec4Node, CopyBlitter, CosHNode, CosNode, CrossProductNode, CubemapSHProjector, CullVisitor, type CylinderCreationOptions, CylinderShape, DDXNode, DDYNode, Degrees2RadiansNode, DepthPass, DirectionalLight, DistanceNode, DotProductNode, DracoMeshDecoder, type DrawContext, type Drawable, type DrawableInstanceInfo, type EditorMode, ElapsedTimeNode, type EmitterBehavior, type EmitterShape, Engine, EnvConstantAmbient, EnvHemisphericAmbient, type EnvLightType, EnvLightWrapper, EnvShIBL, Environment, EnvironmentLighting, EqualNode, Exp2Node, ExpNode, type ExtractMixinReturnType, type ExtractMixinType, FABRIKSolver, FBMWaveGenerator, FFTWaveGenerator, FPSCameraController, type FPSCameraControllerOptions, FWidthNode, FXAA, FaceForwardNode, FloorNode, FmaNode, type FogType, FractNode, FunctionCallNode, FunctionInputNode, FunctionOutputNode, GaussianBlurBlitter, GenericMathNode, GerstnerWaveGenerator, GraphNode, type GraphNodeInput, type GraphNodeOutput, type GraphStructure, type GrassInstanceInfo, GrassLayer, GrassMaterial, GrassRenderer, Grayscale, HEIGHT_FOG_BIT, Hash1Node, Hash2Node, Hash3Node, type Host, type IAttachedScript, type IBaseEvent, type IControllerKeyboardEvent, type IControllerKeydownEvent, type IControllerKeypressEvent, type IControllerKeyupEvent, type IControllerMouseEvent, type IControllerPointerCancelEvent, type IControllerPointerDownEvent, type IControllerPointerMoveEvent, type IControllerPointerUpEvent, type IControllerWheelEvent, type IGraphNode, IKAngleConstraint, IKChain, IKConstraint, type IKJoint, IKModifier, IKSolver, type IMixinAlbedoColor, type IMixinBlinnPhong, type IMixinFoliage, type IMixinLambert, type IMixinLight, type IMixinPBRBluePrint, type IMixinPBRCommon, type IMixinPBRMetallicRoughness, type IMixinPBRSpecularGlossiness, type IMixinVertexColor, type IModKey, type IRUniformTexture, type IRUniformValue, type IRenderHook, type IRenderable, type InputEventHandler, InputManager, InstanceBindGroupAllocator, type InstanceData, type InstanceUniformType, type InterChainConstraint, InvProjMatrixNode, InvSqrtNode, InvViewProjMatrixNode, LIGHT_TYPE_DIRECTIONAL, LIGHT_TYPE_NONE, LIGHT_TYPE_POINT, LIGHT_TYPE_SPOT, LambertMaterial, LengthNode, Log2Node, type LogMode, LogNode, LogicallyAndNode, LogicallyOrNode, MAX_CLUSTERED_LIGHTS, MAX_GERSTNER_WAVE_COUNT, MAX_MORPH_ATTRIBUTES, MAX_MORPH_TARGETS, MAX_TERRAIN_MIPMAP_LEVELS, MORPH_ATTRIBUTE_VECTOR_COUNT, MORPH_TARGET_COLOR, MORPH_TARGET_NORMAL, MORPH_TARGET_POSITION, MORPH_TARGET_TANGENT, MORPH_TARGET_TEX0, MORPH_TARGET_TEX1, MORPH_TARGET_TEX2, MORPH_TARGET_TEX3, MORPH_WEIGHTS_VECTOR_COUNT, MakeVectorNode, Material, MaterialBlueprintIR, type MaterialBlueprintIRBehaviors, type MaterialTextureInfo, MaterialVaryingFlags, MaxNode, Mesh, MeshMaterial, type Metadata, MinNode, MixNode, ModNode, type ModelFetchOptions, type ModelInfo, type MorphData, type MorphInfo, type MorphState, MorphTargetTrack, MultiChainSpringSystem, type MultiChainSpringSystemOptions, NamedObject, type NodeConnection, NodeEulerRotationTrack, type NodeIterateFunc, NodeRotationTrack, NodeScaleTrack, NodeTranslationTrack, NormalizeNode, NotEqualNode, type OIT, Octree, OctreeNode, OctreeNodeChunk, OctreePlacement, OrbitCameraController, type OrbitCameraControllerOptions, OrthoCamera, PBRBlockNode, PBRBluePrintMaterial, PBRMetallicRoughnessMaterial, PBRSpecularGlossinessMaterial, ParticleMaterial, ParticleSystem, PerlinNoise2DNode, PerspectiveCamera, type PickResult, type PickTarget, type PlaneCollider, type PlaneCreationOptions, PlaneShape, type PlayAnimationOptions, PointLight, type PointTransform, PostEffectLayer, PowNode, Primitive, ProjectionMatrixNode, type PropEdit, type PropertyAccessor, type PropertyAccessorOptions, type PropertyToType, PropertyTrack, type PropertyType, type PropertyValue, PunctualLight, QUEUE_OPAQUE, QUEUE_TRANSPARENT, RENDER_PASS_TYPE_DEPTH, RENDER_PASS_TYPE_LIGHT, RENDER_PASS_TYPE_OBJECT_COLOR, RENDER_PASS_TYPE_SHADOWMAP, Radians2DegreesNode, ReflectNode, RefractNode, RenderContext, type RenderItemList, type RenderItemListBundle, type RenderItemListInfo, RenderPass, RenderQueue, type RenderQueueItem, type RenderQueueRef, RenderTarget, type ResolutionTransform, ResolveVertexNormalNode, ResolveVertexPositionNode, ResolveVertexTangentNode, ResourceManager, RuntimeScript, SAO, type SamplerType, SaturateNode, Scene, SceneNode, type SceneNodeVisible, ScreenAdapter, type ScreenConfig, ScreenRenderTarget, type ScreenScaleMode, ScriptRegistry, ScriptingSystem, type ScriptingSystemOptions, SelectionNode, type SerializableClass, ShaderHelper, ShadowMapPass, ShadowMapper, type ShadowMode, Shape, type ShapeCreationOptions, type ShapeOptionType, type ShapeType, SharedModel, SignNode, SimplexNoise2DNode, SinHNode, SinNode, Skeleton, SkeletonModifier, type SkinnedBoundingBox, SkyEnvTextureNode, SkyRenderer, type SkyType, SmoothStepNode, type SphereCollider, type SphereCreationOptions, SphereShape, SpotLight, SpringChain, type SpringCollider, type SpringConstraint, SpringModifier, type SpringParticle, SpringSystem, type SpringSystemOptions, Sprite, SpriteBlockNode, SpriteBlueprintMaterial, SpriteMaterial, SqrtNode, StandardSpriteMaterial, StepNode, type StopAnimationOptions, SwizzleNode, TanHNode, TanNode, type TerrainDebugMode, type TetrahedronCreationOptions, TetrahedronFrameShape, TetrahedronShape, type TextureFetchOptions, type TextureMixinInstanceTypes, type TextureMixinTypes, type TextureProp, type TexturePropUniforms, TextureSampleGrad, TextureSampleNode, type ToMixedTextureType, Tonemap, type TorusCreationOptions, TorusShape, TransformNode, type TwistConstraint, TwoBoneIKSolver, UnlitMaterial, VertexBinormalNode, VertexBlockNode, VertexColorNode, VertexNormalNode, VertexPositionNode, VertexTangentNode, VertexUVNode, ViewMatrixNode, ViewProjMatrixNode, type Visitor, Water, type WaveGenerator, WeightedBlendedOIT, applyMaterialMixins, createCapsuleCollider, createPlaneCollider, createSphereCollider, createSpringConstraint, createSpringParticle, decode2HalfFromRGBA, decodeFloatFromRGBA, decodeNormalizedFloatFromRGBA, decodeRGBM, defineProps, encode2HalfToRGBA, encodeFloatToRGBA, encodeNormalizedFloatToRGBA, encodeRGBM, fetchSampler, gammaToLinear, getApp, getDevice, getEngine, getInput, gradient, hash11, hash12, hash13, hash21, hash22, hash23, hash31, hash32, hash33, interleavedGradientNoise, linearToGamma, mixinAlbedoColor, mixinBlinnPhong, mixinFoliage, mixinLambert, mixinLight, mixinPBRBluePrint, mixinPBRCommon, mixinPBRMetallicRoughness, mixinPBRSpecularGlossness, mixinTextureProps, mixinVertexColor, noise3D, panoramaToCubemap, perlinNoise2D, perlinNoise3D, prefilterCubemap, resolveCapsuleCollision, resolvePlaneCollision, resolveSphereCollision, smoothNoise3D, temporalResolve, tryGetApp, updateColliderFromNode, valueNoise, whiteNoise, worleyFBM, worleyNoise };