Kaim::DatabaseGenMetrics Class Reference
#include <databasegenmetrics.h>
This class gathers a set of generation parameters of one Database and manages the conversion between the floating-point and integer coordinate systems used internally by NavData.
Each Database object maintains and provides access to an instance of this class
void Kaim::DatabaseGenMetrics::Clear |
( |
| ) |
|
|
inline |
Clears all information maintained by this object. For internal use.
CoordPos64 Kaim::DatabaseGenMetrics::ComputeCellOrigin |
( |
const CellPos & |
cellPos | ) |
const |
|
inline |
Retrieves the 64-bit integer coordinates that mark the origin point of theNavCell at the specified position.
CellPos Kaim::DatabaseGenMetrics::ComputeCellPos |
( |
const Vec2f & |
pos | ) |
const |
|
inline |
Retrieves the position of theNavCell in the grid that is responsible for the specified (X,Y) coordinates.
void Kaim::DatabaseGenMetrics::ComputeCellPos |
( |
const Vec2f & |
pos, |
|
|
CellPos & |
cellPos |
|
) |
| const |
|
inline |
Retrieves the position of theNavCell in the grid that is responsible for the specified (X,Y) coordinates.
- Parameters
-
| pos | The coordinates you want to find the whichNavCell is responsible for. |
[out] | cellPos | The position of the NavCell responsible for pos. |
CellPos Kaim::DatabaseGenMetrics::ComputeCellPos |
( |
const Vec3f & |
pos | ) |
const |
|
inline |
Retrieves the position within the grid of theNavCell that is responsible for the specified coordinates.
void Kaim::DatabaseGenMetrics::ComputeCellPos |
( |
const Vec3f & |
pos, |
|
|
CellPos & |
cellPos |
|
) |
| const |
|
inline |
Retrieves the position of theNavCell in the grid that is responsible for the specified coordinates.
- Parameters
-
| pos | The coordinates you want to find the whichNavCell is responsible for. |
[out] | cellPos | The position of the NavCell responsible for pos. |
CellPos Kaim::DatabaseGenMetrics::ComputeCellPosFromCoordPos64 |
( |
const CoordPos64 & |
coordPos64 | ) |
const |
|
inline |
Retrieves the position of theNavCell in the grid that is responsible for the specified (X,Y) coordinates.
void Kaim::DatabaseGenMetrics::ComputeCellPosFromCoordPos64 |
( |
const CoordPos64 & |
coordPos64, |
|
|
CellPos & |
cellPos |
|
) |
| const |
|
inline |
Retrieves the position of theNavCell in the grid that is responsible for the specified (X,Y) coordinates.
- Parameters
-
| coordPos64 | The coordinates you want to find the whichNavCell is responsible for. |
[out] | cellPos | The position of the NavCell responsible for pos. |
void Kaim::DatabaseGenMetrics::GetCellBoxOfAnAABBox |
( |
const Box2f & |
aABB, |
|
|
CellBox & |
cellBox |
|
) |
| const |
|
inline |
Computes a CellBox from a Box2f.
void Kaim::DatabaseGenMetrics::GetCellBoxOfAnAABBox |
( |
const Box3f & |
aABB, |
|
|
CellBox & |
cellBox |
|
) |
| const |
|
inline |
Computes a CellBox from a Box3f.
void Kaim::DatabaseGenMetrics::GetCellBoxOfAnAABBox |
( |
const CoordBox64 & |
aABB, |
|
|
CellBox & |
cellBox |
|
) |
| const |
|
inline |
Computes a CellBox from a CoordBox64.
KyFloat32 Kaim::DatabaseGenMetrics::GetCellSize |
( |
| ) |
const |
|
inline |
Retrieves the size (length and width) of theNavCells in this Database.
CoordPos64 Kaim::DatabaseGenMetrics::GetCoordPos64FromVec2f |
( |
const Vec2f & |
inputPosition | ) |
const |
|
inline |
Retrieves the 64-bit integer coordinates that correspond to the specified floating-point coordinates.
void Kaim::DatabaseGenMetrics::GetCoordPos64FromVec2f |
( |
const Vec2f & |
inputPosition, |
|
|
CoordPos64 & |
result |
|
) |
| const |
|
inline |
Retrieves the 64-bit integer coordinates that correspond to the specified floating-point coordinates.
CoordPos64 Kaim::DatabaseGenMetrics::GetCoordPos64FromVec3f |
( |
const Vec3f & |
inputPosition | ) |
const |
|
inline |
Retrieves the 64-bit integer coordinates that correspond to the specified floating-point coordinates.
void Kaim::DatabaseGenMetrics::GetCoordPos64FromVec3f |
( |
const Vec3f & |
inputPosition, |
|
|
CoordPos64 & |
result |
|
) |
| const |
|
inline |
Retrieves the 64-bit integer coordinates that correspond to the specified floating-point coordinates.
Retrieves the 64-bit integer coordinates that correspond to the specified WorldIntegerPos coordinates.
void Kaim::DatabaseGenMetrics::GetCoordPos64FromWorldIntegerPos |
( |
const WorldIntegerPos & |
inputPosition, |
|
|
CoordPos64 & |
result |
|
) |
| const |
|
inline |
Retrieves the 64-bit integer coordinates that correspond to the specified WorldIntegerPos coordinates.
KyFloat32 Kaim::DatabaseGenMetrics::GetFloatValueFromInteger32 |
( |
KyInt32 |
inputValue | ) |
const |
|
inline |
Retrieves the float nearest to the specified 32-bit integer.
KyFloat32 Kaim::DatabaseGenMetrics::GetFloatValueFromInteger64 |
( |
KyInt64 |
inputValue | ) |
const |
|
inline |
Retrieves the float nearest to the specified 64-bit integer.
KyFloat32 Kaim::DatabaseGenMetrics::GetGenerationAltitudeTolerance |
( |
| ) |
const |
|
inline |
Retrieves the altitude tolerance parameters that the NavMeshes in this Database were generated with.
KyFloat32 Kaim::DatabaseGenMetrics::GetGenerationHeight |
( |
| ) |
const |
|
inline |
Retrieves the height of the character that the NavMeshes in this Database were generated for.
KyFloat32 Kaim::DatabaseGenMetrics::GetGenerationRadius |
( |
| ) |
const |
|
inline |
Retrieves the radius of the character that NavMeshes in this Database were generated for.
KyInt64 Kaim::DatabaseGenMetrics::GetNearestInteger64FromFloatValue |
( |
KyFloat32 |
inputValue | ) |
const |
|
inline |
Retrieves the 64-bit integer nearest to the specified float.
KyFloat32 Kaim::DatabaseGenMetrics::GetPixelSize |
( |
| ) |
const |
|
inline |
Retrieves the size of pixel (raster precision) that the NavMeshes in this Database were generated with.
Vec2f Kaim::DatabaseGenMetrics::GetVec2fFromCoordPos64 |
( |
const CoordPos64 & |
inputPosition | ) |
const |
|
inline |
Retrieves the floating-point coordinates that correspond to the specified 64-bit integer coordinates.
void Kaim::DatabaseGenMetrics::GetVec2fFromCoordPos64 |
( |
const CoordPos64 & |
inputPosition, |
|
|
Vec2f & |
result |
|
) |
| const |
|
inline |
Retrieves the floating-point coordinates that correspond to the specified 64-bit integer coordinates.
Vec2f Kaim::DatabaseGenMetrics::GetVec2fFromWorldIntegerPos |
( |
const WorldIntegerPos & |
inputPosition | ) |
const |
|
inline |
Retrieves the floating-point coordinates that correspond to the specified WorldIntegerPos coordinates.
void Kaim::DatabaseGenMetrics::GetVec2fFromWorldIntegerPos |
( |
const WorldIntegerPos & |
inputPosition, |
|
|
Vec2f & |
result |
|
) |
| const |
|
inline |
Retrieves the floating-point coordinates that correspond to the specified WorldIntegerPos coordinates.
Retrieves the integer coordinates that correspond to the specified 64-bit integer coordinates.
void Kaim::DatabaseGenMetrics::GetWorldIntegerPosFromCoordPos64 |
( |
const CoordPos64 & |
inputPosition, |
|
|
WorldIntegerPos & |
result |
|
) |
| const |
Retrieves the integer coordinates that correspond to the specified 64-bit integer coordinates.
WorldIntegerPos Kaim::DatabaseGenMetrics::GetWorldIntegerPosFromVec2f |
( |
const Vec2f & |
inputPosition | ) |
const |
|
inline |
Retrieves the WorldIntegerPos coordinates that correspond to the specified floating-point coordinates.
void Kaim::DatabaseGenMetrics::GetWorldIntegerPosFromVec2f |
( |
const Vec2f & |
inputPosition, |
|
|
WorldIntegerPos & |
result |
|
) |
| const |
Retrieves the WorldIntegerPos coordinates that correspond to the specified floating-point coordinates.
WorldIntegerPos Kaim::DatabaseGenMetrics::GetWorldIntegerPosFromVec3f |
( |
const Vec3f & |
inputPosition | ) |
const |
|
inline |
Retrieves the WorldIntegerPos coordinates that correspond to the specified floating-point coordinates.
void Kaim::DatabaseGenMetrics::GetWorldIntegerPosFromVec3f |
( |
const Vec3f & |
inputPosition, |
|
|
WorldIntegerPos & |
result |
|
) |
| const |
|
inline |
Retrieves the WorldIntegerPos coordinates that correspond to the specified floating-point coordinates.
void Kaim::DatabaseGenMetrics::SetDefaultValues |
( |
| ) |
|
|
inline |
Clears all information maintained by this object. For internal use.
void Kaim::DatabaseGenMetrics::Setup |
( |
| ) |
|
Initialize m_integerPrecisionInv, m_pixelSize and m_cellSizeInCoord, it has to be called after other members were properly initialized.
KyFloat32 Kaim::DatabaseGenMetrics::m_altitudeTolerance |
The maximum difference in altitude that may exist between the NavMesh and the original terrain mesh. Do not modify.
KyInt32 Kaim::DatabaseGenMetrics::m_cellSizeInCoord |
The number of integer steps in the length and width of each cell. Do not modify. Value set in Setup() based on m_cellSizeInPixel.
KyInt32 Kaim::DatabaseGenMetrics::m_cellSizeInPixel |
The number of raster pixels in the length and width of each cell. Do not modify.
KyFloat32 Kaim::DatabaseGenMetrics::m_generationHeight |
The height of the character the NavMeshes in this DatabaseGenMetrics were generated for. Do not modify.
KyFloat32 Kaim::DatabaseGenMetrics::m_generationRadius |
The radius of the character the NavMeshes in this DatabaseGenMetrics were generated for. Do not modify.
KyFloat32 Kaim::DatabaseGenMetrics::m_integerPrecision |
For internal use. Do not modify.
KyFloat32 Kaim::DatabaseGenMetrics::m_integerPrecisionInv |
For internal use. Do not modify. Value set in Setup() based on m_integerPrecision.
KyFloat32 Kaim::DatabaseGenMetrics::m_pixelSize |
For internal use. Do not modify. Value set in Setup() based on m_integerPrecision.
The documentation for this class was generated from the following files: