Tuesday, November 22, 2011

Smart Select Pt.2: Set Current Layer

I've been using this script since early this year. It started from our frustration at: "Which layer does this object belong to?" and "Why must I always look at the properties tab?". I wrote the script to help find and quickly do some layer management/ file cleanup:

DefaultLayer.rvb: alias "d" - used for steps 5 and 6

So pick your object, run the script, and choose the following:
1. Set current layer to the object's layer*
2. Select all objects on that layer
3. Hide all objects on that layer
4. Isolate all objects on that layer
5. Turn that layer off
6. Lock that layer
7. Do nothing, other than peek at which layer that object belonged to*.

*change the "Current Layer Background" to a bright color to really see that layer pop. Find it at Options --> RhinoOptions > Appearance > Colors > LayerDialogBox.

Rhino has most of these commands (SetLayertoObject, OneLayerOn, OneLayerOff, SelLayer), but typing/ clicking through them is way too much work.

photos coming soon...

Smart Select Pt.1: Select Similar Object

I'm working on a smarter selection tool for rhino, so I'm starting with the basics.

This script selects:
similar closed polysurfaces by volume and at least one other dimension...
similar open surfaces/ polysurfaces by surface area...
similar open or closed curves by length, control points...

So click any of those objects, and watch as the script picks up similar objects in your file!

SelSimilarObjects.rvb (remember to convert the .txt into .rvb)