Kaim::NavFloorBlob Class Reference

Kaim::NavFloorBlob Class Reference

#include <navfloorblob.h>

Class Description

The NavFloorBlob contains a connected and not overlapping part of triangle mesh static data within a NavCellBlob.

NavTriangles are implicitly defined by three consecutive NavHalfEdge in m_navHalfEdges, there is no explicit NavTriangle class. A NavTag is associated to each NavTriangle

Public Attributes

BlobArray< CompactNavConnexIdx > m_triangleConnexIndices
 The array of CompactNavConnexIdx associated to each triangle. GetCount() == GetTriangleCount(). Do not modify. More...
 
BlobArray< NavTag > m_connexNavTag
 The array of NavTag associated to each NavConnex. GetCount() == GetConnexCount(). Do not modify. More...
 
BlobArray< NavHalfEdgem_navHalfEdges
 The array of triangle edges maintained by the NavFloorBlob. GetCount() == GetHalfEdgeCount(). Do not modify. More...
 
BlobArray< NavVertex > m_navVertices
 The array of triangle vertices maintained by the NavFloorBlob. GetCount() == GetVertexCount(). Do not modify. More...
 
BlobArray< KyFloat32m_navVerticesAltitudes
 The array of triangle vertices altitude maintained by the NavFloorBlob. GetCount() == GetVertexCount(). Do not modify. More...
 
FloorAltitudeRange m_altitudeRange
 The range of altitude the vertices of this NavFloor are within. More...
 
NavFloorAABB m_navFloorAABB
 An axis-oriented bounding box that stores the extents of this NavFloorBlob. More...
 

static member functions

static NavTriangleIdx NavHalfEdgeIdxToTriangleIdx (NavHalfEdgeIdx idx)
 Retrieves the index of the triangle that contains the edge specified the input NavHalfEdgeIdx. More...
 
static NavHalfEdgeIdx NavTriangleIdxToFirstNavHalfEdgeIdx (NavTriangleIdx idx)
 Retrieves the first NavHalfEdgeIdx of NavTriangle specified by the input NavTriangleIdx. More...
 
static NavHalfEdgeIdx NavHalfEdgeIdxToFirstNavHalfEdgeIdx (NavHalfEdgeIdx idx)
 Retrieves the first NavHalfEdgeIdx of NavTriangle thet contains the edge specified by the input NavHalfEdgeIdx. More...
 
static NavHalfEdgeIdx NavHalfEdgeIdxToNextNavHalfEdgeIdx (NavHalfEdgeIdx idx)
 Retrieves the triangle NavHalfEdgeIdx that follows the edge specified the input NavHalfEdgeIdx within its triangle. More...
 
static NavHalfEdgeIdx NavHalfEdgeIdxToPrevNavHalfEdgeIdx (NavHalfEdgeIdx idx)
 Retrieves the triangle NavHalfEdgeIdx that precedes the edge specified the input NavHalfEdgeIdx within its triangle. More...
 
static NavHalfEdgeIdx NavTriangleIdxToNavHalfEdgeIdx (NavTriangleIdx idx, KyInt32 halfEdgeNumber)
 Retrieves one edge from the specified triangle. More...
 
static KyUInt32 NavHalfEdgeIdxToHalfEdgeNumberInTriangle (NavHalfEdgeIdx idx)
 Retrieves the index of the specified edge within its triangle. More...
 

accessors

KyUInt32 GetNavVertexCount () const
 
KyUInt32 GetNavHalfEdgeCount () const
 
KyUInt32 GetNavTriangleCount () const
 
const FloorAltitudeRangeGetFloorAltitudeRange () const
 
const NavTag & GetNavTag (NavTriangleIdx navTriangleIdx) const
 Retrieves the NavTag associated to this triangle. More...
 
const NavVertex & GetNavVertex (const NavVertexIdx idx) const
 Retrieves the vertex with the specified index within this NavFloorBlob. More...
 
const NavHalfEdgeGetNavHalfEdge (NavHalfEdgeIdx idx) const
 Retrieves the triangle edge with the specified index within this NavFloorBlob. More...
 
KyFloat32 GetNavVertexAltitude (const NavVertexIdx idx) const
 Retrieves the altitude of the vertex with the specified index within this NavFloorBlob. More...
 
NavHalfEdgeType GetHalfEdgeType (NavHalfEdgeIdx idx) const
 Retrieves the type of the specified triangle edge. More...
 
NavHalfEdgeObstacleType GetHalfEdgeObstacleType (NavHalfEdgeIdx idx) const
 Retrieves the obstacle type of the specified triangle edge. More...
 

function to browse the NavFloorBlob data structure

const NavVertex & NavHalfEdgeIdxToStartNavVertex (NavHalfEdgeIdx idx) const
 Retrieves the vertex at the start of the specified triangle edge. More...
 
NavVertexIdx NavHalfEdgeIdxToStartNavVertexIdx (NavHalfEdgeIdx idx) const
 Retrieves the index of the vertex at the start of the specified triangle edge. More...
 
const NavVertex & NavHalfEdgeIdxToEndNavVertex (NavHalfEdgeIdx idx) const
 Retrieves the vertex at the end of the specified triangle edge. More...
 
NavVertexIdx NavHalfEdgeIdxToEndNavVertexIdx (NavHalfEdgeIdx idx) const
 Retrieves the index of the vertex at the end of the specified triangle edge. More...
 
const NavVertex & NavHalfEdgeIdxToThirdNavVertex (NavHalfEdgeIdx idx) const
 Retrieves the vertex in the triangle that is not connected to the specified triangle edge. More...
 
NavVertexIdx NavHalfEdgeIdxToThirdNavVertexIdx (NavHalfEdgeIdx idx) const
 Retrieves the index of the vertex in the triangle that is not connected to the specified triangle edge. More...
 
const NavHalfEdgeNavHalfEdgeIdxToPairNavHalfEdge (NavHalfEdgeIdx idx) const
 Retrieves the triangle edge that is adjacent to the specified triangle edge, if any. More...
 
NavHalfEdgeIdx NavHalfEdgeIdxToPairNavHalfEdgeIdx (NavHalfEdgeIdx idx) const
 Retrieves the index of the triangle edge that is adjacent to the specified triangle edge, if any. More...
 
const NavHalfEdgeNavHalfEdgeIdxToNextNavHalfEdge (NavHalfEdgeIdx idx) const
 Retrieves the edge that follows the specified triangle edge within its triangle. More...
 
const NavHalfEdgeNavHalfEdgeIdxToPrevNavHalfEdge (NavHalfEdgeIdx idx) const
 Retrieves the edge that precedes the specified triangle edge within its triangle. More...
 
const NavHalfEdgeNavTriangleIdxToNavHalfEdge (NavTriangleIdx idx, const KyInt32 halfEdgeNumber) const
 Retrieves one edge from the specified triangle. More...
 
void NavTriangleIdxToNavVertexIndices (NavTriangleIdx triangleIdx, NavVertexIdx &v0Idx, NavVertexIdx &v1Idx, NavVertexIdx &v2Idx) const
 Retrieves the indices of the vertices that make up the specified triangle. More...
 
const NavVertex & NavTriangleIdxToNavVertex (NavTriangleIdx idx, const KyInt32 vertexNumber) const
 Retrieves one vertex from the specified triangle. More...
 
NavVertexIdx NavTriangleIdxToVertexIdx (NavTriangleIdx idx, const KyInt32 vertexNumber) const
 Retrieves the index of one vertex from the specified triangle. More...
 

geometrical test

bool IsPointInsideFloor (const CoordPos64 &coordPos64, const CoordPos64 &cellOrigin) const
 Indicates whether or not the specified position lies inside the bounding box of the NavFloorBlob on the (X,Y) plane. For internal use. More...
 
bool IsPointInsideFloor (const CoordPos &coordPosInCell) const
 Indicates whether or not the specified position lies inside the bounding box of the NavFloorBlob on the (X,Y) plane. For internal use. More...
 

For internal use only

KyUInt32 GetNavConnexCount () const
 
NavConnexIdx NavTriangleIdxToNavConnexIdx (NavTriangleIdx idx) const
 Retrieves the index of the NavConnex associated to the triangle specified by the input NavTriangleIdx. More...
 
bool IsValid () const
 performs some basic tests on static data. For internal debug purpose. More...
 
bool IsTriangleValid (NavTriangleIdx idx) const
 performs some basic tests on static data. For internal debug purpose. More...
 
bool IsHalfEdgeValid (NavHalfEdgeIdx currentEdgeIdx, const Vec2i &v1, const Vec2i &v2) const
 
KyUInt32 GetNavFloorLinkCount () const
 
KyUInt32 GetStitch1To1EdgeCount () const
 

Member Function Documentation

NavHalfEdgeObstacleType Kaim::NavFloorBlob::GetHalfEdgeObstacleType ( NavHalfEdgeIdx  idx) const
inline

Retrieves the obstacle type of the specified triangle edge.

NavHalfEdgeType Kaim::NavFloorBlob::GetHalfEdgeType ( NavHalfEdgeIdx  idx) const
inline

Retrieves the type of the specified triangle edge.

const NavHalfEdge & Kaim::NavFloorBlob::GetNavHalfEdge ( NavHalfEdgeIdx  idx) const
inline

Retrieves the triangle edge with the specified index within this NavFloorBlob.

const NavTag & Kaim::NavFloorBlob::GetNavTag ( NavTriangleIdx  navTriangleIdx) const
inline

Retrieves the NavTag associated to this triangle.

const NavVertex & Kaim::NavFloorBlob::GetNavVertex ( const NavVertexIdx  idx) const
inline

Retrieves the vertex with the specified index within this NavFloorBlob.

KyFloat32 Kaim::NavFloorBlob::GetNavVertexAltitude ( const NavVertexIdx  idx) const
inline

Retrieves the altitude of the vertex with the specified index within this NavFloorBlob.

bool Kaim::NavFloorBlob::IsPointInsideFloor ( const CoordPos64 coordPos64,
const CoordPos64 cellOrigin 
) const
inline

Indicates whether or not the specified position lies inside the bounding box of the NavFloorBlob on the (X,Y) plane. For internal use.

bool Kaim::NavFloorBlob::IsPointInsideFloor ( const CoordPos coordPosInCell) const
inline

Indicates whether or not the specified position lies inside the bounding box of the NavFloorBlob on the (X,Y) plane. For internal use.

bool Kaim::NavFloorBlob::IsTriangleValid ( NavTriangleIdx  idx) const

performs some basic tests on static data. For internal debug purpose.

function to test if a navTriangle is valid TODO : maybe the function should be moved elsewhere...

bool Kaim::NavFloorBlob::IsValid ( ) const

performs some basic tests on static data. For internal debug purpose.

const NavVertex & Kaim::NavFloorBlob::NavHalfEdgeIdxToEndNavVertex ( NavHalfEdgeIdx  idx) const
inline

Retrieves the vertex at the end of the specified triangle edge.

NavVertexIdx Kaim::NavFloorBlob::NavHalfEdgeIdxToEndNavVertexIdx ( NavHalfEdgeIdx  idx) const
inline

Retrieves the index of the vertex at the end of the specified triangle edge.

NavHalfEdgeIdx Kaim::NavFloorBlob::NavHalfEdgeIdxToFirstNavHalfEdgeIdx ( NavHalfEdgeIdx  idx)
inlinestatic

Retrieves the first NavHalfEdgeIdx of NavTriangle thet contains the edge specified by the input NavHalfEdgeIdx.

KyUInt32 Kaim::NavFloorBlob::NavHalfEdgeIdxToHalfEdgeNumberInTriangle ( NavHalfEdgeIdx  idx)
inlinestatic

Retrieves the index of the specified edge within its triangle.

Returns
0, 1 or 2.
const NavHalfEdge & Kaim::NavFloorBlob::NavHalfEdgeIdxToNextNavHalfEdge ( NavHalfEdgeIdx  idx) const
inline

Retrieves the edge that follows the specified triangle edge within its triangle.

NavHalfEdgeIdx Kaim::NavFloorBlob::NavHalfEdgeIdxToNextNavHalfEdgeIdx ( NavHalfEdgeIdx  idx)
inlinestatic

Retrieves the triangle NavHalfEdgeIdx that follows the edge specified the input NavHalfEdgeIdx within its triangle.

const NavHalfEdge & Kaim::NavFloorBlob::NavHalfEdgeIdxToPairNavHalfEdge ( NavHalfEdgeIdx  idx) const
inline

Retrieves the triangle edge that is adjacent to the specified triangle edge, if any.

NavHalfEdgeIdx Kaim::NavFloorBlob::NavHalfEdgeIdxToPairNavHalfEdgeIdx ( NavHalfEdgeIdx  idx) const
inline

Retrieves the index of the triangle edge that is adjacent to the specified triangle edge, if any.

const NavHalfEdge & Kaim::NavFloorBlob::NavHalfEdgeIdxToPrevNavHalfEdge ( NavHalfEdgeIdx  idx) const
inline

Retrieves the edge that precedes the specified triangle edge within its triangle.

NavHalfEdgeIdx Kaim::NavFloorBlob::NavHalfEdgeIdxToPrevNavHalfEdgeIdx ( NavHalfEdgeIdx  idx)
inlinestatic

Retrieves the triangle NavHalfEdgeIdx that precedes the edge specified the input NavHalfEdgeIdx within its triangle.

const NavVertex & Kaim::NavFloorBlob::NavHalfEdgeIdxToStartNavVertex ( NavHalfEdgeIdx  idx) const
inline

Retrieves the vertex at the start of the specified triangle edge.

NavVertexIdx Kaim::NavFloorBlob::NavHalfEdgeIdxToStartNavVertexIdx ( NavHalfEdgeIdx  idx) const
inline

Retrieves the index of the vertex at the start of the specified triangle edge.

const NavVertex & Kaim::NavFloorBlob::NavHalfEdgeIdxToThirdNavVertex ( NavHalfEdgeIdx  idx) const
inline

Retrieves the vertex in the triangle that is not connected to the specified triangle edge.

NavVertexIdx Kaim::NavFloorBlob::NavHalfEdgeIdxToThirdNavVertexIdx ( NavHalfEdgeIdx  idx) const
inline

Retrieves the index of the vertex in the triangle that is not connected to the specified triangle edge.

NavTriangleIdx Kaim::NavFloorBlob::NavHalfEdgeIdxToTriangleIdx ( NavHalfEdgeIdx  idx)
inlinestatic

Retrieves the index of the triangle that contains the edge specified the input NavHalfEdgeIdx.

+ Examples:
NavHalfEdgeIdx Kaim::NavFloorBlob::NavTriangleIdxToFirstNavHalfEdgeIdx ( NavTriangleIdx  idx)
inlinestatic

Retrieves the first NavHalfEdgeIdx of NavTriangle specified by the input NavTriangleIdx.

+ Examples:
NavConnexIdx Kaim::NavFloorBlob::NavTriangleIdxToNavConnexIdx ( NavTriangleIdx  idx) const
inline

Retrieves the index of the NavConnex associated to the triangle specified by the input NavTriangleIdx.

const NavHalfEdge & Kaim::NavFloorBlob::NavTriangleIdxToNavHalfEdge ( NavTriangleIdx  idx,
const KyInt32  halfEdgeNumber 
) const
inline

Retrieves one edge from the specified triangle.

Parameters
idxThe index of the triangle whose edge is to be retrieved.
halfEdgeNumberThe index of the edge to retrieve within the triangle. May be 0, 1 or 2.
NavHalfEdgeIdx Kaim::NavFloorBlob::NavTriangleIdxToNavHalfEdgeIdx ( NavTriangleIdx  idx,
KyInt32  halfEdgeNumber 
)
inlinestatic

Retrieves one edge from the specified triangle.

Parameters
idxThe index of the triangle whose edge is to be retrieved.
halfEdgeNumberThe index of the edge to retrieve within the triangle. May be 0, 1 or 2.
const NavVertex & Kaim::NavFloorBlob::NavTriangleIdxToNavVertex ( NavTriangleIdx  idx,
const KyInt32  vertexNumber 
) const
inline

Retrieves one vertex from the specified triangle.

Parameters
idxThe index of the triangle whose edge is to be retrieved.
vertexNumberThe index of the vertex to retrieve within the triangle. May be 0, 1 or 2.
void Kaim::NavFloorBlob::NavTriangleIdxToNavVertexIndices ( NavTriangleIdx  triangleIdx,
NavVertexIdx v0Idx,
NavVertexIdx v1Idx,
NavVertexIdx v2Idx 
) const
inline

Retrieves the indices of the vertices that make up the specified triangle.

Parameters
triangleIdxThe index of the triangle whose vertices are to be retrieved.
[out]v0IdxThe index of the first vertex in the triangle.
[out]v1IdxThe index of the second vertex in the triangle.
[out]v2IdxThe index of the third vertex in the triangle.
NavVertexIdx Kaim::NavFloorBlob::NavTriangleIdxToVertexIdx ( NavTriangleIdx  idx,
const KyInt32  vertexNumber 
) const
inline

Retrieves the index of one vertex from the specified triangle.

Parameters
idxThe index of the triangle whose edge is to be retrieved.
vertexNumberThe index of the vertex to retrieve within the triangle. May be 0, 1 or 2.

Member Data Documentation

FloorAltitudeRange Kaim::NavFloorBlob::m_altitudeRange

The range of altitude the vertices of this NavFloor are within.

+ Examples:
BlobArray<NavTag> Kaim::NavFloorBlob::m_connexNavTag

The array of NavTag associated to each NavConnex. GetCount() == GetConnexCount(). Do not modify.

NavFloorAABB Kaim::NavFloorBlob::m_navFloorAABB

An axis-oriented bounding box that stores the extents of this NavFloorBlob.

BlobArray<NavHalfEdge> Kaim::NavFloorBlob::m_navHalfEdges

The array of triangle edges maintained by the NavFloorBlob. GetCount() == GetHalfEdgeCount(). Do not modify.

BlobArray<NavVertex> Kaim::NavFloorBlob::m_navVertices

The array of triangle vertices maintained by the NavFloorBlob. GetCount() == GetVertexCount(). Do not modify.

BlobArray<KyFloat32> Kaim::NavFloorBlob::m_navVerticesAltitudes

The array of triangle vertices altitude maintained by the NavFloorBlob. GetCount() == GetVertexCount(). Do not modify.

BlobArray<CompactNavConnexIdx> Kaim::NavFloorBlob::m_triangleConnexIndices

The array of CompactNavConnexIdx associated to each triangle. GetCount() == GetTriangleCount(). Do not modify.


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