3ds Max C++ API Reference
Deformer Class Reference

The callback object used by modifiers to deform "Deformable" objects. More...

#include <object.h>

+ Inheritance diagram for Deformer:

Public Member Functions

virtual CoreExport ~Deformer ()
 Destructor. More...
 
 MAX_DEPRECATE_DEFORMER_MAP ("The non-const version of Deformer::Map is deprecated and will be removed in future updates.\n" "Define MAX_SILENCE_DEPRECATED_DEFORMER_MAP to silence this warning.") CoreExport virtual Point3 Map(int i
 DEPRECATED : See const version for help. More...
 
virtual CoreExport Point3 Map (int i, Point3 p) const
 This is the method that is called to deform or alter a single point. More...
 
 MAX_DEPRECATE_DEFORMER_MAP ("This is a temporary function and will be removed along-side non-const Deformer::Map().\n" "Define MAX_SILENCE_DEPRECATED_DEFORMER_MAP to silence this warning.") CoreExport virtual bool IsThreadSafe() const
 Override this function and return true if your deformer implements Deformer::Map() const. More...
 
virtual CoreExport Point3 MapNormal (int i, Point3 normal) const
 This is the method that is called to deform or alter a point normal. More...
 
void ApplyToTM (Matrix3 *tm)
 

Public Attributes

Point3 p
 

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

The callback object used by modifiers to deform "Deformable" objects.

See also
Class Object, Class Point3.

Constructor & Destructor Documentation

◆ ~Deformer()

virtual CoreExport ~Deformer ( )
virtual

Destructor.

Member Function Documentation

◆ MAX_DEPRECATE_DEFORMER_MAP() [1/2]

MAX_DEPRECATE_DEFORMER_MAP ( "The non-const version of Deformer::Map is deprecated and will be removed in future updates.\n" "Define MAX_SILENCE_DEPRECATED_DEFORMER_MAP to silence this warning."  )

DEPRECATED : See const version for help.

REASON : Deformer::Map should have always been const, now it will be. This will allow us to accelerate the deformers using more aggressive threading.

◆ Map()

virtual CoreExport Point3 Map ( int  i,
Point3  p 
) const
virtual

This is the method that is called to deform or alter a single point.

Note that this method needs to be thread safe, that is why it is const. If you absolutely must modify state inside of Map, use a mutex.

Parameters
iThe index of the point to be altered. Note: An index of -1 may be passed. This indicates that the deformer is not being applied to a regular object but instead points that are generated on the fly for display purposes.
pThe point to be altered.
Returns
The altered point.

◆ MAX_DEPRECATE_DEFORMER_MAP() [2/2]

MAX_DEPRECATE_DEFORMER_MAP ( "This is a temporary function and will be removed along-side non-const Deformer::Map().\n" "Define MAX_SILENCE_DEPRECATED_DEFORMER_MAP to silence this warning."  ) const

Override this function and return true if your deformer implements Deformer::Map() const.

◆ MapNormal()

virtual CoreExport Point3 MapNormal ( int  i,
Point3  normal 
) const
virtual

This is the method that is called to deform or alter a point normal.

Note that this method needs to be thread safe, that is why it is const. If you absolutely must modify state inside of MapNormal, use a mutex.

By default, this will call your Map() implementation. Override this if you need different behavior when deforming normals.

Parameters
iThe index of the normal to be altered. Note: An index of -1 may be passed. This indicates that the deformer is not being applied to a regular object but instead normals that are generated on the fly for display purposes.
normalThe normal to be altered.
Returns
The altered normal.

◆ ApplyToTM()

void ApplyToTM ( Matrix3 tm)

Member Data Documentation

◆ p

Point3 p