pymel.core.nodetypes.SkinCluster

Inheritance diagram of SkinCluster

class SkinCluster(*args, **kwargs)

class counterpart of mel function skinCluster

The skinCluster command is used for smooth skinning in maya. It binds the selected geometry to the selected joints or skeleton by means of a skinCluster node. Each point of the bound geometry can be affected by any number of joints. The extent to which each joint affects the motion of each point is regulated by a corresponding weight factor. Weight factors can be modified using the skinPercent command. The command returns the name of the new skinCluster.The skinCluster binds only a single geometry at a time. Thus, to bind multiple geometries, multiple skinCluster commands must be issued.Upon creation of a new skinCluster, the command can be used to add and remove transforms (not necessarily joints) that influence the motion of the bound skin points.The skinCluster command can also be used to adjust parameters such as the dropoff, nurbs samples, polygon smoothness on a particular influence object. Note: Any custom weights on a skin point that the influence object affects will be lost after adjusting these parameters.

addInfluence(val=True, **kwargs)

The specified transform or joint will be added to the list of transforms that influence the bound geometry. The maximum number of influences will be observed and only the weights of the cv’s that the specified transform effects will change. This flag is multi-use.

Derived from mel command maya.cmds.skinCluster

addToSelection(val=True, **kwargs)

When used in conjunction with the selectInfluenceVerts flag, causes the vertices afftected by the influence to be added to the current selection, without first de-selecting other vertices.

Derived from mel command maya.cmds.skinCluster

after(val=True, **kwargs)

If the default behavior for insertion/appending into/onto the existing chain is not what you want then you can use this flag to force the command to stick the deformer node after the selected node in the chain even if a new geometry shape has to be created in order to do so. Works in create mode (and edit mode if the deformer has no geometry added yet).

Derived from mel command maya.cmds.skinCluster

afterReference(val=True, **kwargs)

The -afterReference flag is used to specify deformer ordering in a hybrid way that choses between -before and -after automatically. If the geometry being deformed is referenced then -after mode is used in adding the new deformer otherwise -before mode is used. The net effect when using -afterReference to build deformer chains is that internal shape nodes in the deformer chain will only appear at reference file boundaries, leading to lightweight deformer networks that may be more amicable to reference swapping.

Derived from mel command maya.cmds.skinCluster

baseShape(val=True, **kwargs)

This flag can be used in conjunction with the -addInfluence flag to specify the shape that will be used as the base shape when an influence object with geometry is added to the skinCluster. If the flag is not used then the command will make a copy of the influence object’s shape and use that as a base shape.

Derived from mel command maya.cmds.skinCluster

before(val=True, **kwargs)

If the default behavior for insertion/appending into/onto the existing chain is not what you want then you can use this flag to force the command to stick the deformer node before the selected node in the chain even if a new geometry shape has to be created in order to do so. Works in create mode (and edit mode if the deformer has no geometry added yet).

Derived from mel command maya.cmds.skinCluster

forceNormalizeWeights(val=True, **kwargs)

If the normalization mode is none or post, it is possible (indeed likely) for the weights in the skin cluster to no longer add up to 1. This flag forces all weights to add back to 1 again.

Derived from mel command maya.cmds.skinCluster

frontOfChain(val=True, **kwargs)

This command is used to specify that the new deformer node should be placed ahead (upstream) of existing deformer and skin nodes in the shape’s history (but not ahead of existing tweak nodes). The input to the deformer will be the upstream shape rather than the visible downstream shape, so the behavior of this flag is the most intuitive if the downstream deformers are in their reset (hasNoEffect) position when the new deformer is added. Works in create mode (and edit mode if the deformer has no geometry added yet).

Derived from mel command maya.cmds.skinCluster

getBindMethod(**kwargs)

This flag sets the binding method. 0 - Closest distance between a joint and a point of the geometry. 1 - Closest distance between a joint, considering the skeleton hierarchy, and a point of the geometry. 2 - Surface heat map diffusion.

Derived from mel command maya.cmds.skinCluster

