Click or drag to resize
DigitalRuneInterpolationHelperEaseInOutSmoothStep Method (Single)
Computes a constant acceleration ease-in/ease-out smooth step function (single-precision).

Namespace: DigitalRune.Mathematics.Interpolation
Assembly: DigitalRune.Mathematics (in DigitalRune.Mathematics.dll) Version: 1.14.0.0 (1.14.0.14427)
Syntax
public static float EaseInOutSmoothStep(
	float x
)

Parameters

x
Type: SystemSingle
The argument x.

Return Value

Type: Single
The function value y.
Remarks

This functions can be visualized as an S-shaped curve based on a constant-acceleration ease-in/ease-out behavior.

The function value y goes from 0 to 1 as x goes from 0 to 1. y = 0 for x < 0 and y = 1 for x > 1.

To understand how the function works, let's assume that x is time and y is the distance. The function starts at x = 0 with 0 velocity and constant acceleration. The velocity increases until x = 0.5. Then the velocity decreases with constant acceleration and at x = 1 the velocity is 0.

See Also