Vector4.Clamp Method (Vector4, Vector4, Vector4)
Restricts a value to be within a specified range.
Syntax
'Declaration
Public Shared Function Clamp ( _
value1 As Vector4, _
min As Vector4, _
max As Vector4 _
) As Vector4
public static Vector4 Clamp (
Vector4 value1,
Vector4 min,
Vector4 max
)
public:
static Vector4 Clamp(
Vector4 value1,
Vector4 min,
Vector4 max
)
Parameters
- value1
Type: Vector4
The value to clamp. - min
Type: Vector4
The minimum value. - max
Type: Vector4
The maximum value.
Return Value
Type: Vector4
The clamped value.
Requirements
Namespace: Microsoft.Xna.Framework
Assembly: Microsoft.Xna.Framework (in microsoft.xna.framework.dll)
See Also
Reference
Vector4 Structure
Vector4 Members
Microsoft.Xna.Framework Namespace
Platforms
Windows Phone