All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
BlockCoverageTreeCube.h
1 // Copyright (c) 2015 eeGeo. All rights reserved.
2 #pragma once
3 
4 #include "Types.h"
5 #include "BlockCoverageTrees.h"
6 #include "Streaming.h"
7 #include <vector>
8 
9 namespace Eegeo
10 {
11  namespace Streaming
12  {
13  namespace BlockCoverageTrees
14  {
16  {
17  public:
20 
21  bool HasCoverageFor(const MortonKey& mortonKey) const;
22 
23  void SetBlockCoverageTreeForFace(int face, const std::vector<u64>& blocks);
24 
25  private:
26  static const int CubeFaceCount = 6;
27 
28  bool FaceEmpty(int faceIndex) const
29  {
30  return ((1 << faceIndex) & m_hasFaceMask) == 0;
31  }
32 
33  Byte m_hasFaceMask;
34 
35  std::vector<u64> m_cubeFaces[6];
36  };
37  }
38  }
39 }