Click or drag to resize

RhinoMathIsValidSingle Method

Determines whether a Single value is valid within the RhinoCommon context.

Rhino does not use Single.NaN by convention, so this test evaluates to true if:

x is not equal to RhinoMath.UnsetValue,

System.Single.IsNaN(x) evaluates to false

System.Single.IsInfinity(x) evaluates to false

Namespace:  Rhino
Assembly:  RhinoCommon (in RhinoCommon.dll)
Since: 5.0
Syntax
public static bool IsValidSingle(
	float x
)

Parameters

x
Type: SystemSingle
Single number to test for validity.

Return Value

Type: Boolean
true if the number if valid, false if the number is NaN, Infinity or Unset.
See Also