MFnDragField Class Reference
[OpenMayaFX - API module for effectsFunctionSet classes]

#include <MFnDragField.h>

Inheritance diagram for MFnDragField:

Inheritance graph
[legend]
Collaboration diagram for MFnDragField:

Collaboration graph
[legend]

List of all members.


Detailed Description

Function set for Drag Fields.

Function set for creation, edit, and query of Drag Fields.

A drag field exerts a friction, or braking force, proportional to the speed of a moving object.

Public Member Functions

virtual MFn::Type type () const
 Function set type.
virtual ~MFnDragField ()
 Destructor.
 MFnDragField ()
 Default constructor.
 MFnDragField (MObject &object, MStatus *ReturnStatus=NULL)
 Constructor.
 MFnDragField (const MDagPath &object, MStatus *ret=NULL)
 Constructor.
MVector direction (MStatus *ReturnStatus=NULL) const
MStatus setDirection (const MVector &dragDirection)
bool useDirection (MStatus *ReturnStatus=NULL) const
MStatus setUseDirection (bool enable)
 MFnDragField (const MObject &object, MStatus *ret=NULL)
 Constructor.

Protected Member Functions

virtual const char * className () const
 Class name.


Constructor & Destructor Documentation

MFnDragField::~MFnDragField (  )  [virtual]

Destructor.

Class destructor.

MFnDragField::MFnDragField ( MObject object,
MStatus ReturnStatus = NULL 
)

Constructor.

Class constructor that initializes the function set to the given MObject.

Parameters:
[in] object The MObject to attach the function set to
[out] ReturnStatus the return status
Status Codes:

MFnDragField::MFnDragField ( const MDagPath object,
MStatus ReturnStatus = NULL 
)

Constructor.

Class constructor that initializes the function set to the given constant MDagPath object.

Parameters:
[in] object The const MDagPath to attach the function set to
[out] ReturnStatus The return status
Status Codes:

MFnDragField::MFnDragField ( const MObject object,
MStatus ReturnStatus = NULL 
)

Constructor.

Class constructor that initializes the function set to the given MObject.

Parameters:
[in] object The MObject to attach the function set to
[out] ReturnStatus the return status
Status Codes:


Member Function Documentation

MFn::Type MFnDragField::type (  )  const [virtual]

Function set type.

Return the class type : MFn::kDrag

Reimplemented from MFnField.

MVector MFnDragField::direction ( MStatus ReturnStatus = NULL  )  const

Returns the direction of the drag force's influence along the x, y, and z axes. You must have the Use Direction setting turned on for this attribute to take effect.

Parameters:
[out] ReturnStatus Status code
Returns:
A vector representing direction.
Status Codes:

MStatus MFnDragField::setDirection ( const MVector dragDirection  ) 

Sets the direction of the drag force's influence along the x, y, and z axes. You must have the Use Direction setting turned on for this attribute to take effect.

Parameters:
[in] dragDirection A vector representing direction.
Returns:
Status code
Status Codes:

bool MFnDragField::useDirection ( MStatus ReturnStatus = NULL  )  const

Returns true if the braking force is exerted only against the component of the object's velocity that lies along the direction of the drag force.

Parameters:
[out] ReturnStatus Status code
Returns:
  • true Use the direction setting to determine the braking force.
  • false Use the objects velocity to determine the braking force.
Status Codes:

MStatus MFnDragField::setUseDirection ( bool  enable  ) 

Enables the braking force to be exerted only against the component of the object's velocity that lies along the direction setting of the drag force.

Parameters:
[in] enable Flag to enable or disable direction setting.
Returns:
Status code
Status Codes:


Autodesk® Maya® 2009 © 1997-2008 Autodesk, Inc. All rights reserved. Generated with doxygen 1.5.6