Adaptagrams
|
#include <faces.h>
Public Member Functions | |
Nexus (Node_SP u) | |
Standard constructor. More... | |
void | addSide (Side_SP side) |
Add a Side to the Nexus. | |
std::set< Side_SP > | getNeighboursOfADirection (CompassDir direc) |
Find out what are the first objects you hit as you try sweeping both clockwise and anticlockwise, starting from a given direction. More... | |
std::string | toString (void) const |
Write a string representation. | |
Regarded as a member of a Face F, a Node u belongs to certain Sides si of F. As we traverse the face in the clockwise direction (i.e. so that the interior of the face is always to the /right/), each Side si gets a direction, and therefore may stand in one of eight relations to Node u: it may be /entering/ or /exiting/, and this may be from or to any of the four cardinal compass directions.
A single Side may stand in two such relations, as when the Node lies along the middle of the Side, or else in just one such relation, as when a Node lies at one end or the other.
A Nexus represents a Node in this capacity as a "joining point" of several Sides of a Face. It stores eight "slots" that are either empty or else occupied by a Side object.
|
inline |
std::set< Side_SP > Nexus::getNeighboursOfADirection | ( | CompassDir | direc | ) |
Find out what are the first objects you hit as you try sweeping both clockwise and anticlockwise, starting from a given direction.
[in] | direc | The given direction. |