getBlendWeights(path, components)

This method returns weights from skinCluster’s blend weight array. These weights are used to determine the blending between classical linear skinning and dual quaternion bases skinning on a per vertex basis. The function returns the weights associated with the components passed. The components are defined on the object whose dagPath is specified.

Parameters :
path : PyNode

path to object deformed by the skinCluster

components : PyNode

the components to return weights for

Return type:

float list

Derived from api method maya.OpenMayaAnim.MFnSkinCluster.getBlendWeights

getDeformerTools(**kwargs)

Returns the name of the deformer tool objects (if any) as string string ...

Derived from mel command maya.cmds.skinCluster

getDropoffRate(**kwargs)

Sets the rate at which the influence of a transform drops as the distance from that transform increases. The valid range is between 0.1 and 10.0. In Create mode it sets the dropoff rate for all the bound joints. In Edit mode the flag is used together with the inf/influence flag to set the dropoff rate of a particular influence. Note: When the flag is used in Edit mode, any custom weights on the skin points the given transform influences will be lost.

Derived from mel command maya.cmds.skinCluster

getExclusive(**kwargs)

Puts the deformation set in a deform partition.

Derived from mel command maya.cmds.skinCluster

getGeometry(**kwargs)

The specified object will be added to the list of objects being deformed by this deformer object, unless the -rm flag is also specified. When queried, this flag returns string string string ...

Derived from mel command maya.cmds.skinCluster

getGeometryIndices(**kwargs)

Complements the -geometry flag in query mode. Returns the multi index of each geometry.

Derived from mel command maya.cmds.skinCluster

getIgnoreHierarchy(**kwargs)

Deprecated. Use bindMethod flag instead. Disregard the place of the joints in the skeleton hierarchy when computing the closest joints that influence a point of the geometry.

Derived from mel command maya.cmds.skinCluster

getInfluence(**kwargs)

This flag specifies the influence object that will be used for the current edit operation. In query mode, returns a string array of the influence objects (joints and transform). In query mode, this flag can accept a value.

Derived from mel command maya.cmds.skinCluster

getLockWeights(**kwargs)

Lock the weights of the specified influence object to their current value or to the value specified by the -weight flag.

Derived from mel command maya.cmds.skinCluster

getMaximumInfluences(**kwargs)

Sets the maximum number of transforms that can influence a point (have non-zero weight for the point) when the skinCluster is first created or a new influence is added. Note: When this flag is used in Edit mode any custom weights will be lost and new weights will be reassigned to the whole skin.

Derived from mel command maya.cmds.skinCluster

getNormalizeWeights(**kwargs)

This flag sets the normalization mode. 0 - none, 1 - interactive, 2 - post (default) Interactive normalization makes sure the weights on the influences add up to 1.0, always. Everytime a weight is changed, the weights are automatically normalized. This may make it difficult to perform weighting operations, as the normalization may interfere with the weights the user has set. Post normalization leaves the weights the user has set as is, and only normalizes the weights at the moment it is needed (by dividing by the sum of the weights). This makes it easier for users to weight their skins.

Derived from mel command maya.cmds.skinCluster

getObeyMaxInfluences(**kwargs)

When true, the skinCluster will continue to enforce the maximum influences each time the user modifies the weight, so that any given point is only weighted by the number of influences in the skinCluster’s maximumInfluences attribute.

Derived from mel command maya.cmds.skinCluster

getPointsAffectedByInfluence(path)

During deformation, the skinCluster algorithm is applied for a given influence object on all points in the deformer’s set whose weights are non-zero. This method allows the user to query the non-zero weights for a particular influence object.

Parameters :
path : PyNode

path of the influence object

Return type:

(SelectionSet, float list)

Derived from api method maya.OpenMayaAnim.MFnSkinCluster.getPointsAffectedByInfluence

getSkinMethod(**kwargs)

This flag set the skinning method. 0 - classical linear skinning (default). 1 - dual quaternion (volume preserving), 2 - a weighted blend between the two.

