VTK-m  2.0
Macros
Mesh2D_DEM_Triangulation_Macros.h File Reference

Go to the source code of this file.

Macros

#define N_EDGE_TYPES   3
 
#define EDGE_TYPE_HORIZONTAL   0
 
#define EDGE_TYPE_VERTICAL   1
 
#define EDGE_TYPE_DIAGONAL   2
 
#define N_INCIDENT_EDGES   6
 
#define MAX_OUTDEGREE   3
 
#define VERTEX_ROW(V, NCOLS)   ((V) / (NCOLS))
 
#define VERTEX_COL(V, NCOLS)   ((V) % (NCOLS))
 
#define VERTEX_ID(R, C, NCOLS)   ((R) * (NCOLS) + (C))
 
#define EDGE_ROW(E, NCOLS)   ((E) / ((NCOLS) * (N_EDGE_TYPES)))
 
#define EDGE_COL(E, NCOLS)   (((E) / (N_EDGE_TYPES)) % (NCOLS))
 
#define EDGE_WHICH(E)   ((E) % (N_EDGE_TYPES))
 
#define EDGE_ID(R, C, W, NCOLS)   ((((R) * (NCOLS) + (C)) * (N_EDGE_TYPES)) + (W))
 
#define EDGE_FROM(E, NCOLS)   VERTEX_ID(EDGE_ROW(E, NCOLS), EDGE_COL(E, NCOLS), NCOLS)
 
#define EDGE_TO(E, NCOLS)
 

Macro Definition Documentation

◆ EDGE_COL

#define EDGE_COL (   E,
  NCOLS 
)    (((E) / (N_EDGE_TYPES)) % (NCOLS))

◆ EDGE_FROM

#define EDGE_FROM (   E,
  NCOLS 
)    VERTEX_ID(EDGE_ROW(E, NCOLS), EDGE_COL(E, NCOLS), NCOLS)

◆ EDGE_ID

#define EDGE_ID (   R,
  C,
  W,
  NCOLS 
)    ((((R) * (NCOLS) + (C)) * (N_EDGE_TYPES)) + (W))

◆ EDGE_ROW

#define EDGE_ROW (   E,
  NCOLS 
)    ((E) / ((NCOLS) * (N_EDGE_TYPES)))

◆ EDGE_TO

#define EDGE_TO (   E,
  NCOLS 
)
Value:
VERTEX_ID(EDGE_ROW(E, NCOLS) + ((EDGE_WHICH(E) == EDGE_TYPE_HORIZONTAL) ? 0 : 1), \
EDGE_COL(E, NCOLS) + ((EDGE_WHICH(E) == EDGE_TYPE_VERTICAL) ? 0 : 1), \
NCOLS)

◆ EDGE_TYPE_DIAGONAL

#define EDGE_TYPE_DIAGONAL   2

◆ EDGE_TYPE_HORIZONTAL

#define EDGE_TYPE_HORIZONTAL   0

◆ EDGE_TYPE_VERTICAL

#define EDGE_TYPE_VERTICAL   1

◆ EDGE_WHICH

#define EDGE_WHICH (   E)    ((E) % (N_EDGE_TYPES))

◆ MAX_OUTDEGREE

#define MAX_OUTDEGREE   3

◆ N_EDGE_TYPES

#define N_EDGE_TYPES   3

◆ N_INCIDENT_EDGES

#define N_INCIDENT_EDGES   6

◆ VERTEX_COL

#define VERTEX_COL (   V,
  NCOLS 
)    ((V) % (NCOLS))

◆ VERTEX_ID

#define VERTEX_ID (   R,
  C,
  NCOLS 
)    ((R) * (NCOLS) + (C))

◆ VERTEX_ROW

#define VERTEX_ROW (   V,
  NCOLS 
)    ((V) / (NCOLS))
EDGE_ROW
#define EDGE_ROW(E, NCOLS)
Definition: Mesh2D_DEM_Triangulation_Macros.h:88
EDGE_WHICH
#define EDGE_WHICH(E)
Definition: Mesh2D_DEM_Triangulation_Macros.h:92
EDGE_TYPE_HORIZONTAL
#define EDGE_TYPE_HORIZONTAL
Definition: Mesh2D_DEM_Triangulation_Macros.h:71
EDGE_TYPE_VERTICAL
#define EDGE_TYPE_VERTICAL
Definition: Mesh2D_DEM_Triangulation_Macros.h:72
VERTEX_ID
#define VERTEX_ID(R, C, NCOLS)
Definition: Mesh2D_DEM_Triangulation_Macros.h:85
EDGE_COL
#define EDGE_COL(E, NCOLS)
Definition: Mesh2D_DEM_Triangulation_Macros.h:90