M_Rhino_RhinoMath_Clamp_1 - mcneel/rhinocommon-api-docs GitHub Wiki
Restricts a Int32 to be specified within an interval of two integers.
Namespace: Rhino
Assembly: RhinoCommon (in RhinoCommon.dll) Version: Rhino 6.0
C#
public static int Clamp(
int value,
int bound1,
int bound2
)
VB
Public Shared Function Clamp (
value As Integer,
bound1 As Integer,
bound2 As Integer
) As Integer
- value
- Type: System.Int32
An integer. - bound1
- Type: System.Int32
A first bound. - bound2
- Type: System.Int32
A second bound. This does not necessarily need to be larger or smaller than bound1.
Type: Int32
The clamped value.
Supported in: 5D58w