- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Examples

- Class List
- Class Hierarchy
- Class Members

Public Member Functions | Static Public Member Functions | Friends

# MRichSelection Class Reference
OpenMaya - API module for common classes

Search for all occurrences

## Detailed Description

Selection list supporting soft selection and symmetry.

This class implements a selection list that support soft selection and symmetry.

The rich selection is split into two halves: the "normal" side, and an optional symmetric component. Components on both sides can include weight data which is used to specify both the amount of influence and the proximity to the centre of symmetry.

In addition to the selected objects, the rich selection also includes information about the axis of symmetry so that operations can determine how to process any symmetric selection (e.g. reflect transformations, etc).

`#include <MRichSelection.h>`

List of all members.

## Public Member Functions
| MRichSelection ()
| Class constructor.
| MRichSelection (const MRichSelection &src)
| Copy constructor.
virtual | ~MRichSelection ()
| Class destructor.
MStatus | getSelection (MSelectionList &selection) const
| Returns a copy of the non-symmetry component of the rich selection.
MStatus | getSymmetry (MSelectionList &symmetry) const
| Returns a copy of the symmetry component of the rich selection.
MStatus | getSymmetryMatrix (MMatrix &symmetryMatrix, MSpace::Space &space) const
| Returns the raw symmetry matrix to use for the symmetric components of the rich selection.
MStatus | getSymmetryMatrix (const MDagPath &path, MSpace::Space space, MMatrix &symmetryMatrix) const
| Returns the symmetry matrix to use for the symmetric component of the specified DAG object.
MStatus | getSymmetryPlane (const MDagPath &path, MSpace::Space space, MPlane &plane) const
| Returns the plane of symmetry.
MStatus | clear ()
| This method empties the rich selection.
## Static Public Member Functions
static const char * | className ()
| Returns the name of this class.
## Friends
class | MGlobal Search for all occurrences

## Constructor & Destructor Documentation

MRichSelection | ( |  | ) |

Class constructor.

Creates an empty rich selection.

MRichSelection | ( | const MRichSelection & | src | ) |

Copy constructor.

This constructor will copy the contents of the given selection list into the newly created selection list.

Parameters:

  [in] | src | the rich selection to be copied.

~MRichSelection | ( |  | ) | `[virtual]`

Class destructor.

Removes the selection list.

## Member Function Documentation

MStatus getSelection | ( | MSelectionList & | selection | ) | const

Search for all occurrences

Returns a copy of the non-symmetry component of the rich selection.

Parameters:

  [out] | selection | Storage for the selection list

Returns:
  Status code

Status Codes:
  - MS::kSuccess Selection list was successfully returned
  - MS::kFailure Error getting the selection list

MStatus getSymmetry | ( | MSelectionList & | symmetry | ) | const

Search for all occurrences

Returns a copy of the symmetry component of the rich selection.

Parameters:

  [out] | symmetry | Storage for the symmetric selection list

Returns:
  Status code

Status Codes:
  - MS::kSuccess Selection list was successfully returned
  - MS::kFailure Error getting the selection list

MStatus getSymmetryMatrix | ( | MMatrix & | symmetryMatrix,
|  | MSpace::Space & | space
| ) |  | const

Search for all occurrences

Returns the raw symmetry matrix to use for the symmetric components of the rich selection.

The caller is responsible for handling any necessary transformation space conversions when using this version of getSymmetryMatrix.

Parameters:

  [out] | symmetryMatrix | Storage for the symmetry matrix
  [out] | space | The transformation space of the symmetryMatrix

Returns:
  Status code

Status Codes:
  - MS::kSuccess Symmetry matrix was successfully returned
  - MS::kFailure Error getting the symmetry matrix

MStatus getSymmetryMatrix | ( | const MDagPath & | path,
|  | MSpace::Space | space,
|  | MMatrix & | symmetryMatrix
| ) |  | const

Search for all occurrences

Returns the symmetry matrix to use for the symmetric component of the specified DAG object.

This method handles any matrix space conversions for you.

Parameters:

  [in] | path | The DAG path the matrix should be calculated for
  [in] | space | The space the matrix should be calculated in. Only kWorld and kObject are currently supported.
  [out] | symmetryMatrix | Storage for the symmetry matrix

Returns:
  Status code

Status Codes:
  - MS::kSuccess Symmetry matrix was successfully returned
  - MS::kFailure Error getting the symmetry matrix

MStatus getSymmetryPlane | ( | const MDagPath & | path,
|  | MSpace::Space | space,
|  | MPlane & | symmetryPlane
| ) |  | const

Search for all occurrences

Returns the plane of symmetry.

This can be used to enforce seam weights in tools that support symmetry. Note that the direction of the plane carries no significance (specifically, having a positive offset from the plane does not imply a point is part of the non-symmetric selection).

Parameters:

  [in] | path | The DAG path the plane should be calculated for
  [in] | space | The space the plane should be calculated in. Only kWorld and kObject are currently supported.
  [out] | symmetryPlane | Storage for the symmetry plane

Returns:
  Status code

Status Codes:
  - MS::kSuccess Symmetry plane was successfully returned
  - MS::kFailure Error getting the symmetry plane

MStatus clear | ( |  | ) |

Search for all occurrences

This method empties the rich selection.

Returns:
  Status flag

Status Codes:
  - MS::kSuccess The list was successfully reset.
  - MS::kFailure Error resetting list.

const char * className | ( |  | ) | `[static]`

Search for all occurrences

Returns the name of this class.

Returns:
  The name of this class.

MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection
MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection MRichSelection