KGrid2D::HexagonalBase Class Reference
#include <kgrid2d.h>
Inheritance diagram for KGrid2D::HexagonalBase:
Public Types | |
| enum | Neighbour { Left = 0, Right, LeftUp, LeftDown, RightUp, RightDown, Nb_Neighbour } |
Static Public Member Functions | |
| static double | angle (Neighbour n) |
| static Neighbour | opposed (Neighbour n) |
| static Coord | neighbour (const Coord &c, Neighbour n) |
| static uint | distance (const Coord &c1, const Coord &c2) |
Detailed Description
This class contains static methods to manipulate coordinates on an hexagonal grid where hexagons form horizontal lines:
(0,0) (0,1) (0,2)
(1,0) (1,1) (1,2)
(2,0) (2,1) (2,2)
- Since:
- 3.2
Member Enumeration Documentation
Member Function Documentation
| static double KGrid2D::HexagonalBase::angle | ( | Neighbour | n | ) | [inline, static] |
| static uint KGrid2D::HexagonalBase::distance | ( | const Coord & | c1, |
| const Coord & | c2 | ||
| ) | [inline, static] |
| static Coord KGrid2D::HexagonalBase::neighbour | ( | const Coord & | c, |
| Neighbour | n | ||
| ) | [inline, static] |
| static Neighbour KGrid2D::HexagonalBase::opposed | ( | Neighbour | n | ) | [inline, static] |
The documentation for this class was generated from the following file:
Trinity API Reference