Derived from mel command maya.cmds.skinCluster

getWeightedInfluence(**kwargs)

This flag returns a string array of the influence objects (joints and transform) that have non-zero weighting.

Derived from mel command maya.cmds.skinCluster

getWeights(geometry, influenceIndex=None)
ignoreBindPose(val=True, **kwargs)

This flag is deprecated and no longer used. It will be ignored if used.

Derived from mel command maya.cmds.skinCluster

indexForInfluenceObject(mpath)

Returns the logical index of the matrix array attribute where the specified influence object is attached.

Parameters :
mpath : PyNode

path of the influence object

Return type:

int

Derived from api method maya.OpenMayaAnim.MFnSkinCluster.indexForInfluenceObject

influenceObjects()

Returns an array of paths to the influence objects for the skinCluster.

Return type:(int, PyNode list)

Derived from api method maya.OpenMayaAnim.MFnSkinCluster.influenceObjects

moveJointsMode(val=True, **kwargs)

If set to true, puts the skin into a mode where joints can be moved without modifying the skinning. If set to false, takes the skin out of move joints mode.

Derived from mel command maya.cmds.skinCluster

numInfluenceObjects()
nurbsSamples(val=True, **kwargs)

Sets the number of sample points that will be used along an influence curve or in each direction on an influence NURBS surface to influence the bound skin. The more the sample points the more closely the skin follows the influence NURBS curve/surface.

Derived from mel command maya.cmds.skinCluster

parallel(val=True, **kwargs)

Inserts the new deformer in a parallel chain to any existing deformers in the history of the object. A blendShape is inserted to blend the parallel results together. Works in create mode (and edit mode if the deformer has no geometry added yet).

Derived from mel command maya.cmds.skinCluster

polySmoothness(val=True, **kwargs)

This flag controls how accurately the skin control points follow a given polygon influence object. The higher the value of polySmoothnmess the more rounded the deformation resulting from a polygonal influence object will be.

Derived from mel command maya.cmds.skinCluster

prune(val=True, **kwargs)

Removes any points not being deformed by the deformer in its current configuration from the deformer set.

Derived from mel command maya.cmds.skinCluster

remove(val=True, **kwargs)

Specifies that objects listed after the -g flag should be removed from this deformer.

Derived from mel command maya.cmds.skinCluster

removeFromSelection(val=True, **kwargs)

When used in conjunction with the selectInfluenceVerts flag, causes the vertices afftected by the influence to be removed from the current selection.

Derived from mel command maya.cmds.skinCluster

removeInfluence(val=True, **kwargs)

Remove the specified transform or joint from the list of transforms that influence the bound geometry The weights for the affected points are renormalized. This flag is multi-use.

Derived from mel command maya.cmds.skinCluster

selectInfluenceVerts(val=True, **kwargs)

Given the name of a transform, this will select the verts or control points being influenced by this transform, so users may visualize which vertices are being influenced by the transform.

Derived from mel command maya.cmds.skinCluster

setBlendWeights(path, components, weights)

This method sets weights in skinCluster’s blend weight array. These weights are used to determine the blending between classical linear skinning and dual quaternion bases skinning on a per vertex basis. The function sets the weights for the given components of the object whose dagPath is specified. The array size should match the number of components passed. Failing this, it will set the smaller of the two.

Parameters :
path : PyNode

path to object deformed by the skinCluster

components : PyNode

the components list for the new weight values

weights : float list

the weight values (one per component in the order given)

Derived from api method maya.OpenMayaAnim.MFnSkinCluster.setBlendWeights

setDropoffRate(val=True, **kwargs)

Sets the rate at which the influence of a transform drops as the distance from that transform increases. The valid range is between 0.1 and 10.0. In Create mode it sets the dropoff rate for all the bound joints. In Edit mode the flag is used together with the inf/influence flag to set the dropoff rate of a particular influence. Note: When the flag is used in Edit mode, any custom weights on the skin points the given transform influences will be lost.

Derived from mel command maya.cmds.skinCluster

