class MClothConstraintCmd

Jump to documentation

: public MClothConstraint Interface for cloth solver constraint command.

Inheritance:

MClothConstraintCmd < MClothConstraint

public members:

MClothConstraintCmd ( MClothParticle * particle )
MClothConstraintCmd ( MClothParticle * particle, double shear, double damp )
virtual ~MClothConstraintCmd ()
virtual MPoint desired_position ( double frame )
void setSoft (bool soft)
bool isSoft () const
void setStrength ( double shear, double damp )
double getShear () const
double getDamp () const
bool userDefined ()
MStatus execute ()
void setCustomConstraintBehavior ( MClothConstraintBridge * impl)
MClothConstraintBridge * getCustomConstraintBehavior () const

Inherited from MClothConstraint:

public members:

virtual MStatus execute ()
virtual bool userDefined ()
MClothParticle * getParticle ( MStatus * ReturnStatus = NULL ) const

Documentation

Interface for cloth solver constraint command.
Description

Interface that must be implemented by solver writers to override custom behavior for various constraints. MayaCloth plugin implements MClothConstraintCmd in plugin (PinConstraint, TransformConstraint).

Solver should provide MClothConstraintBridge object to override custom behavior during constraint evaluation. MClothConstraintBridge object should get set in addCommand method of MClothSystem implementation.

Functions

MClothConstraintCmd:: MClothConstraintCmd ( MClothParticle * particle, double shear, double damp)

Description

Class constructor.

MClothConstraintCmd:: MClothConstraintCmd ( MClothParticle * particle)

Description

Class constructor.

MClothConstraintCmd:: ~MClothConstraintCmd ()

Description

Class destructor.

void MClothConstraintCmd:: setSoft (bool soft)

Description

set soft constraint.

Arguments

  • soft The soft value either true or false.

bool MClothConstraintCmd:: isSoft () const

Description

Check for soft constraint.

Return Value

  • bool true or false.

void MClothConstraintCmd:: setStrength (double soft, double damp)

Description

Set strength of constraint.

Arguments

  • soft The shear value.
  • damp The damp value.

bool MClothConstraintCmd:: userDefined ()

Description

Check for user defined constraint.

Return Value

  • bool true or false.

double MClothConstraintCmd:: getShear () const

Description

Get shear value associated with this constraint.

Return Value

  • double shear value.

double MClothConstraintCmd:: getDamp () const

Description

Get damp value associated with this constraint.

Return Value

  • double damp value.

MStatus MClothConstraintCmd:: execute ()

Description

Execute the constraint command.

void MClothConstraintCmd:: setCustomConstraintBehavior ( MClothConstraintBridge * bridge)

Description

Set the custom constraint behavior object.

Arguments

  • MClothConstraintBridge The MClothConstraintBridge object to set.

MClothConstraintBridge * MClothConstraintCmd:: getCustomConstraintBehavior () const

Description

Get the custom constraint behavior object.

Return Value

  • MClothConstraintBridge MClothConstraintBridge object.

MPoint MClothConstraintCmd:: desired_position ( double frame )

Description

This method returns the desired position of constraint at given frame.

Arguments

  • frame The frame at which constraint gets evaluated.

Return Value

  • MPoint The desired position.

This class has no child classes.


Autodesk® Maya® 2008 © 1997-2007 Autodesk, Inc. All rights reserved. doc++ Copyright