RenderQueue.ixx File
Container for enqueued render commands and renderables. More...
Included Headers
#include <cassert>
#include <format>
#include <helios/helios_config.h>
#include <memory>
#include <span>
#include <vector>
#include <helios.util.log.LogManager>
#include <helios.util.log.Logger>
#include <helios.rendering.text.TextRenderCommand>
#include <helios.rendering.mesh.MeshRenderCommand>
Namespaces Index
| namespace | helios |
| namespace | rendering |
|
Graphics rendering infrastructure. More... | |
Classes Index
| class | RenderQueue |
|
Manages collections of render commands for geometry and text. More... | |
Macro Definitions Index
| #define | HELIOS_LOG_SCOPE "helios::rendering::RenderQueue" |
Description
Container for enqueued render commands and renderables.
Macro Definitions
HELIOS_LOG_SCOPE
|
Definition at line 22 of file RenderQueue.ixx.
22#define HELIOS_LOG_SCOPE "helios::rendering::RenderQueue"
File Listing
The file content with the documentation metadata removed is:
22#define HELIOS_LOG_SCOPE "helios::rendering::RenderQueue"
23export namespace helios::rendering {
46 class RenderQueue {
52 std::vector<helios::rendering::mesh::MeshRenderCommand> meshRenderCommands_;
57 std::vector<helios::rendering::text::TextRenderCommand> textRenderCommands_;
62 inline static const helios::util::log::Logger& logger_ = helios::util::log::LogManager::loggerForScope(HELIOS_LOG_SCOPE);
65 ~RenderQueue() = default;
70 RenderQueue(const RenderQueue&) = delete;
75 RenderQueue& operator=(const RenderQueue&) = delete;
78 RenderQueue(RenderQueue&&) noexcept = default;
81 RenderQueue& operator=(RenderQueue&&) noexcept = default;
86 RenderQueue() {
87 textRenderCommands_.reserve(RENDERQUEUE_TEXTRENDER_COMMANDS_SIZE);
88 meshRenderCommands_.reserve(RENDERQUEUE_MESHRENDER_COMMANDS_SIZE);
100 void add(helios::rendering::mesh::MeshRenderCommand renderCommand) {
101 meshRenderCommands_.emplace_back(std::move(renderCommand));
112 void add(helios::rendering::text::TextRenderCommand renderCommand) {
113 textRenderCommands_.emplace_back(std::move(renderCommand));
121 [[nodiscard]] std::span<const helios::rendering::mesh::MeshRenderCommand> meshRenderCommands() const noexcept {
122 return meshRenderCommands_;
130 [[nodiscard]] std::span<const helios::rendering::text::TextRenderCommand> textRenderCommands() const noexcept {
131 return textRenderCommands_;
140 meshRenderCommands_.clear();
141 textRenderCommands_.clear();
156 [[nodiscard]] size_t meshRenderCommandsSize() const noexcept {
157 return meshRenderCommands_.size();
165 [[nodiscard]] size_t textRenderCommandsSize() const noexcept {
166 return textRenderCommands_.size();
Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.15.0.