|
SolarSim
|
Handles all rendering operations and graphics state. More...
#include <renderer.hpp>
Data Structures | |
| struct | CameraUBO |
| struct | LightData |
| struct | LightsUBO |
| struct | RBData |
| struct | RBUBO |
Public Member Functions | |
| Renderer () | |
| ~Renderer () | |
| void | render () |
| Execute one frame of rendering. | |
| void | toggleGrid () |
| Toggle grid visibility. | |
Private Member Functions | |
| void | bindCameraMatrices (Registry ®) |
| Bind camera matrices to UBO. | |
| void | bindLightUBOS (Registry ®) |
| Bind light data to UBO. | |
| void | bindRigidBodyUBOS (Registry ®) |
| Bind rigid body data to UBO. | |
| void | renderGrid (Registry ®) |
| Render the debug grid. | |
| void | renderLights (Registry ®) |
| Render all light entities. | |
| void | renderMeshes (Registry ®) |
| Render all mesh entities. | |
| void | renderGui (Registry ®) |
| Toggle grid visibility. | |
Private Attributes | |
| uint32_t | cameraUBO |
| uint32_t | lightsUBO |
| uint32_t | rbUBO |
| bool | showGrid = true |
| glm::vec4 | clearColor = glm::vec4(0.0f, 0.0f, 0.0f, 1.0f) |
Handles all rendering operations and graphics state.
| solarsim::Renderer::Renderer | ( | ) |
| solarsim::Renderer::~Renderer | ( | ) |
|
private |
Bind camera matrices to UBO.
| reg | Registry containing camera entities |
|
private |
Bind light data to UBO.
| reg | Registry containing light entities |
|
private |
Bind rigid body data to UBO.
| reg | Registry containing rigid body entities |
| void solarsim::Renderer::render | ( | ) |
Execute one frame of rendering.
|
private |
Render the debug grid.
| reg | Registry containing grid entities |
|
private |
Toggle grid visibility.
|
private |
Render all light entities.
| reg | Registry containing mesh entities |
|
private |
Render all mesh entities.
| reg | Registry containing mesh entities |
|
inline |
Toggle grid visibility.
|
private |
OpenGL handle for camera UBO
|
private |
OpenGL clear buffer bit color
|
private |
OpenGL handle for lights UBO
|
private |
OpenGL handle for rigid bodies UBO
|
private |
Whether to render the debug grid