Class NURBSFilletSurface

3DS Max Plug-In SDK

Class NURBSFilletSurface

See Also: Class NURBSSurface.

class NURBSFilletSurface : public NURBSSurface

Description:

This class is available in release 3.0 and later only.

This class provides access to the NURBS Fillet Surface. Methods are provided to get / set the parent surfaces, get / set the radius, and get / set the trim and trim flip settings.

Methods:

protected:

Prototype:

void Clean(NURBSIdTab ids);

Remarks:

This method is available in release 3.0 and later only.

This methods breaks the relation between this NURBSObject and a NURBSSet.

Parameters:

NURBSIdTab ids

A table with the IDs of each object in the NURBSSet.

public:

Prototype:

NURBSFilletSurface();

Remarks:

Constructor. The data members are initialized as follows:

 mType = kNFilletSurface;

 mpObject = NULL;

 mpNSet = NULL;

 mParentId[0] = mParentId[1] = 0;

 mParentIndex[0] = mParentIndex[1] = -1;

 mRadius[0] = mRadius[1] = 10.0f;

 mSeed[0] = mSeed[1] = Point2(0.0, 0.0);

 mCubic = TRUE;

Prototype:

virtual ~NURBSFilletSurface();

Remarks:

Destructor.

Prototype:

void SetParent(int pnum, int index);

Remarks:

Sets the specified parent surface (by NURBSSet index) for the fillet.

Parameters:

int pnum

The parent surface: 0 or 1.

int index

The index in the NURBSSet.

Prototype:

void SetParentId(int pnum, NURBSId id);

Remarks:

Sets the specified parent surface (by NURBSId) for the fillet.

Parameters:

int pnum

The parent surface: 0 or 1.

NURBSId id

The ID of the surface.

Prototype:

int GetParent(int pnum);

Remarks:

Returns the index in the NURBSSet of the specified parent surface.

Parameters:

int pnum

The parent surface: 0 or 1.

Prototype:

NURBSId GetParentId(int pnum);

Remarks:

Returns the NURBSId of the specified parent surface.

Parameters:

int pnum

The parent surface: 0 or 1.

Prototype:

Point2 GetSeed(int pnum);

Remarks:

Returns the UV location of the seed value on the specified surface.

Parameters:

int pnum

The parent surface: 0 or 1.

Prototype:

void SetSeed(int pnum, Point2& seed);

Remarks:

Sets the UV location of the seed value on the specified surface.

Parameters:

int pnum

The parent surface: 0 or 1.

Point2& seed

The seed value to set.

Prototype:

BOOL IsCubic();

Remarks:

Returns TRUE if the cubic setting is on; FALSE if off. When off, the radius is always linear. When on, the radius is treated as a cubic function, allowing it to change based on the parent surface's geometry.

Prototype:

void SetCubic(BOOL cubic);

Remarks:

Sets the cubic setting to on or off.

Parameters:

BOOL cubic

TRUE for on; FALSE for off.

Prototype:

float GetRadius(TimeValue t, int rnum);

Remarks:

Returns the specified radius at the time passed.

Parameters:

TimeValue t

The time at which to get the radius.

int rnum

Specifies which radius to get: 0 for start, 1 for end.

Prototype:

void SetRadius(TimeValue t, int rnum, float radius);

Remarks:

Sets the specified radius at the time passed.

Parameters:

TimeValue t

The time at which to set the radius.

int rnum

Specifies which radius to set: 0 for start, 1 for end.

float radius

The radius to set.

Prototype:

BOOL GetTrimSurface(int pnum);

Remarks:

Returns the trim surface setting for the specified parent surface. TRUE if on (trims the parent surface at the edge of the fillet); FALSE if off.

Parameters:

int pnum

The parent surface: 0 or 1.

Prototype:

void SetTrimSurface(int pnum, BOOL trim);

Remarks:

Sets the trim surface setting for the specified parent surface.

Parameters:

int pnum

The parent surface: 0 or 1.

BOOL trim

TRUE for on (trims the parent surface at the edge of the fillet); FALSE for off.

Prototype:

BOOL GetFlipTrim(int pnum);

Remarks:

Returns the state of the trim flip setting. When set this reverses the direction of the trim.

Parameters:

int pnum

The parent surface: 0 or 1.

Prototype:

void SetFlipTrim(int pnum, BOOL flip);

Remarks:

Sets the state of the trim flip setting. When set this reverses the direction of the trim.

Parameters:

int pnum

The parent surface: 0 or 1.

BOOL flip

TRUE for on; FALSE for off.

Prototype:

NURBSFilletSurface & operator=(const NURBSFilletSurface& curve);

Remarks:

Assignment operator.

Parameters:

const NURBSFilletSurface& curve

The surface to assign.