Go to: Synopsis. Return value. Related. Flags. Python examples.
viewCamera(
[camera]
, [move=name], [sideView=boolean], [topView=boolean])
Note: Strings representing object names and arguments must be separated by commas. This is not depicted in the synopsis.
viewCamera is undoable, NOT queryable, and NOT editable.
The viewCamera command is used to position a camera to look directly at the side or top of another camera. This is primarily useful for the user when he or she is setting depth-of-field and clipping planes, if they are being used.The default behaviour: If no other flags are specified, the camera in the active panel is moved and the -t is presumed. If there is a camera selected, it is used as the target camera.
None
Long name (short name) | Argument types | Properties | ||
---|---|---|---|---|
move(m)
|
name
|
![]() |
||
|
||||
sideView(s)
|
boolean
|
![]() |
||
|
||||
topView(t)
|
boolean
|
![]() |
||
|
![]() |
![]() |
![]() |
![]() |
import maya.cmds as cmds cmds.viewCamera( 'cameraShape2', m='cameraShape1' ) # Move current view camera to top of camera1 cmds.viewCamera( 'camera1' )