| Vector4DClamp Method (Vector4D, Double, Double) |
Returns a vector with the vector components clamped to the range [min, max].
Namespace: DigitalRune.Mathematics.AlgebraAssembly: DigitalRune.Mathematics (in DigitalRune.Mathematics.dll) Version: 1.14.0.0 (1.14.0.14427)
Syntax public static Vector4D Clamp(
Vector4D vector,
double min,
double max
)
Public Shared Function Clamp (
vector As Vector4D,
min As Double,
max As Double
) As Vector4D
public:
static Vector4D Clamp(
Vector4D vector,
double min,
double max
)
static member Clamp :
vector : Vector4D *
min : float *
max : float -> Vector4D
Parameters
- vector
- Type: DigitalRune.Mathematics.AlgebraVector4D
The vector. - min
- Type: SystemDouble
The min limit. - max
- Type: SystemDouble
The max limit.
Return Value
Type:
Vector4DA vector with clamped components.
Remarks
This operation is carried out per component. Component values less than
min are set to min. Component values greater than
max are set to max.
See Also