| |
-_RunScript (
Sub LayerMaterialColor_To_LayerColor
Dim strLayer, intIndex
For Each strLayer In Rhino.LayerNames
intIndex = Rhino.LayerMaterialIndex(strLayer)
If IsNumeric(intIndex) Then
If intIndex <> -1 Then
Rhino.LayerColor strLayer, Rhino.MaterialColor (intIndex)
End If
End If
Next
End Sub
LayerMaterialColor_To_LayerColor
)
-_RunScript (
Sub LayerColor_To_LayerMaterialColor
Dim strLayer, intIndex
For Each strLayer In Rhino.LayerNames
intIndex = Rhino.LayerMaterialIndex(strLayer)
If IsNumeric(intIndex) Then
If intIndex = -1 Then
intIndex = Rhino.AddMaterialToLayer(strLayer)
End If
Rhino.MaterialColor intIndex, Rhino.LayerColor (strLayer)
End If
Next
End Sub
LayerColor_To_LayerMaterialColor
)
|