gwnavruntime/abstractgraph/identifiers/loadedabstractgraphcellidx.h Source File

loadedabstractgraphcellidx.h
Go to the documentation of this file.
1 /*
2 * Copyright 2015 Autodesk, Inc. All rights reserved.
3 * Use of this software is subject to the terms of the Autodesk license agreement and any attachments or Appendices thereto provided at the time of installation or download,
4 * or which otherwise accompanies this software in either electronic or hard copy form, or which is signed by you and accepted by Autodesk.
5 */
6 
7 #ifndef Navigation_LoadedAbstractGraphCellIdx_H
8 #define Navigation_LoadedAbstractGraphCellIdx_H
9 
11 
12 namespace Kaim
13 {
14 
15 class LoadedAbstractGraphCellIdx
16 {
17  KY_DEFINE_NEW_DELETE_OPERATORS(MemStat_NavData)
18 public:
19  LoadedAbstractGraphCellIdx() { Invalidate(); }
20 
21  bool HasAbstractGraphNodes() const { return m_abstractGraphInGridIdx < AbstractGraphIdx_Invalid && m_cellInBlobIdx < AbstractGraphCellIdx_Invalid; }
22  bool IsInAbstractGraph() const { return m_abstractGraphInGridIdx < AbstractGraphIdx_Invalid; }
23  void Invalidate()
24  {
25  m_abstractGraphInGridIdx = AbstractGraphIdx_Invalid;
26  m_cellInBlobIdx = AbstractGraphCellIdx_Invalid;
27  }
28 
29  AbstractGraphIdx m_abstractGraphInGridIdx;
30  AbstractGraphCellIdx m_cellInBlobIdx;
31 };
32 
33 }
34 
35 #endif
Definition: gamekitcrowddispersion.h:20
#define KY_DEFINE_NEW_DELETE_OPERATORS(MemStat)
This macro defines new and delete operators.
Definition: memory.h:137