Public Member Functions

IEditNormalsMod Class Reference

Search for all occurrences

Detailed Description

See also:
Class MNMesh , Class MNNormalSpec

class IEditNormalsMod : public FPMixinInterface

Description:
This class is available in release 5.0 and later only.

This class is an interface used by the scripter and the SDK to access the Edit Normals modifier. See the documentation for that modifier for background on the normals and the basic operations like Break and Unify.

All but the last two of these methods are available via the scripter with commands like:

numNormals = $.modifiers[#Edit_Normals].EditNormalsMod.GetNumNormals ()

$.modifiers[#Edit_Normals].EditNormalsMod.SetSelection #{1..numNormals}

$.modifiers[#Edit_Normals].EditNormalsMod.Unify ().

#include <iEditNormals.h>

Inheritance diagram for IEditNormalsMod:
Inheritance graph
[legend]

List of all members.

Public Member Functions

BEGIN_FUNCTION_MAP  PROP_FNS (enfn_get_sel_level, EnfnGetSelLevel, enfn_set_sel_level, EnfnSetSelLevel, TYPE_INT)
  FNT_1 (enfn_move, TYPE_bool, EnfnMove, TYPE_POINT3_BR)
  FNT_1 (enfn_rotate, TYPE_bool, EnfnRotate, TYPE_QUAT_BR)
  FN_3 (enfn_break, TYPE_bool, EnfnBreakNormals, TYPE_BITARRAY, TYPE_INODE, TYPE_bool)
  FN_3 (enfn_unify, TYPE_bool, EnfnUnifyNormals, TYPE_BITARRAY, TYPE_INODE, TYPE_bool)
  FN_2 (enfn_reset, TYPE_bool, EnfnResetNormals, TYPE_BITARRAY, TYPE_INODE)
  FN_2 (enfn_specify, TYPE_bool, EnfnSpecifyNormals, TYPE_BITARRAY, TYPE_INODE)
  FN_2 (enfn_make_explicit, TYPE_bool, EnfnMakeNormalsExplicit, TYPE_BITARRAY, TYPE_INODE)
  FN_2 (enfn_copy, TYPE_bool, EnfnCopyNormal, TYPE_INDEX, TYPE_INODE)
  FN_2 (enfn_paste, TYPE_bool, EnfnPasteNormal, TYPE_BITARRAY, TYPE_INODE)
  FN_4 (enfn_average, TYPE_bool, EnfnAverageNormals, TYPE_bool, TYPE_FLOAT, TYPE_BITARRAY, TYPE_INODE)
  FN_2 (enfn_average_global, TYPE_bool, EnfnAverageGlobalNormals, TYPE_bool, TYPE_FLOAT)
  FN_4 (enfn_average_two, TYPE_bool, EnfnAverageTwoNormals, TYPE_INODE, TYPE_INDEX, TYPE_INODE, TYPE_INDEX)
  FN_1 (enfn_get_selection, TYPE_BITARRAY, EnfnGetSelection, TYPE_INODE)
  FN_2 (enfn_set_selection, TYPE_bool, EnfnSetSelection, TYPE_BITARRAY_BR, TYPE_INODE)
  FN_4 (enfn_select, TYPE_bool, EnfnSelect, TYPE_BITARRAY_BR, TYPE_bool, TYPE_bool, TYPE_INODE)
  VFN_3 (enfn_convert_vertex_selection, EnfnConvertVertexSelection, TYPE_BITARRAY_BR, TYPE_BITARRAY_BR, TYPE_INODE)
  VFN_3 (enfn_convert_edge_selection, EnfnConvertEdgeSelection, TYPE_BITARRAY_BR, TYPE_BITARRAY_BR, TYPE_INODE)
  VFN_3 (enfn_convert_face_selection, EnfnConvertFaceSelection, TYPE_BITARRAY_BR, TYPE_BITARRAY_BR, TYPE_INODE)
  FN_1 (enfn_get_num_normals, TYPE_INT, EnfnGetNumNormals, TYPE_INODE)
  FNT_2 (enfn_get_normal, TYPE_POINT3, EnfnGetNormal, TYPE_INDEX, TYPE_INODE)
  VFNT_3 (enfn_set_normal, EnfnSetNormal, TYPE_INDEX, TYPE_POINT3_BR, TYPE_INODE)
  FN_2 (enfn_get_normal_explicit, TYPE_bool, EnfnGetNormalExplicit, TYPE_INDEX, TYPE_INODE)
  VFN_3 (enfn_set_normal_explicit, EnfnSetNormalExplicit, TYPE_INDEX, TYPE_bool, TYPE_INODE)
  FN_1 (enfn_get_num_faces, TYPE_INT, EnfnGetNumFaces, TYPE_INODE)
  FN_2 (enfn_get_face_degree, TYPE_INT, EnfnGetFaceDegree, TYPE_INDEX, TYPE_INODE)
  FN_3 (enfn_get_normal_id, TYPE_INDEX, EnfnGetNormalID, TYPE_INDEX, TYPE_INDEX, TYPE_INODE)
  VFN_4 (enfn_set_normal_id, EnfnSetNormalID, TYPE_INDEX, TYPE_INDEX, TYPE_INDEX, TYPE_INODE)
  FN_3 (enfn_get_face_normal_specified, TYPE_bool, EnfnGetFaceNormalSpecified, TYPE_INDEX, TYPE_INDEX, TYPE_INODE)
  VFN_4 (enfn_set_face_normal_specified, EnfnSetFaceNormalSpecified, TYPE_INDEX, TYPE_INDEX, TYPE_bool, TYPE_INODE)
  FN_1 (enfn_get_num_vertices, TYPE_INT, EnfnGetNumVertices, TYPE_INODE)
  FN_3 (enfn_get_vertex_id, TYPE_INDEX, EnfnGetVertexID, TYPE_INDEX, TYPE_INDEX, TYPE_INODE)
  FNT_2 (enfn_get_vertex, TYPE_POINT3_BV, EnfnGetVertex, TYPE_INDEX, TYPE_INODE)
  FN_1 (enfn_get_num_edges, TYPE_INT, EnfnGetNumEdges, TYPE_INODE)
  FN_3 (enfn_get_edge_id, TYPE_INDEX, EnfnGetEdgeID, TYPE_INDEX, TYPE_INDEX, TYPE_INODE)
  FN_3 (enfn_get_face_edge_side, TYPE_INDEX, EnfnGetFaceEdgeSide, TYPE_INDEX, TYPE_INDEX, TYPE_INODE)
  FN_3 (enfn_get_edge_vertex, TYPE_INDEX, EnfnGetEdgeVertex, TYPE_INDEX, TYPE_INDEX, TYPE_INODE)
  FN_3 (enfn_get_edge_face, TYPE_INDEX, EnfnGetEdgeFace, TYPE_INDEX, TYPE_INDEX, TYPE_INODE)
  FN_4 (enfn_get_edge_normal, TYPE_INDEX, EnfnGetEdgeNormal, TYPE_INDEX, TYPE_INDEX, TYPE_INDEX, TYPE_INODE)
  VFN_1 (enfn_rebuild_normals, EnfnRebuildNormals, TYPE_INODE)
  VFN_1 (enfn_recompute_normals, EnfnRecomputeNormals, TYPE_INODE)
END_FUNCTION_MAP FPInterfaceDesc GetDesc ()
virtual int  EnfnGetSelLevel ()
virtual void  EnfnSetSelLevel (int selLevel)
virtual bool  EnfnMove (Point3 &offset, TimeValue t)
virtual bool  EnfnRotate (Quat &rotation, TimeValue t)
virtual bool  EnfnBreakNormals (BitArray *normalSelection=NULL, INode *pNode=NULL, bool toAverage=false)
  In 3ds Max 6, the Edit normals modifier had an average function added to its tool set.
virtual bool  EnfnUnifyNormals (BitArray *normalSelection=NULL, INode *pNode=NULL, bool toAverage=false)
virtual bool  EnfnResetNormals (BitArray *normalSelection=NULL, INode *pNode=NULL)
virtual bool  EnfnSpecifyNormals (BitArray *normalSelection=NULL, INode *pNode=NULL)
virtual bool  EnfnMakeNormalsExplicit (BitArray *normalSelection=NULL, INode *pNode=NULL)
virtual bool  EnfnCopyNormal (int normalID, INode *pNode=NULL)
virtual bool  EnfnPasteNormal (BitArray *normalSelection=NULL, INode *pNode=NULL)
virtual bool  EnfnAverageNormals (bool useThresh=false, float threshold=0.0f, BitArray *normalSelection=NULL, INode *pNode=NULL)
virtual bool  EnfnAverageGlobalNormals (bool useThresh=false, float threshold=0.0f)
virtual bool  EnfnAverageTwoNormals (INode *pNode1, int normID1, INode *pNode2, int normID2)
virtual BitArray EnfnGetSelection (INode *pNode=NULL)
virtual bool  EnfnSetSelection (BitArray &selection, INode *pNode=NULL)
virtual bool  EnfnSelect (BitArray &selection, bool invert=false, bool select=true, INode *pNode=NULL)
virtual void  EnfnConvertVertexSelection (BitArray &vertexSelection, BitArray &normalSelection, INode *pNode=NULL)
virtual void  EnfnConvertEdgeSelection (BitArray &edgeSelection, BitArray &normalSelection, INode *pNode=NULL)
virtual void  EnfnConvertFaceSelection (BitArray &faceSelection, BitArray &normalSelection, INode *pNode=NULL)
virtual int  EnfnGetNumNormals (INode *pNode=NULL)
virtual Point3 EnfnGetNormal (int normalID, INode *pNode=NULL, TimeValue t=0)
virtual void  EnfnSetNormal (int normalID, Point3 &direction, INode *pNode=NULL, TimeValue t=0)
virtual bool  EnfnGetNormalExplicit (int normID, INode *pNode=NULL)
virtual void  EnfnSetNormalExplicit (int normID, bool value, INode *pNode=NULL)
virtual int  EnfnGetNumFaces (INode *pNode=NULL)
virtual int  EnfnGetFaceDegree (int face, INode *pNode=NULL)
virtual int  EnfnGetNormalID (int face, int corner, INode *pNode=NULL)
virtual void  EnfnSetNormalID (int face, int corner, int normalID, INode *pNode=NULL)
virtual bool  EnfnGetFaceNormalSpecified (int face, int corner, INode *pNode=NULL)
virtual void  EnfnSetFaceNormalSpecified (int face, int corner, bool specified, INode *pNode=NULL)
 


virtual int  EnfnGetNumVertices (INode *pNode=NULL)
virtual int  EnfnGetVertexID (int face, int corner, INode *pNode=NULL)
virtual Point3  EnfnGetVertex (int vertexID, INode *pNode=NULL, TimeValue t=0)
virtual int  EnfnGetNumEdges (INode *pNode=NULL)
virtual int  EnfnGetEdgeID (int faceIndex, int sideIndex, INode *pNode=NULL)
virtual int  EnfnGetFaceEdgeSide (int faceIndex, int edgeIndex, INode *pNode=NULL)
virtual int  EnfnGetEdgeVertex (int edgeIndex, int end, INode *pNode=NULL)
virtual int  EnfnGetEdgeFace (int edgeIndex, int side, INode *pNode=NULL)
virtual int  EnfnGetEdgeNormal (int edgeIndex, int end, int side, INode *pNode=NULL)
virtual void  EnfnRebuildNormals (INode *pNode=NULL)
virtual void  EnfnRecomputeNormals (INode *pNode=NULL)
virtual MNMesh EnfnGetMesh (INode *pNode=NULL, TimeValue t=0)
virtual MNNormalSpec EnfnGetNormals (INode *pNode=NULL, TimeValue t=0)

Member Function Documentation

BEGIN_FUNCTION_MAP PROP_FNS ( enfn_get_sel_level  ,
EnfnGetSelLevel  ,
enfn_set_sel_level  ,
EnfnSetSelLevel  ,
TYPE_INT   
)
FNT_1 ( enfn_move  ,
TYPE_bool  ,
EnfnMove  ,
TYPE_POINT3_BR   
)
FNT_1 ( enfn_rotate  ,
TYPE_bool  ,
EnfnRotate  ,
TYPE_QUAT_BR   
)
FN_3 ( enfn_break  ,
TYPE_bool  ,
EnfnBreakNormals  ,
TYPE_BITARRAY  ,
TYPE_INODE  ,
TYPE_bool   
)
FN_3 ( enfn_unify  ,
TYPE_bool  ,
EnfnUnifyNormals  ,
TYPE_BITARRAY  ,
TYPE_INODE  ,
TYPE_bool   
)
FN_2 ( enfn_reset  ,
TYPE_bool  ,
EnfnResetNormals  ,
TYPE_BITARRAY  ,
TYPE_INODE   
)
FN_2 ( enfn_specify  ,
TYPE_bool  ,
EnfnSpecifyNormals  ,
TYPE_BITARRAY  ,
TYPE_INODE   
)
FN_2 ( enfn_make_explicit  ,
TYPE_bool  ,
EnfnMakeNormalsExplicit  ,
TYPE_BITARRAY  ,
TYPE_INODE   
)
FN_2 ( enfn_copy  ,
TYPE_bool  ,
EnfnCopyNormal  ,
TYPE_INDEX  ,
TYPE_INODE   
)
FN_2 ( enfn_paste  ,
TYPE_bool  ,
EnfnPasteNormal  ,
TYPE_BITARRAY  ,
TYPE_INODE   
)
FN_4 ( enfn_average  ,
TYPE_bool  ,
EnfnAverageNormals  ,
TYPE_bool  ,
TYPE_FLOAT  ,
TYPE_BITARRAY  ,
TYPE_INODE   
)
FN_2 ( enfn_average_global  ,
TYPE_bool  ,
EnfnAverageGlobalNormals  ,
TYPE_bool  ,
TYPE_FLOAT   
)
FN_4 ( enfn_average_two  ,
TYPE_bool  ,
EnfnAverageTwoNormals  ,
TYPE_INODE  ,
TYPE_INDEX  ,
TYPE_INODE  ,
TYPE_INDEX   
)
FN_1 ( enfn_get_selection  ,
TYPE_BITARRAY  ,
EnfnGetSelection  ,
TYPE_INODE   
)
FN_2 ( enfn_set_selection  ,
TYPE_bool  ,
EnfnSetSelection  ,
TYPE_BITARRAY_BR  ,
TYPE_INODE   
)
FN_4 ( enfn_select  ,
TYPE_bool  ,
EnfnSelect  ,
TYPE_BITARRAY_BR  ,
TYPE_bool  ,
TYPE_bool  ,
TYPE_INODE   
)
VFN_3 ( enfn_convert_vertex_selection  ,
EnfnConvertVertexSelection  ,
TYPE_BITARRAY_BR  ,
TYPE_BITARRAY_BR  ,
TYPE_INODE   
)
VFN_3 ( enfn_convert_edge_selection  ,
EnfnConvertEdgeSelection  ,
TYPE_BITARRAY_BR  ,
TYPE_BITARRAY_BR  ,
TYPE_INODE   
)
VFN_3 ( enfn_convert_face_selection  ,
EnfnConvertFaceSelection  ,
TYPE_BITARRAY_BR  ,
TYPE_BITARRAY_BR  ,
TYPE_INODE   
)
FN_1 ( enfn_get_num_normals  ,
TYPE_INT  ,
EnfnGetNumNormals  ,
TYPE_INODE   
)
FNT_2 ( enfn_get_normal  ,
TYPE_POINT3  ,
EnfnGetNormal  ,
TYPE_INDEX  ,
TYPE_INODE   
)
VFNT_3 ( enfn_set_normal  ,
EnfnSetNormal  ,
TYPE_INDEX  ,
TYPE_POINT3_BR  ,
TYPE_INODE   
)
FN_2 ( enfn_get_normal_explicit  ,
TYPE_bool  ,
EnfnGetNormalExplicit  ,
TYPE_INDEX  ,
TYPE_INODE   
)
VFN_3 ( enfn_set_normal_explicit  ,
EnfnSetNormalExplicit  ,
TYPE_INDEX  ,
TYPE_bool  ,
TYPE_INODE   
)
FN_1 ( enfn_get_num_faces  ,
TYPE_INT  ,
EnfnGetNumFaces  ,
TYPE_INODE   
)
FN_2 ( enfn_get_face_degree  ,
TYPE_INT  ,
EnfnGetFaceDegree  ,
TYPE_INDEX  ,
TYPE_INODE   
)
FN_3 ( enfn_get_normal_id  ,
TYPE_INDEX  ,
EnfnGetNormalID  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_INODE   
)
VFN_4 ( enfn_set_normal_id  ,
EnfnSetNormalID  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_INODE   
)
FN_3 ( enfn_get_face_normal_specified  ,
TYPE_bool  ,
EnfnGetFaceNormalSpecified  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_INODE   
)
VFN_4 ( enfn_set_face_normal_specified  ,
EnfnSetFaceNormalSpecified  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_bool  ,
TYPE_INODE   
)
FN_1 ( enfn_get_num_vertices  ,
TYPE_INT  ,
EnfnGetNumVertices  ,
TYPE_INODE   
)
FN_3 ( enfn_get_vertex_id  ,
TYPE_INDEX  ,
EnfnGetVertexID  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_INODE   
)
FNT_2 ( enfn_get_vertex  ,
TYPE_POINT3_BV  ,
EnfnGetVertex  ,
TYPE_INDEX  ,
TYPE_INODE   
)
FN_1 ( enfn_get_num_edges  ,
TYPE_INT  ,
EnfnGetNumEdges  ,
TYPE_INODE   
)
FN_3 ( enfn_get_edge_id  ,
TYPE_INDEX  ,
EnfnGetEdgeID  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_INODE   
)
FN_3 ( enfn_get_face_edge_side  ,
TYPE_INDEX  ,
EnfnGetFaceEdgeSide  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_INODE   
)
FN_3 ( enfn_get_edge_vertex  ,
TYPE_INDEX  ,
EnfnGetEdgeVertex  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_INODE   
)
FN_3 ( enfn_get_edge_face  ,
TYPE_INDEX  ,
EnfnGetEdgeFace  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_INODE   
)
FN_4 ( enfn_get_edge_normal  ,
TYPE_INDEX  ,
EnfnGetEdgeNormal  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_INDEX  ,
TYPE_INODE   
)
VFN_1 ( enfn_rebuild_normals  ,
EnfnRebuildNormals  ,
TYPE_INODE   
)
VFN_1 ( enfn_recompute_normals  ,
EnfnRecomputeNormals  ,
TYPE_INODE   
)
END_FUNCTION_MAP FPInterfaceDesc* GetDesc ( ) [virtual]
Remarks:
Returns a pointer to the class which contains the interface metadata.

Implements FPInterface.

virtual int EnfnGetSelLevel ( ) [inline, virtual]
Remarks:
"Get" accessor for selection level - one of these values:

EN_SL_OBJECT, EN_SL_NORMAL, EN_SL_VERTEX, EN_SL_EDGE, EN_SL_FACE

{ return EN_SL_OBJECT; }
virtual void EnfnSetSelLevel ( int  selLevel ) [inline, virtual]
Remarks:
"Set" accessor for selection level - one of these values:

EN_SL_OBJECT, EN_SL_NORMAL, EN_SL_VERTEX, EN_SL_EDGE, EN_SL_FACE

{ }
virtual bool EnfnMove ( Point3 offset,
TimeValue  t 
) [inline, virtual]
Remarks:
Moves the ends of currently selected normals by the offset indicated - then renormalizes them to unit length.

Note that the time is currently ignored, as the Edit Normals modifier is not yet animatable

{ return false; }
virtual bool EnfnRotate ( Quat rotation,
TimeValue  t 
) [inline, virtual]
Remarks:
Rotates currently selected normals by the rotation indicated.

Note that the time is currently ignored, as the Edit Normals modifier is not yet animatable

{ return false; }
virtual bool EnfnBreakNormals ( BitArray normalSelection = NULL,
INode pNode = NULL,
bool  toAverage = false 
) [inline, virtual]

In 3ds Max 6, the Edit normals modifier had an average function added to its tool set.

Remarks:
Breaks the indicated normals into separate normals for each face.

In 3ds Max 6, the Edit normals modifier had an average function added to its tool set. This allows the user to average the normals across the surface of the object(s). The toAverage parameter was added to this method to provide access to this new functionality.
Parameters:
BitArray *normalSelection=NULL

An optional selection set to use. If NULL, the current selection is used.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

bool toAverage=false

Default is false. When true, this parameter causes the normals to be averaged across the surface of the object(s).

This allows the user to average the normals across the surface of the objects(s). This method and the next four methods were added to an existing interface to provide access to this new functionality.

Remarks:
Breaks the indicated normals into separate normals for each face.
Parameters:
BitArray *normalSelection=NULL

An optional selection set to use. If NULL, the current selection is used.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)
{ return false; }
virtual bool EnfnUnifyNormals ( BitArray normalSelection = NULL,
INode pNode = NULL,
bool  toAverage = false 
) [inline, virtual]
Remarks:
Unifies the indicated normals so there's at most one normal per vertex. (Basically, causes normals to be shared across faces at a vertex.)

In 3ds Max 6, the Edit normals modifier had an average function added to its tool set. This allows the user to average the normals across the surface of the objects(s). The toAverage parameter was added to this method to provide access to this new functionality.
Parameters:
BitArray *normalSelection=NULL

An optional selection set to use. If NULL, the current selection is used.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

bool toAverage=false

Default is false. When true, this parameter causes the normals to be averaged across the surface of the object(s).
{ return false; }
virtual bool EnfnResetNormals ( BitArray normalSelection = NULL,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Makes the indicated normals completely non-explicit and unspecified. Generates a rebuild & computation to determine the topology and direction of the newly unspecified normals.
Parameters:
BitArray *normalSelection=NULL

An optional selection set to use. If NULL, the current selection is used.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in.

If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return false; }
virtual bool EnfnSpecifyNormals ( BitArray normalSelection = NULL,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Specifies the normals indicated to be fixed to the faces they're currently used by.
Parameters:
BitArray *normalSelection=NULL

An optional selection set to use. If NULL, the current selection is used.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return false; }
virtual bool EnfnMakeNormalsExplicit ( BitArray normalSelection = NULL,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Make the indicated normals explicit, so they won't be based on underlying face normals.
Parameters:
BitArray *normalSelection=NULL

An optional selection set to use. If NULL, the current selection is used.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return false; }
virtual bool EnfnCopyNormal ( int  normalID,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Copies the indicated normal into the Edit Normals modifier's copy/paste buffer.
Parameters:
int normalID

The ID of the normal we want to copy.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return false; }
virtual bool EnfnPasteNormal ( BitArray normalSelection = NULL,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Pastes the normal currently in the Edit Normals modifier's copy/paste buffer into the normals indicated, making them specified and explicit.
Parameters:
BitArray *normalSelection = NULL

An optional selection set to use. If NULL, the current selection is used.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return false; }
virtual bool EnfnAverageNormals ( bool  useThresh = false,
float  threshold = 0.0f,
BitArray normalSelection = NULL,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Added in 3ds Max 6 SDK.
Parameters:
bool useThresh=false

float threshhold=0.0f

BitArray *normalSelection=NULL

An optional selection set to use. If NULL, the current selection is used.
{ return false; }
virtual bool EnfnAverageGlobalNormals ( bool  useThresh = false,
float  threshold = 0.0f 
) [inline, virtual]
Remarks:
Added in 3ds Max 6 SDK.
Parameters:
bool useThresh=false

float threshhold=0.0f
{ return false; }
virtual bool EnfnAverageTwoNormals ( INode pNode1,
int  normID1,
INode pNode2,
int  normID2 
) [inline, virtual]
Remarks:
Added in 3ds Max 6 SDK.
Parameters:
INode *pNode1

int normID1

INode *pNode2

int normID2

{ return false; }
virtual BitArray* EnfnGetSelection ( INode pNode = NULL ) [inline, virtual]
Remarks:
Returns a pointer to the current selection.
Parameters:
INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return NULL; }
virtual bool EnfnSetSelection ( BitArray selection,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Sets the normal selection to the selection given.
Parameters:
BitArray&selection

The desired selection

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

Returns:
True if the selection was changed; false if the new selection was the same as the old selection.

{ return false; }
virtual bool EnfnSelect ( BitArray selection,
bool  invert = false,
bool  select = true,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Selects, deselects, or inverts the selection of the normals indicated.
Parameters:
BitArray&selection

The normals whose selection we are trying to change.

bool invert=false

If true, indicates that the normals in <selection> should have their selection status inverted

bool select=true

If <invert> is true, this is ignored. Otherwise, if true, the normals indicated should be selected; if false, they should be deselected.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

Returns:
True if the selection changed, false otherwise.

{ return false; }
virtual void EnfnConvertVertexSelection ( BitArray vertexSelection,
BitArray normalSelection,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Converts a vertex selection into a selection of normals, by setting bits on normals based at selected faces.
Parameters:
BitArray & vertexSelection

The vertex selection we're converting

BitArray & normalSelection

The output normal selection

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

Returns:
True if the selection changed, false otherwise.

{ }
virtual void EnfnConvertEdgeSelection ( BitArray edgeSelection,
BitArray normalSelection,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Converts an edge selection into a selection of normals, by setting bits for normals used on either end and either side of selected edges.
Parameters:
BitArray & edgeSelection

The edge selection we're converting

BitArray & normalSelection

The output normal selection

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ }
virtual void EnfnConvertFaceSelection ( BitArray faceSelection,
BitArray normalSelection,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Converts a face selection into a selection of normals, by setting bits on normals used by selected faces.
Parameters:
BitArray & faceSelection

The face selection we're converting

BitArray & normalSelection

The output normal selection

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ }
virtual int EnfnGetNumNormals ( INode pNode = NULL ) [inline, virtual]
Remarks:
Returns the current number of normals.
Parameters:
INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return 0; }
virtual Point3* EnfnGetNormal ( int  normalID,
INode pNode = NULL,
TimeValue  t = 0 
) [inline, virtual]
Remarks:
Returns a pointer to the normal indicated.
Parameters:
int normalID

The index of the normal

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

TimeValue t=0

This is currently unused - but might be important if we add animation capabilities to Edit Normals in the future.

{ return NULL; }
virtual void EnfnSetNormal ( int  normalID,
Point3 direction,
INode pNode = NULL,
TimeValue  t = 0 
) [inline, virtual]
Remarks:
Sets the indicated normal to a specific value. NOTE that this does not set the "explicitness" of this normal. If the normal is not made

explicit, it will be restored to its default value the next time non-explicit normals are recomputed.
Parameters:
int normalID

The index of the normal

Point3 & direction

The desired normal direction. If not already normalized to a length of 1,

this method will normalize it.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

TimeValue t=0

This is currently unused - but might be important if we add animation capabilities to Edit Normals in the future.

{ }
virtual bool EnfnGetNormalExplicit ( int  normID,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Controls whether a given normal is built from smoothing groups or set to an explicit value (Also makes the normal specified for all faces using this normal.)
Parameters:
int normalID

The index of the normal

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return false; }
virtual void EnfnSetNormalExplicit ( int  normID,
bool  value,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Makes the indicated normal explicit (or not). If setting the normal to explicit, it will also be set to "specified" on all faces using it. If

setting it to non-explicit, the modifier recomputes all non-explicit normals to bring it up to date.
Parameters:
int normalID

The index of the normal

bool value

True to make this normal explicit, false to make it non-explicit.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ }
virtual int EnfnGetNumFaces ( INode pNode = NULL ) [inline, virtual]
Remarks:
Returns the number of faces in the normal specification..
Parameters:
INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return 0; }
virtual int EnfnGetFaceDegree ( int  face,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Returns the degree of the face indicated. (3 for triangle, 4 for quad, etc.)
Parameters:
int face

The desired face. INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return 0; }
virtual int EnfnGetNormalID ( int  face,
int  corner,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Gets the index of the normal in the indicated corner of the indicated face
Parameters:
int face

The desired face.

int corner

The desired corner, in the range of 0 to EnfnGetFaceDegree(face)-1. INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return 0; }
virtual void EnfnSetNormalID ( int  face,
int  corner,
int  normalID,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Sets the index of the normal in the indicated corner of the indicated

face
Parameters:
int face

The desired face.

int corner

The desired corner, in the range of 0 to EnfnGetFaceDegree(face)-1.

int normalID

The index of the desired normal

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ }
virtual bool EnfnGetFaceNormalSpecified ( int  face,
int  corner,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Indicates whether a particular corner of a particular face is specified

to use a specific normal or not.
Parameters:
int face

The desired face.

int corner

The desired corner, in the range of 0 to EnfnGetFaceDegree(face)-1.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return false; }
virtual void EnfnSetFaceNormalSpecified ( int  face,
int  corner,
bool  specified,
INode pNode = NULL 
) [inline, virtual]



Remarks:
Controls whether a corner of a face uses a specific normal ID, or builds normals based on smoothing groups. If called to set a corner

to unspecified, it generates a rebuild of nonspecified normals and a recomputation of nonexplicit normals at next update.
Parameters:
int face

The desired face.

int corner

The desired corner, in the range of 0 to EnfnGetFaceDegree(face)-1.

bool specified

True to specify, false to set as unspecified.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ }
virtual int EnfnGetNumVertices ( INode pNode = NULL ) [inline, virtual]
Remarks:
Returns the number of vertices in the current mesh cache..

Parameters:
INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{return 0; }
virtual int EnfnGetVertexID ( int  face,
int  corner,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Returns the vertex used in a corner of a face, in the current mesh cache. (Useful for determining the "base" of the normal used in that corner of

that face.)

Parameters:
int face

The desired face.

int corner

The desired corner, in the range of 0 to EnfnGetFaceDegree(face)-1.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return 0; }
virtual Point3 EnfnGetVertex ( int  vertexID,
INode pNode = NULL,
TimeValue  t = 0 
) [inline, virtual]
Remarks:
Returns the location of the vertex indicated (in the current mesh cache).

Parameters:
int vertexID

The desired vertex.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

TimeValue t=0

This is currently unused - but might be important if we add animation capabilities to Edit Normals in the future.

{ return Point3(0,0,0); }
virtual int EnfnGetNumEdges ( INode pNode = NULL ) [inline, virtual]
Remarks:
Returns the number of edges in the current mesh cache.

Parameters:
INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return 0; }
virtual int EnfnGetEdgeID ( int  faceIndex,
int  sideIndex,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Returns the index of the edge used on a particular side of a particular face, in the current mesh cache

Parameters:
int faceIndex

The desired face.

int side

The desired side, in the range of 0 to EnfnGetFaceDegree(faceIndex)-1.

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return 0; }
virtual int EnfnGetFaceEdgeSide ( int  faceIndex,
int  edgeIndex,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Tells you which side of the face a given edge is on. (Can be useful for getting normal and vertex information around the edge.)

Parameters:
int faceIndex

The desired face.

int edgeIndex

The desired edge

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

Returns:
The side of the face, in the range of 0 to EnfnGetFaceDegree(faceIndex)-1, or -1 if the edge was not found on this face

{ return 0; }
virtual int EnfnGetEdgeVertex ( int  edgeIndex,
int  end,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Returns the vertex at the end of the edge.

Parameters:
int edgeIndex

The desired edge.

int end

The desired end - either 0 or 1

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ return 0; }
virtual int EnfnGetEdgeFace ( int  edgeIndex,
int  side,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Tells you what face is on a particular side of a particular edge.

Parameters:
int edgeIndex

The index of the edge in the MNMesh's edge array.

int side

Indicates which side of the edge you want the face from. (Values: 0 or 1.)

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

Returns:
The index of the desired face, or -1 if there's an error or if there is no face on that side.

{ return 0; }
virtual int EnfnGetEdgeNormal ( int  edgeIndex,
int  end,
int  side,
INode pNode = NULL 
) [inline, virtual]
Remarks:
Returns the normal associated with a particular end and side of this edge.

Parameters:
int edgeIndex

The index of the edge in the MNMesh's edge array.

int end

Indicates which end of the edge should be used. (Values: 0 or 1.)

int side

Indicates which side of the edge should be used - the edge may have different normals used by the faces on either side. (Values: 0 or 1.)

INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

Returns:
The index of the desired normal..

{ return 0; }
virtual void EnfnRebuildNormals ( INode pNode = NULL ) [inline, virtual]
Remarks:
Forces the modifier to rebuild all non-specified normals from the face smoothing groups. Note that this can change the number of normals in some cases, and often changes their order.

Parameters:
INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ }
virtual void EnfnRecomputeNormals ( INode pNode = NULL ) [inline, virtual]
Remarks:
Forces the modifier to recompute all non-explicit normals.

Parameters:
INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

{ }
virtual MNMesh* EnfnGetMesh ( INode pNode = NULL,
TimeValue  t = 0 
) [inline, virtual]
Remarks:
Returns a pointer to the cached copy of the MNMesh held by the EditNormalsModData. This is a "stripped-down" copy of the last mesh that was output by the modifier. It contains no maps, vertex or edge data, or normals. It's mainly used as a temporary "parent" to the localdata's MNNormalSpec in operations such as Display.

Parameters:
INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

TimeValue t=0

This is currently unused - but might be important if we add animation capabilities to Edit Normals in the future.

{ return NULL; }
virtual MNNormalSpec* EnfnGetNormals ( INode pNode = NULL,
TimeValue  t = 0 
) [inline, virtual]
Remarks:
Returns a pointer to the MNNormalSpec used by the EditNormalsModData. This MNNormalSpec is not part of any particular MNMesh, rather it's used as the local data of the EditNormalsMod to indicate what normals should be applied to the mesh coming up the pipe. Its "parent" pointer is generally set to NULL, and should be set to a mesh like the one you get from EnfnGetMesh before you do certain operations. (See class MNNormalSpec for details on which methods require an accurate "parent" pointer.

Parameters:
INode *pNode = NULL

If the Edit Normals modifier is instanced across several nodes, this parameter can be used to indicate which node you mean to modify normals in. If you want to modify normals in all nodes, you must make a separate call for each node. If NULL, it assumes you want to modify normals in the "first" node. (This is fine if the modifier is only applied to one node, as is usually the case.)

TimeValue t=0

This is currently unused - but might be important if we add animation capabilities to Edit Normals in the future.
{ return NULL; }

IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod
IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod IEditNormalsMod