All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
RouteVertexDebugVisualiser.h
1 // Copyright eeGeo Ltd (2012-2014), All Rights Reserved
2 
3 #pragma once
4 
5 #include "Rendering.h"
6 #include "Routes.h"
7 #include "DebugRendering.h"
8 #include "MortonKey.h"
9 #include "FittedRouteCallback.h"
10 #include "RouteVertexDebugVisualiser.h"
11 #include "RouteCallback.h"
12 #include "VectorMathDecl.h"
13 
14 #include <vector>
15 #include <map>
16 
17 namespace Eegeo
18 {
19  namespace Routes
20  {
22  {
23  private:
24  Routes::Fitting::FittedRouteRepository& m_fittedRouteRepository;
25  Routes::RouteRepository& m_routeRepository;
26  DebugRendering::DebugRenderer& m_debugRenderer;
27 
28  typedef std::vector<DebugRendering::DebugSphereData*> TSphereVector;
29  std::map<Streaming::MortonKey, TSphereVector> m_sphereMap;
30  bool m_enabled;
31 
35 
36  void GenerateVertexDebugSpheres(const Routes::Route* pRoute, const Streaming::MortonKey& key);
37  void RemoveSpheres(const Routes::Route* pRoute, const Streaming::MortonKey key);
38  void RemoveAllSpheres();
39 
40  void HandleFittedRouteAdded(const Fitting::FittedRoute& fittedRoute);
41  void HandleFittedRouteRemoved(const Fitting::FittedRoute& fittedRoute);
42  void HandleRouteRemoved(const Route* route);
43 
44  public:
46  Routes::RouteRepository& routeRepository,
47  DebugRendering::DebugRenderer& debugRenderer);
48 
50 
51 
52  void RenderSpheres();
53  bool GetEnabled() const { return m_enabled; };
54  void ToggleEnabled();
55  };
56  }
57 }