setGeometry(val=True, **kwargs)

The specified object will be added to the list of objects being deformed by this deformer object, unless the -rm flag is also specified. When queried, this flag returns string string string ...

Derived from mel command maya.cmds.skinCluster

setInfluence(val=True, **kwargs)

This flag specifies the influence object that will be used for the current edit operation. In query mode, returns a string array of the influence objects (joints and transform). In query mode, this flag can accept a value.

Derived from mel command maya.cmds.skinCluster

setLockWeights(val=True, **kwargs)

Lock the weights of the specified influence object to their current value or to the value specified by the -weight flag.

Derived from mel command maya.cmds.skinCluster

setMaximumInfluences(val=True, **kwargs)

Sets the maximum number of transforms that can influence a point (have non-zero weight for the point) when the skinCluster is first created or a new influence is added. Note: When this flag is used in Edit mode any custom weights will be lost and new weights will be reassigned to the whole skin.

Derived from mel command maya.cmds.skinCluster

setNormalizeWeights(val=True, **kwargs)

This flag sets the normalization mode. 0 - none, 1 - interactive, 2 - post (default) Interactive normalization makes sure the weights on the influences add up to 1.0, always. Everytime a weight is changed, the weights are automatically normalized. This may make it difficult to perform weighting operations, as the normalization may interfere with the weights the user has set. Post normalization leaves the weights the user has set as is, and only normalizes the weights at the moment it is needed (by dividing by the sum of the weights). This makes it easier for users to weight their skins.

Derived from mel command maya.cmds.skinCluster

setObeyMaxInfluences(val=True, **kwargs)

When true, the skinCluster will continue to enforce the maximum influences each time the user modifies the weight, so that any given point is only weighted by the number of influences in the skinCluster’s maximumInfluences attribute.

Derived from mel command maya.cmds.skinCluster

setSkinMethod(val=True, **kwargs)

This flag set the skinning method. 0 - classical linear skinning (default). 1 - dual quaternion (volume preserving), 2 - a weighted blend between the two.

Derived from mel command maya.cmds.skinCluster

setWeights(geometry, influnces, weights, normalize=True)
smoothWeights(val=True, **kwargs)

This flag is used to detect sudden jumps in skin weight values, which often indicates bad weighting, and then smooth out those jaggies in skin weights. The argument is the error tolerance ranging from 0 to 1. A value of 1 means that the algorithm will smooth a vertex only if there is a 100% change in weight values from its neighbors. The recommended default to use is 0.5 (50% change in weight value from the neighbors).

Derived from mel command maya.cmds.skinCluster

smoothWeightsMaxIterations(val=True, **kwargs)

This flag is valid only with the smooth weights flag. It is possible that not all the vertices detected as needing smoothing can be smoothed in 1 iteration (because all of their neighbors also have bad weighting and need to be smoothed). With more iterations, more vertices can be smoothed. This flag controls the maximum number of iterations the algorithm will attempt to smooth weights. The default is 2 for this flag.

Derived from mel command maya.cmds.skinCluster

unbind(val=True, **kwargs)

Unbinds the geometry from the skinCluster and deletes the skinCluster node

Derived from mel command maya.cmds.skinCluster

unbindKeepHistory(val=True, **kwargs)

Unbinds the geometry from the skinCluster, but keeps the skinCluster node so that its weights can be used when the skin is rebound. To rebind, use the skinCluster command.

Derived from mel command maya.cmds.skinCluster

useGeometry(val=True, **kwargs)

When adding an influence to a skinCluster, use the geometry parented under the influence transform to determine the weight dropoff of that influence.

Derived from mel command maya.cmds.skinCluster

weight(val=True, **kwargs)

This flag is only valid in conjunction with the -addInfluence flag. It sets the weight for the influence object that is being added.

Derived from mel command maya.cmds.skinCluster

Previous topic

pymel.core.nodetypes.SkinBinding

Next topic

pymel.core.nodetypes.SmoothCurve

Core

Core Modules

Other Modules

This Page