pymel.core.context.polyCreateFacetCtx

polyCreateFacetCtx(*args, **kwargs)

Create a new context to create polygonal objects In query mode, return type is based on queried flag.

Flags:

Long Name / Short Name Argument Types Properties
append / ap bool ../../../_images/create.gif ../../../_images/query.gif ../../../_images/edit.gif
  Allows to switch to polyAppendFacetCtx tool
exists / ex bool ../../../_images/create.gif
  Returns true or false depending upon whether the specified object exists. Other flags are ignored.
image1 / i1 unicode ../../../_images/create.gif ../../../_images/query.gif ../../../_images/edit.gif
  First of three possible icons representing the tool associated with the context.
image2 / i2 unicode ../../../_images/create.gif ../../../_images/query.gif ../../../_images/edit.gif
  Second of three possible icons representing the tool associated with the context.
image3 / i3 unicode ../../../_images/create.gif ../../../_images/query.gif ../../../_images/edit.gif
  Third of three possible icons representing the tool associated with the context.
maximumNumberOfPoints / mp int ../../../_images/create.gif ../../../_images/query.gif ../../../_images/edit.gif
  Allows the ability to set a upper bound on the number of points in interactively place before polygon is created. A value less than 2 will mean that there is no upper bound.
planarConstraint / pc bool ../../../_images/create.gif ../../../_images/query.gif ../../../_images/edit.gif
  allows/avoid new facet to be non-planar. If on, all new points will be projected onto current facet plane.
subdivision / s int ../../../_images/create.gif ../../../_images/query.gif ../../../_images/edit.gif
  Number of subdivisions for each edge. Default:1
texture / tx int ../../../_images/create.gif ../../../_images/query.gif ../../../_images/edit.gif
  What texture mechanism to be applied 0=No textures, 1=Normalized, Undistorted textures 2=Unitized textures Default:0 Flag can have multiple arguments, passed either as a tuple or a list.

Derived from mel command maya.cmds.polyCreateFacetCtx

Example:

import pymel.core as pm

# Create a new poly facet create context, set it to add four vertices per new edge, then switch to it
pm.polyCreateFacetCtx('polyCreateFacetCtx1', s=4)
pm.setToolTo('polyCreateFacetCtx1')