MNMesh Component Flags

General MNMesh Component Flags

For MNVerts, MNEdges, and MNFaces, bits 0-7 are used for common characteristics of all components.Bits 8-15 are used for component-specific flags. Bits 16-23 are reserved for temporary use in MNMesh algorithms. Bits 24-31 are reserved for MNMath.lib users.
#define  MN_SEL   (1<<0)
  Indicates that a component is selected.
#define  MN_DEAD   (1<<1)
  Indicates that a component is not used and should be ignored.
#define  MN_TARG   (1<<2)
  Indicates that a component is targeted.
#define  MN_BACKFACING   (1<<3)
  Indicates that the vertex faces "backwards" in the current viewport.
#define  MN_HIDDEN   (1<<4)
#define  MN_CACHEINVALID   (1<<5)
#define  MN_INFOREGROUND   (1<<7)
  Tags a face as not renderable but can be hit-test.
#define  MN_WHATEVER   (1<<16)
#define  MN_LOCAL_SEL   (1<<17)
  Alternate selections (not passed up the pipe).
#define  MN_HITTEST_CULLED   (1<<18)
  Used to indicate culled components (neither selected nor not selected) in window-region hit testing.
#define  MN_USER   (1<<24)
  Any value above this can be used by applications.

Vertex Flags

#define  MN_VERT_DONE   (1<<8)
  Set in algorithms that may accidentally revisit the same vertex (MNVertext twice, to keep them from processing it the second time.
#define  MN_VERT_WELDED   (1<<9)
  Used by MNMesh::WeldBorderVerts()
#define  MN_VERT_SUBDIVISION_CORNER   (1<<10)
  Track which vertices are direct "descendants" of the original cage vertices in subdivision.

Edge flags

#define  MN_EDGE_INVIS   (1<<8)
  Both faces using this edge consider it invisible.
#define  MN_EDGE_NOCROSS   (1<<9)
  This edge should not be crossed in algorithms like MNMesh::SabinDoo that can mix faces across edges.
#define  MN_EDGE_MAP_SEAM   (1<<10)
  Track which edges are direct descendants of the original cage edges in subdivision.
#define  MN_EDGE_SUBDIVISION_BOUNDARY   (1<<11)
  Track unwanted edges created by Cut, so they might be removed later.
#define  MN_EDGE_CUT_EXTRA   (1<<12)
  Used with MNMesh::CutPrepare() and MNMEsh::CutCleanUp()

Define Documentation

#define MN_SEL   (1<<0)

Indicates that a component is selected.

#define MN_DEAD   (1<<1)

Indicates that a component is not used and should be ignored.

Vertices with the MN_DEAD flag are deleted in the next call MNMesh::CollapseDeadVerts().

#define MN_TARG   (1<<2)

Indicates that a component is targeted.

(See the MNMesh methods starting with the words TargetBy.

#define MN_BACKFACING   (1<<3)

Indicates that the vertex faces "backwards" in the current viewport.

This changes often.

#define MN_HIDDEN   (1<<4)
#define MN_CACHEINVALID   (1<<5)
#define MN_INFOREGROUND   (1<<7)

Tags a face as not renderable but can be hit-test.

1<<6 is skipped because the tri strip uses that as face flag signifying a face to be stripped

#define MN_WHATEVER   (1<<16)

SDK users should use MN_USER and higher flags.

#define MN_LOCAL_SEL   (1<<17)

Alternate selections (not passed up the pipe).

#define MN_HITTEST_CULLED   (1<<18)

Used to indicate culled components (neither selected nor not selected) in window-region hit testing.

#define MN_USER   (1<<24)

Any value above this can be used by applications.

#define MN_VERT_DONE   (1<<8)

Set in algorithms that may accidentally revisit the same vertex (MNVertext twice, to keep them from processing it the second time.

#define MN_VERT_WELDED   (1<<9)
#define MN_VERT_SUBDIVISION_CORNER   (1<<10)

Track which vertices are direct "descendants" of the original cage vertices in subdivision.

#define MN_EDGE_INVIS   (1<<8)

Both faces using this edge consider it invisible.

#define MN_EDGE_NOCROSS   (1<<9)

This edge should not be crossed in algorithms like MNMesh::SabinDoo that can mix faces across edges.

#define MN_EDGE_MAP_SEAM   (1<<10)

Track which edges are direct descendants of the original cage edges in subdivision.

#define MN_EDGE_SUBDIVISION_BOUNDARY   (1<<11)

Track unwanted edges created by Cut, so they might be removed later.

#define MN_EDGE_CUT_EXTRA   (1<<12)

Used with MNMesh::CutPrepare() and MNMEsh::CutCleanUp()