Go to: Synopsis. Return value. Flags. Python examples.
viewManip([bottomLeft=boolean], [bottomRight=boolean], [compassAngle=float], [dragSnap=boolean], [drawCompass=boolean], [fitToView=boolean], [frontParameters=string], [goDefault=boolean], [goHome=boolean], [homeParameters=string], [levelCamera=boolean], [minOpacity=float], [namespace=string], [postCommand=string], [preCommand=string], [preserveSceneUp=boolean], [resetFront=boolean], [resetHome=boolean], [restoreCenter=boolean], [selectionLockParameters=string], [setFront=boolean], [setHome=boolean], [size=string], [toggleSelectionLock=boolean], [topLeft=boolean], [topRight=boolean], [visible=boolean], [zoomToFitScene=boolean])
Note: Strings representing object names and arguments must be separated by commas. This is not depicted in the synopsis.
viewManip is undoable, queryable, and NOT editable.
Mel access to the view cube manipulator.
None
In query mode, return type is based on queried flag.
bottomLeft, bottomRight, compassAngle, dragSnap, drawCompass, fitToView, frontParameters, goDefault, goHome, homeParameters, levelCamera, minOpacity, namespace, postCommand, preCommand, preserveSceneUp, resetFront, resetHome, restoreCenter, selectionLockParameters, setFront, setHome, size, toggleSelectionLock, topLeft, topRight, visible, zoomToFitScene
Long name (short name) |
Argument types |
Properties |
|
bottomLeft(bl)
|
boolean
|
|
|
Positions the cube in the bottom left of the screen.
|
|
bottomRight(br)
|
boolean
|
|
|
Positions the cube in the bottom right of the screen.
|
|
compassAngle(ca)
|
float
|
|
|
Angle (in degrees) to rotate the compass.
|
|
dragSnap(ds)
|
boolean
|
|
|
Enable snapping of orbit direction to view cube part directions during drag operation.
|
|
drawCompass(dc)
|
boolean
|
|
|
Show compass below the view cube.
|
|
fitToView(ftv)
|
boolean
|
|
|
Fits the scene bounding box to the active view.
|
|
frontParameters(fp)
|
string
|
|
|
Parameter string for the front position
|
|
goDefault(gd)
|
boolean
|
|
|
Go to the default position
|
|
goHome(gh)
|
boolean
|
|
|
homeParameters(hp)
|
string
|
|
|
Parameter string for the home position
|
|
levelCamera(lc)
|
boolean
|
|
|
Flattens the camera view rotation relative to the ground plane.
|
|
minOpacity(mo)
|
float
|
|
|
Opacity level (in range [0,1]) on view cube when the cursor is away from it (it is fully opaque when the cursor is in the view cube area).
|
|
namespace(ns)
|
string
|
|
|
Namespace to use for the object
|
|
postCommand(p)
|
string
|
|
|
Command to run after moving
|
|
preCommand(pr)
|
string
|
|
|
Command to run before moving
|
|
preserveSceneUp(psu)
|
boolean
|
|
|
Specify whether the scene "up" direction should be preserved
|
|
resetFront(rf)
|
boolean
|
|
|
resetHome(rh)
|
boolean
|
|
|
restoreCenter(rc)
|
boolean
|
|
|
Repositions the pivot point for orbiting/tumbling the scene to the center
of the scene's bounding box.
|
|
selectionLockParameters(slp)
|
string
|
|
|
String containing the selection lock parameters
|
|
setFront(sf)
|
boolean
|
|
|
Set the front view to the current one
|
|
setHome(sh)
|
boolean
|
|
|
Set the home view to the current one
|
|
size(s)
|
string
|
|
|
Set or query the size of the View Cube, which can be one of "tiny",
"small", "normal", "large" or "auto". When set to "auto" the View Cube
will be automatically set to the size most appropriate for the view.
|
|
toggleSelectionLock(tsl)
|
boolean
|
|
|
Toggle the selection lock
|
|
topLeft(tl)
|
boolean
|
|
|
Positions the cube in the top left of the screen.
|
|
topRight(tr)
|
boolean
|
|
|
Positions the cube in the top right of the screen.
|
|
visible(v)
|
boolean
|
|
|
Shows/hides the view manip.
|
|
zoomToFitScene(zf)
|
boolean
|
|
|
Zoom the camera during animated transitions to fit the scene object in the viewport.
|
|
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 have multiple arguments, passed either as a tuple or a list.
|
import maya.cmds as cmds
#Position the view cube in the top left of the screen and set it to fully opaque
cmds.viewManip(topLeft=True, minOpacity=1)