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)
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.
Version Information

Rhino for Mac

Supported in: 5.4

Rhino for Windows

Supported in: 6.8
See Also