3ds Max C++ API Reference
MNChamferData10 Class Reference

MNChamferData for use with IMNMeshUtilities10::ChamferEdges. More...

#include <MNChamferData10.h>

+ Inheritance diagram for MNChamferData10:

Public Member Functions

DllExport MNChamferData10 (MNChamferData &in_data)
 Initializes decorated object. More...
 
virtual DllExport ~MNChamferData10 ()
 
DllExport void GetDelta (float in_amount, Tab< Point3 > &out_delta)
 Decorator for MNChamferData::GetDelta. This function also interpolates between vertices created. More...
 
DllExport void setNumVerts (int in_nv, bool in_keep=TRUE, int in_resizer=0)
 Decorator for MNChamferData::setNumVerts. More...
 
DllExport void InitToMesh (const MNMesh &in_m)
 Decorator for MNChamferData::InitToMesh. More...
 
DllExport void ClearLimits ()
 Decorator for MNChamferData::ClearLimits. More...
 
DllExport bool GetMapDelta (MNMesh &in_mm, int in_mapChannel, float in_amount, Tab< UVVert > &out_delta)
 Decorator for MNChamferData::GetMapDelta. More...
 
DllExport Tab< UVVert > & MDir (int in_mapChannel)
 Decorator for MNChamferData::MDir. More...
 
DllExport Tab< Point3 > & GetVDIR ()
 Returns MNChamferData::vdir. More...
 
DllExport Tab< float > & GetVMAX ()
 Returns MNChamferData::vmax. More...
 
DllExport Tab< UVVert > *& GetMDIR ()
 Returns MNChamferData::mdir. More...
 

Friends

class MNMesh
 

Additional Inherited Members

- Static Public Member Functions inherited from MaxHeapOperators
static UtilExport voidoperator new (size_t size)
 Standard new operator used to allocate objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e)
 Standard new operator used to allocate objects if there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate objects that takes the type of memory, filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate arrays of objects. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport void operator delete (void *ptr)
 Standard delete operator used to deallocate an object If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an object If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an object that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, void *placement_ptr)
 Placement new operator. More...
 
static UtilExport void operator delete (void *ptr, void *placement_ptr)
 Placement delete operator. More...
 
static UtilExport voidaligned_malloc (size_t size, size_t alignment)
 Allocates memory on a specified alignment boundary. More...
 
static UtilExport voidaligned_realloc (void *ptr, size_t size, size_t alignment)
 Reallocates memory on a specified alignment boundary. More...
 
static UtilExport void aligned_free (void *ptr)
 Frees a block of memory that was allocated with aligned_malloc/aligned_realloc. More...
 

Detailed Description

MNChamferData for use with IMNMeshUtilities10::ChamferEdges.

See also
Class MNChamferData, Class IMNTempData10, Class IMNMeshUtilities10

This class enhances MNChamferData. IMNMeshUtilities10::ChamferEdges requires an MNChamferData10 object. The following code sample demonstrates how to use this class.

Some well-defined pointers:

MNTempData* tempData;
MNMesh* mesh;
The MNMesh class is provided for temporary use by plug-ins, to help with complex topology-based modif...
Definition: mnmesh.h:1164
Used for caching face and edge clusters, vertex normals, and other derived data about an MNMesh.
Definition: mnmesh.h:5762

First, effect the topological change with IMNMeshUtilities10::ChamferEdges:

IMNTempData10* tempData10 = static_cast<IMNTempData10*>(tempData->GetInterface( IMNTEMPDATA10_INTERFACE_ID ));
MNChamferData10& chamferData10 = tempData10->ChamferData();
mesh10->ChamferEdges(MN_SEL, chamferData10, false, 1);
Extends the MNMeshUtilities class, adding new functionality applied on a MNMesh.
Definition: mnmesh.h:6817
virtual bool ChamferEdges(const DWORD in_flag, MNChamferData10 &in_mcd, const bool in_open, const int in_segments)=0
Chamfers mesh edges like MNMesh::ChamferEdges.
Interface for changes made to MNTempData in version 9.5.
Definition: mnmesh.h:6087
virtual MNChamferData10 & ChamferData()=0
Returns pointer to MNChamferData10 object.
MNChamferData for use with IMNMeshUtilities10::ChamferEdges.
Definition: MNChamferData10.h:65
DllExport BaseInterface * GetInterface(Interface_ID id)
DllExport BaseInterface * GetInterface(Interface_ID id)
Returns an interfaces.
#define MN_SEL
Indicates that a component is selected.
Definition: mnmesh.h:70
#define IMNTEMPDATA10_INTERFACE_ID
Interface ID for IMNTempData10.
Definition: mnmesh.h:119
#define IMNMESHUTILITIES10_INTERFACE_ID
Definition: mnmesh.h:6806

After making the topological change, modify the mesh geometry with the desired chamfer amount:

Tab<int> delta;
IMNTempData10* tempData10 = static_cast<IMNTempData10*>(tempData->GetInterface( IMNTEMPDATA10_INTERFACE_ID ));
MNChamferData10& chamferData10 = tempData10->ChamferData();
chamferData10.SetDelta(chamferAmount, delta);

Do not do this:

MNChamferData* chamferData = tempData->ChamferData();
chamferData->GetDelta(chamferAmount, delta);
Contains all the data needed to move points (and map vertices) as the user drags a chamfer or extrude...
Definition: mnmesh.h:5624
DllExport void GetDelta(float amount, Tab< Point3 > &delta)
Uses vectors and limits to obtain the offsets corresponding to a certain extrude or chamfer amount.
DllExport MNChamferData * ChamferData()
Rreturns the cache of a ChamferData for use in the MNMesh Chamfer methods.

Constructor & Destructor Documentation

◆ MNChamferData10()

Initializes decorated object.

Functions are forwarded to underlying MNChamferData object in_data. Some functions append additional functionality. Thus in_data is updated with every function call.

Parameters
[in]in_dataunderlying MNChamferData object.

◆ ~MNChamferData10()

virtual DllExport ~MNChamferData10 ( )
virtual

Member Function Documentation

◆ GetDelta()

DllExport void GetDelta ( float  in_amount,
Tab< Point3 > &  out_delta 
)

Decorator for MNChamferData::GetDelta. This function also interpolates between vertices created.

◆ setNumVerts()

DllExport void setNumVerts ( int  in_nv,
bool  in_keep = TRUE,
int  in_resizer = 0 
)

◆ InitToMesh()

DllExport void InitToMesh ( const MNMesh in_m)

Decorator for MNChamferData::InitToMesh.

◆ ClearLimits()

DllExport void ClearLimits ( )

◆ GetMapDelta()

DllExport bool GetMapDelta ( MNMesh in_mm,
int  in_mapChannel,
float  in_amount,
Tab< UVVert > &  out_delta 
)

Decorator for MNChamferData::GetMapDelta.

This function also interpolates between mapping vertices created on segmented edges.

◆ MDir()

DllExport Tab<UVVert>& MDir ( int  in_mapChannel)

Decorator for MNChamferData::MDir.

◆ GetVDIR()

DllExport Tab<Point3>& GetVDIR ( )

◆ GetVMAX()

DllExport Tab<float>& GetVMAX ( )

◆ GetMDIR()

DllExport Tab<UVVert>*& GetMDIR ( )

Friends And Related Function Documentation

◆ MNMesh

friend class MNMesh
friend