Announcement

Collapse
No announcement yet.

Render selected - a script

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Render selected - a script

    Hi,

    since a long time I use this script and I think it's a good time to share it here.
    If the user has selected some objects, the script hide all other objects except the lights in the scene.

    I have got the script at the rhino forum some months befor. I use a copy of the script at the right mouse button of the render button.

    Ciao Micha

    Code:
    -_RunScript (
    Sub RenderSelected
    Dim arrobjects, hideObjects, lights
    arrObjects = Rhino.GetObjects("Select Object for Rendering" , , vbTrue, vbTrue)
    lights = Rhino.ObjectsByType (256)
    If IsArray (arrObjects) Then
    hideObjects = Rhino.InvertSelectedObjects
    If Not IsArray(hideObjects) Then
    Rhino.print "Only one object in scene use regular render command"
    Else
    Rhino.HideObjects(hideObjects)
    Rhino.command "_Render"
    Rhino.showObjects (hideObjects)
    Rhino.SelectObjects (arrobjects)
    End If
    End If
    End Sub
    RenderSelected
    )
    www.simulacrum.de - visualization for designer and architects
Working...
X