Go to: Synopsis. Return value. Related. Flags. Python examples.

Synopsis

nurbsCube([axis=[linear, linear, linear]], [caching=boolean], [constructionHistory=boolean], [degree=int], [heightRatio=float], [lengthRatio=float], [name=string], [nodeState=int], [object=boolean], [patchesU=int], [patchesV=int], [pivot=[linear, linear, linear]], [polygon=int], [width=linear])

Note: Strings representing object names and arguments must be separated by commas. This is not depicted in the synopsis.

nurbsCube is undoable, queryable, and editable.

The nurbsCube command creates a new NURBS Cube made up of six planes. It creates an unit cube with center at origin by default.

Return value

string[]Object name and node name

In query mode, return type is based on queried flag.

Related

cone, cylinder, nurbsPlane, sphere, torus

Flags

axis, caching, constructionHistory, degree, heightRatio, lengthRatio, name, nodeState, object, patchesU, patchesV, pivot, polygon, width
Long name (short name) Argument types Properties
width(w) linear createqueryedit
Width of the object
Default: 1.0
lengthRatio(lr) float createqueryedit
Ratio of "length" to "width"
Default: 1.0
heightRatio(hr) float createqueryedit
Ratio of "height" to "width"
Default: 1.0
patchesU(u) int createqueryedit
Number of sections in U
Default: 1
patchesV(v) int createqueryedit
Number of sections in V
Default: 1
degree(d) int createqueryedit
The degree of the resulting surface. 1 - linear, 2 - quadratic, 3 - cubic, 5 - quintic, 7 - heptic
Default: 3
pivot(p) [linear, linear, linear] createqueryedit
The primitive's pivot point
axis(ax) [linear, linear, linear] createqueryedit
The primitive's axis
Advanced flags
caching(cch) boolean createqueryedit
Modifies the node caching mode. See the node documentation for more information.
Note: For advanced users only.
nodeState(nds) int createqueryedit
Modifies the node state. See the node documentation for more information.
Note: For advanced users only.
Common flags
name(n) string create
Sets the name of the newly-created node. If it contains namespace path, the new node will be created under the specified namespace; if the namespace does not exist, it will be created.
constructionHistory(ch) boolean create
Turn the construction history on or off
object(o) boolean create
Create the result, or just the dependency node
polygon(po) int create
The value of this argument controls the type of the object created by this operation
  • 0: nurbs surface
  • 1: polygon (use nurbsToPolygonsPref to set the parameters for the conversion)
  • 2: subdivision surface (use nurbsToSubdivPref to set the parameters for the conversion)
  • 3: Bezier surface
  • 4: subdivision surface solid (use nurbsToSubdivPref to set the parameters for the conversion)

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.

Python examples

import maya.cmds as cmds

cmds.nurbsCube()
cmds.nurbsCube( w=3, hr=5 )
cmds.nurbsCube( w=10, p=(0, 0, 1) )
cmds.nurbsCube( d=1, u=3, v=5, w=5 )