DebugRenderer.pkg 1.4 KB

123456789101112131415161718192021222324252627
  1. $#include "DebugRenderer.h"
  2. /// Debug geometry rendering component. Should be added only to the root scene node.
  3. class DebugRenderer : public Component
  4. {
  5. public:
  6. /// Add a line.
  7. void AddLine(const Vector3& start, const Vector3& end, const Color& color, bool depthTest = true);
  8. /// Add a line with color already converted to unsigned.
  9. void AddLine(const Vector3& start, const Vector3& end, unsigned color, bool depthTest = true);
  10. /// Add a scene node represented as its coordinate axes.
  11. void AddNode(Node* node, float scale = 1.0f, bool depthTest = true);
  12. /// Add a bounding box.
  13. void AddBoundingBox(const BoundingBox& box, const Color& color, bool depthTest = true);
  14. /// Add a bounding box with transform.
  15. void AddBoundingBox(const BoundingBox& box, const Matrix3x4& transform, const Color& color, bool depthTest = true);
  16. /// Add a frustum.
  17. void AddFrustum(const Frustum& frustum, const Color& color, bool depthTest = true);
  18. /// Add a polyhedron.
  19. void AddPolyhedron(const Polyhedron& poly, const Color& color, bool depthTest = true);
  20. /// Add a sphere.
  21. void AddSphere(const Sphere& sphere, const Color& color, bool depthTest = true);
  22. /// Add a skeleton.
  23. void AddSkeleton(const Skeleton& skeleton, const Color& color, bool depthTest = true);
  24. };
  25. DebugRenderer* GetDebugRenderer();