| Vector2DClampToZero Method (Vector2D) |
Returns a vector with near-zero vector components clamped to 0.
Namespace: DigitalRune.Mathematics.AlgebraAssembly: DigitalRune.Mathematics (in DigitalRune.Mathematics.dll) Version: 1.14.0.0 (1.14.0.14427)
Syntax public static Vector2D ClampToZero(
Vector2D vector
)
Public Shared Function ClampToZero (
vector As Vector2D
) As Vector2D
public:
static Vector2D ClampToZero(
Vector2D vector
)
static member ClampToZero :
vector : Vector2D -> Vector2D
Parameters
- vector
- Type: DigitalRune.Mathematics.AlgebraVector2D
The vector.
Return Value
Type:
Vector2DThe vector with small components clamped to zero.
Remarks
Each vector component (X and Y) is compared to zero. If the component is in the interval
[-
EpsilonD, +
EpsilonD] it is set to zero,
otherwise it remains unchanged.
See Also