1#ifndef OE_RENDER_DEBUG_H
2#define OE_RENDER_DEBUG_H
6#ifndef OXYGEN_ENGINE_DEBUG_TOOLS
7 #error Debug tools are not included in this build, please enable then with OE_DEBUG_TOOLS CMake option
10#include <glm/vec3.hpp>
11#include <glm/matrix.hpp>
24namespace oe::detail::dd
26 class OxygenEngineRenderInterface;
44 static void axis(
const float& length = 1.0f,
const float& arrow_size = 0.1f);
53 static void transform(
const glm::mat4& model,
const float& length = 1.0f,
const float& arrow_size = 0.1f);
59 static void tbn(
const glm::vec3& origin,
const glm::vec3& tangent,
const glm::vec3& bitangent,
const glm::vec3& normal,
const float& length = 1.0);
76 static void point(
const glm::vec3& position,
const float& size = 10.0f,
const glm::vec3& color = glm::vec3(1.0));
85 static void sphere(
const glm::vec3& center,
const float& radius,
const glm::vec3& color = glm::vec3(1.0));
94 static void box(
const glm::vec3& min,
const glm::vec3& max,
const glm::vec3& color = glm::vec3(1.0));
103 static void line(
const glm::vec3& start,
const glm::vec3& end,
const glm::vec3& color = glm::vec3(1.0));
105 static void arrow(
const glm::vec3& start,
const glm::vec3& end,
const float& size = 1.0f,
const glm::vec3& color = glm::vec3(1.0));
106 static void cone(
const glm::vec3& start,
const glm::vec3& end,
const float& baseAngle = 1.0f,
const float& apexAngle = 0.0f,
const glm::vec3& color = glm::vec3(1.0));
127 static Debug* getInstance()
136 detail::dd::OxygenEngineRenderInterface* _render_interface =
nullptr;
137 void* _ctx =
nullptr;
139 static Debug* _instance;
The OxygenEngine device that will manage events, windows, scene, etc...
Definition device.h:18
Render simple shapes for debugging purposes.
Definition debug.h:36
void render(oe::scene::Camera &camera, const bool flush=true)
Render all debug objects and clean buffer.
static void box(const glm::vec3 &min, const glm::vec3 &max, const glm::vec3 &color=glm::vec3(1.0))
Draw a box between two corners.
static void axis(const float &length=1.0f, const float &arrow_size=0.1f)
Draw origin axis.
static void point(const glm::vec3 &position, const float &size=10.0f, const glm::vec3 &color=glm::vec3(1.0))
Draw a point.
static void frustum(const oe::scene::Camera &camera, const glm::vec3 &color=glm::vec3(1.0))
Draw the frustum pyramid of a camera.
static void sphere(const glm::vec3 ¢er, const float &radius, const glm::vec3 &color=glm::vec3(1.0))
Draw a sphere.
static void line(const glm::vec3 &start, const glm::vec3 &end, const glm::vec3 &color=glm::vec3(1.0))
Draw a line between two points.
static void transform(const glm::mat4 &model, const float &length=1.0f, const float &arrow_size=0.1f)
Draw a transform.
static void tbn(const glm::vec3 &origin, const glm::vec3 &tangent, const glm::vec3 &bitangent, const glm::vec3 &normal, const float &length=1.0)
Render vertex TBN (Tangent, bi-tangent, normal)
static void aabb(const oe::scene::AABB &bbox, const glm::vec3 &color=glm::vec3(1.0))
Draw a bounding box.
void flush()
Flush buffer without rendering.
Axis-aligned bounding box.
Definition aabb.h:13
The "eye of the scene".
Definition camera.h:33
Core functionality (windows, event handler, logger, ...)
Definition cursor.h:8
Render related abstractions (Shader, Framebuffer, Cubemaps, Textures)
Definition opengl.h:10
Scene related management (Render-agnostic Geometry, Manger, etc...)
Definition debug.h:19