Go to: Synopsis. Return value. Related. Flags. MEL examples.
select [-add] [-addFirst] [-all] [-allDagObjects] [-allDependencyNodes] [-clear] [-deselect] [-hierarchy] [-noExpand] [-replace] [-toggle] [-visible]
[objects...]
select is undoable, NOT queryable, and NOT editable.
This command is used to put objects onto or off of the active list. If none of the five flags [-add, -af, -r, -d, -tgl] are specified, the default is to replace the objects on the active list with the given list of objects. When selecting a set as in "select set1", the behaviour is for all the members of the set to become selected instead of the set itself. If you want to select a set, the "-ne/noExpand" flag must be used. With the advent of namespaces, selection by name may be confusing. To clarify, without a qualified namespace, name lookup is limited to objects in the root namespace ":". There are really two parts of a name: the namespace and the name itself which is unique within the namespace. If you want to select objects in a specific namespace, you need to include the namespace separator ":". For example, 'select -r "foo*"' is trying to look for an object with the "foo" prefix in the root namespace. It is not trying to look for all objects in the namespace with the "foo" prefix. If you want to select all objects in a namespace (foo), use 'select "foo:*"'. Note: When the application starts up, there are several dependency nodes created by the system which must exist. These objects are not deletable but are selectable. All objects (dag and dependency nodes) in the scene can be obtained using the "ls" command without any arguments. When using the "-all", "adn/allDependencyNodes" or "-ado/allDagObjects" flags, only the deletable objects are selected. The non deletable object can still be selected by explicitly specifying their name as in "select time1;".None
Long name (short name) | Argument types | Properties | ||
---|---|---|---|---|
-all(-all)
|
|
|||
|
||||
-allDependencyNodes(-adn)
|
|
|||
|
||||
-allDagObjects(-ado)
|
|
|||
|
||||
-visible(-vis)
|
|
|||
|
||||
-hierarchy(-hi)
|
|
|||
|
||||
-add(-add)
|
|
|||
|
||||
-addFirst(-af)
|
|
|||
|
||||
-replace(-r)
|
|
|||
|
||||
-deselect(-d)
|
|
|||
|
||||
-toggle(-tgl)
|
|
|||
|
||||
-clear(-cl)
|
|
|||
|
||||
-noExpand(-ne)
|
|
|||
|
Flag can appear in Create mode of command | Flag can appear in Edit mode of command |
Flag can appear in Query mode of command | Flag can be used more than once in a command. |
// create some objects and add them to a set sphere -n sphere1; sphere -n sphere2; sets -n set1 sphere1 sphere2; // select all dag objects and all dependency nodes select -all; // clear the active list select -clear; // select sphere2 only if it is visible select -visible sphere2; // select a couple of objects regardless of visibilty select -r sphere1; select -add sphere2; // remove one of the spheres from the active list (using toggle) select -tgl sphere1; // remove the other sphere from the active list select -d sphere2; // the following selects all the members of set1 select set1; // this selects set1 itself select -ne set1; // Some examples selecting with namespaces: // create a namespace and an object in the namespace namespace -add foo; namespace -set foo; sphere -n bar; // 'select bar' will not select "bar" unless bar is in the // root namespace. You need to qualify the name with the // namespace (shown below). select foo:bar; // select all the objects in a namespace select "foo:*";