IsMaterialDefault

Verifies that a material is a copy of Rhino's built-in "default" material.  The default material is used by objects and layers that have not been assigned a material.

Syntax

Rhino.IsMaterialDefault (intMaterialIndex)

Parameters

intMaterialIndex

Required.  Number.  The zero-based material index.

Returns

True

If successful.

False

If not successful.

Null

On error.

Example

Dim strObject, intIndex

strObject = Rhino.GetObject

If Not IsNull(strObject) Then

intIndex = Rhino.ObjectMaterialIndex(strObject)

If Rhino.IsMaterialDefault(intIndex) Then

Rhino.Print "Object is assigned default material."

Else

Rhino.Print "Object is not assigned default material."

End If

End If

Also See

LayerMaterialIndex

ObjectMaterialIndex