Falaise  4.0.1
SuperNEMO Software Toolkit
Public Types | Static Public Member Functions | Static Public Attributes | List of all members
snemo::geometry::utils Class Reference

Some geometry utility. More...

#include <falaise/snemo/geometry/utils.h>

Public Types

enum  direction_index {
  DIRECTION_INVALID = -1, DIRECTION_BACK = 0, DIRECTION_FRONT = 1, DIRECTION_LEFT = 2,
  DIRECTION_RIGHT = 3, DIRECTION_BOTTOM = 4, DIRECTION_TOP = 5
}
 Direction identifier constants in the SuperNEMO reference frame. More...
 
enum  side_index { SIDE_INVALID = -1, SIDE_BACK = DIRECTION_BACK, SIDE_FRONT = DIRECTION_FRONT }
 Side identifier constants (X axis in the SuperNEMO reference frame) More...
 
enum  grid_neighbour_mask_type {
  NEIGHBOUR_NONE = 0x0, NEIGHBOUR_SIDE = 0x1, NEIGHBOUR_DIAG = 0x2, NEIGHBOUR_FIRST = NEIGHBOUR_SIDE | NEIGHBOUR_DIAG,
  NEIGHBOUR_SECOND = 0x4
}
 Neighbourg flag on a 2D-grid [s][s][s][s][s] [s][D][S][D][s] [s][S][x][S][s] [s][D][S][D][s] [s][s][s][s][s]. More...
 

Static Public Member Functions

static const std::string & side_back_label ()
 Return a label representing the "back" side. More...
 
static const std::string & side_front_label ()
 Return a label representing the "front" side. More...
 
static bool is_side_label_valid (const std::string &label_)
 Check if a label represents a valid side. More...
 
static int get_side_from_label (const std::string &label_)
 Get the side code from a label. More...
 

Static Public Attributes

static const unsigned int NSIDES = 2
 
static const unsigned int NSUBMODULES = NSIDES
 

Detailed Description

Some geometry utility.

Member Enumeration Documentation

◆ direction_index

Direction identifier constants in the SuperNEMO reference frame.

Enumerator
DIRECTION_INVALID 

Invalid/undefined direction.

DIRECTION_BACK 

Back direction (X-)

DIRECTION_FRONT 

Front direction (X+)

DIRECTION_LEFT 

Left direction (Y-)

DIRECTION_RIGHT 

Right direction (Y+)

DIRECTION_BOTTOM 

Bottom direction (Z-)

DIRECTION_TOP 

Top direction (Z+)

◆ grid_neighbour_mask_type

Neighbourg flag on a 2D-grid [s][s][s][s][s] [s][D][S][D][s] [s][S][x][S][s] [s][D][S][D][s] [s][s][s][s][s].

Enumerator
NEIGHBOUR_NONE 
NEIGHBOUR_SIDE 
NEIGHBOUR_DIAG 

S : nearest neighbours (side)

NEIGHBOUR_FIRST 

D : nearest diagonal.

NEIGHBOUR_SECOND 

S or D.

◆ side_index

Side identifier constants (X axis in the SuperNEMO reference frame)

Enumerator
SIDE_INVALID 

Invalid/undefined side.

SIDE_BACK 

Back side (X-)

SIDE_FRONT 

Front side (X+)

Member Function Documentation

◆ get_side_from_label()

static int snemo::geometry::utils::get_side_from_label ( const std::string &  label_)
static

Get the side code from a label.

◆ is_side_label_valid()

static bool snemo::geometry::utils::is_side_label_valid ( const std::string &  label_)
static

Check if a label represents a valid side.

◆ side_back_label()

static const std::string& snemo::geometry::utils::side_back_label ( )
static

Return a label representing the "back" side.

◆ side_front_label()

static const std::string& snemo::geometry::utils::side_front_label ( )
static

Return a label representing the "front" side.

Member Data Documentation

◆ NSIDES

const unsigned int snemo::geometry::utils::NSIDES = 2
static

◆ NSUBMODULES

const unsigned int snemo::geometry::utils::NSUBMODULES = NSIDES
static

The documentation for this class was generated from the following file: