Creates a 3D spring animator.
Spring constant (stiffness).
Damping coefficient.
Mass applied to each axis.
Gets the damping constant (resistance).
Sets the damping constant. Higher values increase resistance and reduce oscillation.
The damping coefficient.
Gets the spring constant (stiffness).
Sets the spring constant (stiffness).
The spring constant k.
Gets the mass of the object.
Sets the mass. Higher mass slows acceleration and increases inertia.
The mass value.
Gets the onSettled callback.
Sets a callback that fires once all three axes of the spring have settled.
Gets the x-component of the spring's velocity.
Gets the y-component of the spring's velocity.
Gets the z-component of the spring's velocity.
StaticbouncyConvenience factory for a bouncy spring with noticeable overshoot.
Total perceptual duration in seconds (default: 0.5).
A SpringAnimate configured for bouncy motion.
Evaluates the new position of the object based on the spring dynamics.
The updated position of the object.
Resets the spring's velocity and time accumulator to zero.
Retunes the internal springs to match a desired duration and bounce. Preserves current velocities by default to maintain continuity.
Perceptual duration in seconds.
Bounce factor in [0,1], default 0 (smooth/critically-damped).
If false, zeroes velocities.
Retunes to the bouncy profile.
Perceptual duration in seconds.
If false, zeroes velocities.
Retunes to the smooth profile.
Perceptual duration in seconds.
If false, zeroes velocities.
Retunes to the snappy profile.
Perceptual duration in seconds.
If false, zeroes velocities.
StaticsmoothConvenience factory for a smooth, critically-damped spring with no bounce.
Total perceptual duration in seconds (default: 0.3).
A SpringAnimate configured for smooth motion.
StaticsnappyConvenience factory for a snappy spring with slight bounce.
Total perceptual duration in seconds (default: 0.3).
A SpringAnimate configured for snappy motion.
StaticspringCreates a new spring animation with the given duration and bounce.
The perceptual duration of the animation in seconds.
How much bounce the spring should have. 0 is no bounce, 1 is infinite bounce.
A new spring animation object.
A 3D spring simulation class for smooth, physically-based animations of vectors.