C++ API Reference

A plane equation. More...

#include <MPlane.h>

Public Member Functions

 MPlane ()
 Class default constructor. More...
 
 MPlane (const MPlane &)
 Class copy constructor. More...
 
MVector normal () const
 Returns the normal of the plane. More...
 
double distance () const
 Returns the distance of the plane along the normal. More...
 
void setPlane (double a, double b, double c, double d)
 Directly set the equation of the plane in the form: ax + by +cz + d = 0. More...
 
void setPlane (const MVector &n, double d)
 Set the equation of the plane from a normal and offset. More...
 
double distance (const MVector &) const
 Returns the unsigned distance from the plane to the specified point. More...
 
double directedDistance (const MVector &) const
 Returns the signed distance from the plane to the specified point. More...
 

Static Public Member Functions

static const char * className ()
 Returns the name of this class. More...
 

Detailed Description

A plane equation.

This class describes a mathematical plane.

Examples:
apiMeshShape/apiMeshShape.cpp, apiMeshShape/apiMeshShape.h, and richMoveCmd/richMoveCmd.cpp.

Constructor & Destructor Documentation

OPENMAYA_MAJOR_NAMESPACE_OPEN MPlane ( )

Class default constructor.

Create a new default plane.

MPlane ( const MPlane src)

Class copy constructor.

Create a new vector and initialize it to the same values as the given plane.

Parameters
[in]srcthe plane to copy

Member Function Documentation

MVector normal ( ) const

Returns the normal of the plane.

Returns
The plane's normal
Examples:
apiMeshShape/apiMeshShape.cpp, and richMoveCmd/richMoveCmd.cpp.
double distance ( ) const

Returns the distance of the plane along the normal.

Returns
The distance of the plane along the normal
void setPlane ( double  a,
double  b,
double  c,
double  d 
)

Directly set the equation of the plane in the form: ax + by +cz + d = 0.

Parameters
[in]aThe plane equation's x coefficent
[in]bThe plane equation's y coefficent
[in]cThe plane equation's z coefficent
[in]dThe plane equation's constant distance term
void setPlane ( const MVector n,
double  d 
)

Set the equation of the plane from a normal and offset.

Parameters
[in]nThe plane's normal
[in]dThe offset of the plane along the normal
double distance ( const MVector point) const

Returns the unsigned distance from the plane to the specified point.

Parameters
[in]pointThe point from which to calculate the distance
Returns
The distance from the specified point to the plane.
double directedDistance ( const MVector point) const

Returns the signed distance from the plane to the specified point.

Parameters
[in]pointThe point from which to calculate the distance
Returns
The distance from the specified point to the plane.
Examples:
apiMeshShape/apiMeshShape.cpp, and richMoveCmd/richMoveCmd.cpp.
const char * className ( )
static

Returns the name of this class.

Returns
The name of this class.

The documentation for this class was generated from the following files: