gwnavruntime/navmesh/identifiers/stitch1to1edgelink.h Source File
Go to the documentation of this file.
10 #ifndef Navigation_Stitch1To1EdgeLink_H
11 #define Navigation_Stitch1To1EdgeLink_H
22 class Stitch1To1EdgeLink
33 Stitch1To1EdgeLink(NavFloor* navFloor,
KyUInt32 stitch1To1EdgeIdx);
38 void Set(NavFloor* navFloor,
KyUInt32 stitch1To1EdgeIdx);
45 bool operator==(const Stitch1To1EdgeLink& rhs) const;
46 bool operator!=(const Stitch1To1EdgeLink& rhs) const;
54 NavFloor* GetNavFloor() const;
58 const NavFloorBlob* GetNavFloorBlob() const;
63 KyUInt16 m_correspondingOfStitch1To1Idx;
68 KY_INLINE Stitch1To1EdgeLink::Stitch1To1EdgeLink() : m_navFloor(), m_stitch1To1EdgeIdx(
KyUInt16MAXVAL), m_correspondingOfStitch1To1Idx(KyUInt16MAXVAL) {}
70 KY_INLINE Stitch1To1EdgeLink::Stitch1To1EdgeLink(NavFloor* navFloor,
NavHalfEdgeIdx stitch1To1EdgeIdx) :
71 m_navFloor(navFloor), m_stitch1To1EdgeIdx((CompactNavHalfEdgeIdx)stitch1To1EdgeIdx), m_correspondingOfStitch1To1Idx(
KyUInt16MAXVAL) {}
73 KY_INLINE
void Stitch1To1EdgeLink::Set(NavFloor* navFloor,
NavHalfEdgeIdx stitch1To1EdgeIdx)
75 m_navFloor = navFloor;
76 m_stitch1To1EdgeIdx = (CompactNavHalfEdgeIdx)stitch1To1EdgeIdx;
80 KY_INLINE
bool Stitch1To1EdgeLink::IsValid()
const {
return m_navFloor !=
KY_NULL && m_stitch1To1EdgeIdx !=
KyUInt16MAXVAL; }
83 KY_INLINE
bool Stitch1To1EdgeLink::operator==(
const Stitch1To1EdgeLink& rhs)
const {
return m_navFloor == rhs.m_navFloor && m_stitch1To1EdgeIdx == rhs.m_stitch1To1EdgeIdx;}
84 KY_INLINE
bool Stitch1To1EdgeLink::operator!=(
const Stitch1To1EdgeLink& rhs)
const {
return !(*
this == rhs); }
86 KY_INLINE NavFloor* Stitch1To1EdgeLink::GetNavFloor()
const {
return m_navFloor; }
87 KY_INLINE
const NavFloorBlob* Stitch1To1EdgeLink::GetNavFloorBlob()
const {
return m_navFloor->GetNavFloorBlob(); }
90 #endif //Navigation_Stitch1To1EdgeLink_H
KyUInt32 NavHalfEdgeIdx
An index that uniquely identifies a single edge of a triangle within the set of edges owned by a NavF...
Definition: navmeshtypes.h:87
#define KY_NULL
Null value.
Definition: types.h:247
Definition: gamekitcrowddispersion.h:20
#define KY_DEFINE_NEW_DELETE_OPERATORS(MemStat)
This macro defines new and delete operators.
Definition: memory.h:137
#define KyUInt16MAXVAL
The maximum value that can be stored in the KyUInt16 variable type.
Definition: types.h:230
unsigned short KyUInt16
Type used internally to represent an unsigned 16-bit integer.
Definition: types.h:40
unsigned int KyUInt32
Type used internally to represent an unsigned 32-bit integer.
Definition: types.h:36