All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
DebugLineRendererEcef.h
1 // Copyright (c) 2014 eeGeo. All rights reserved.
2 
3 #pragma once
4 
5 #include "VectorMath.h"
6 #include "DynamicBuffer.h"
7 #include "Rendering.h"
8 #include "AllVertexTypes.h"
9 #include "Streaming.h"
10 #include "DebugLineRenderable.h"
11 #include "Camera.h"
12 #include "IRenderableFilter.h"
13 
14 namespace Eegeo
15 {
16  namespace DebugRendering
17  {
18  namespace Renderers
19  {
21  {
22  struct DebugLineEcef
23  {
24  dv3 P0;
25  dv3 P1;
26  v4 Color;
27  float Lifetime;
28  };
29 
30  public:
32  const Rendering::VertexLayouts::VertexBinding& vertexBinding,
33  int vertexBufferSize,
34  float lineWidth);
35 
37 
38  void SetLineWidth(float lineWidth);
39 
40  void DrawLine(const dv3& ecefPointA,
41  const dv3& ecefPointB,
42  const v4& color,
43  const float lifetime = 0.0f
44  );
45 
46  void Update(float dt, const Camera::RenderCamera& renderCamera);
47 
48  void GenerateGeometry(const Camera::RenderCamera& renderCamera);
49 
50  void EnqueueRenderables(const Rendering::RenderContext& renderContext, Rendering::RenderQueue& renderQueue);
51 
52  void SetDepthEnabled(const bool depthEnabled);
53 
54  private:
55  std::vector<DebugLineEcef> m_drawData;
56 
57  DebugLineRenderable* m_pDebugLineRenderable;
58  };
59  }
60  }
61 }
62 
63