Skip to main content

LegacyRenderPass Class

Encapsulates a single rendering pass with its associated resources. More...

Declaration

class helios::rendering::LegacyRenderPass { ... }

Public Constructors Index

LegacyRenderPass (const LegacyRenderPass &)=delete

Prevent copying. A LegacyRenderPass is not intended to be copied. More...

LegacyRenderPass (LegacyRenderPass &&) noexcept=default

Allow move. More...

LegacyRenderPass (const helios::rendering::Viewport *viewport, helios::rendering::RenderQueue renderQueue, const helios::rendering::shader::UniformValueMap &frameUniformValues) noexcept

Creates a new `LegacyRenderPass` with the specified viewport, render queue, and frame uniforms. More...

Public Destructor Index

~LegacyRenderPass ()=default

Public Operators Index

LegacyRenderPass &operator= (const LegacyRenderPass &)=delete

Prevent copy assignment. A LegacyRenderPass is not intended to be copied. More...

LegacyRenderPass &operator= (LegacyRenderPass &&) noexcept=default

Allow move assignment. More...

Public Member Functions Index

const RenderQueue &renderQueue () const noexcept

Returns a const ref to the `RenderQueue` this `LegacyRenderPass` holds. More...

const Viewport &viewport () const noexcept

Returns a const ref to the `Viewport` this `LegacyRenderPass` holds. More...

voidsetFrameUniformValues (const helios::rendering::shader::UniformValueMap &frameUniformValues) noexcept

Sets the frame-specific uniform values for this pass. More...

const helios::rendering::shader::UniformValueMap &frameUniformValues () const noexcept

Returns a const reference to this `LegacyRenderPass`' `UniformValueMap`. More...

Private Member Attributes Index

helios::rendering::RenderQueuerenderQueue_

The `RenderQueue` for this pass, containing all render commands. More...

helios::rendering::shader::UniformValueMapframeUniformValues_

Uniform values specific to the current frame. More...

const helios::rendering::Viewport *viewport_

Non-owning pointer to the `Viewport` processed by this pass. More...

Protected Static Attributes Index

static const helios::util::log::Logger &logger_ = ...

Shared logger instance for all LegacyRenderPass objects. More...

Description

Encapsulates a single rendering pass with its associated resources.

A `LegacyRenderPass` holds a `RenderQueue` containing all `MeshRenderCommand` and `TextRenderCommand` objects to be processed. It also stores frame-level uniform values (e.g., view and projection matrices) that remain constant during the pass.

## Components

  • **RenderQueue:** Contains geometry and text render commands.
  • **Viewport:** Non-owning pointer to the rendering area and clear settings.
  • **UniformValueMap:** Frame-level uniforms applied to all commands.

## Ownership Model

  • **RenderQueue:** Owned by value (moved into the pass).
  • **UniformValueMap:** Owned by value (copied/moved into the pass).
  • **Viewport:** Non-owning raw pointer. The caller must ensure the viewport remains valid for the lifetime of this pass.

## Lifecycle

``` RenderingDevice::beginRenderPass(pass) → Clear buffers, configure viewport RenderingDevice::doRender(pass) → Process MeshRenderCommands and TextRenderCommands RenderingDevice::endRenderPass(pass) → Finalize pass, unbind resources ```

info

Future versions should support additional configuration like depth testing, stencil operations, and draw modes.

See Also

RenderQueue

See Also

RenderingDevice

See Also

Viewport

See Also

RenderPassFactory

Definition at line 63 of file LegacyRenderPass.ixx.

Public Constructors

LegacyRenderPass()

helios::rendering::LegacyRenderPass::LegacyRenderPass (const LegacyRenderPass &)
delete

Prevent copying. A LegacyRenderPass is not intended to be copied.

Definition at line 101 of file LegacyRenderPass.ixx.

Reference LegacyRenderPass.

Referenced by LegacyRenderPass, LegacyRenderPass, LegacyRenderPass, operator= and operator=.

LegacyRenderPass()

helios::rendering::LegacyRenderPass::LegacyRenderPass (LegacyRenderPass &&)
noexcept default

Allow move.

Definition at line 112 of file LegacyRenderPass.ixx.

Reference LegacyRenderPass.

LegacyRenderPass()

helios::rendering::LegacyRenderPass::LegacyRenderPass (const helios::rendering::Viewport * viewport, helios::rendering::RenderQueue renderQueue, const helios::rendering::shader::UniformValueMap & frameUniformValues)
inline explicit noexcept

Creates a new `LegacyRenderPass` with the specified viewport, render queue, and frame uniforms.

The render queue is moved into this pass. The viewport pointer must remain valid for the lifetime of this pass.

Parameters
viewport

Non-owning pointer to the viewport this LegacyRenderPass is processing.

renderQueue

The `RenderQueue` to be processed with this pass (moved).

frameUniformValues

Frame-specific uniform values (e.g., view/projection matrices).

Definition at line 129 of file LegacyRenderPass.ixx.

133 ) noexcept
134 :
135 viewport_(viewport),
136 renderQueue_(std::move(renderQueue)),
137 frameUniformValues_(frameUniformValues) {
138
139 assert(viewport_ != nullptr && "Unexpected nullptr for viewport in LegacyRenderPass constructor");
140 }

References frameUniformValues, LegacyRenderPass, renderQueue and viewport.

Public Destructor

~LegacyRenderPass()

helios::rendering::LegacyRenderPass::~LegacyRenderPass ()
default

Definition at line 95 of file LegacyRenderPass.ixx.

Public Operators

operator=()

LegacyRenderPass & helios::rendering::LegacyRenderPass::operator= (const LegacyRenderPass &)
delete

Prevent copy assignment. A LegacyRenderPass is not intended to be copied.

Definition at line 107 of file LegacyRenderPass.ixx.

Reference LegacyRenderPass.

operator=()

LegacyRenderPass & helios::rendering::LegacyRenderPass::operator= (LegacyRenderPass &&)
noexcept default

Allow move assignment.

Definition at line 117 of file LegacyRenderPass.ixx.

Reference LegacyRenderPass.

Public Member Functions

frameUniformValues()

const helios::rendering::shader::UniformValueMap & helios::rendering::LegacyRenderPass::frameUniformValues ()
inline nodiscard noexcept

Returns a const reference to this `LegacyRenderPass`' `UniformValueMap`.

The map might be empty.

Returns

A const reference to this `LegacyRenderPass`' `UniformValueMap` for the current frame.

Definition at line 176 of file LegacyRenderPass.ixx.

176 [[nodiscard]] const helios::rendering::shader::UniformValueMap& frameUniformValues() const noexcept {
177 return frameUniformValues_;
178 }

Referenced by LegacyRenderPass and setFrameUniformValues.

renderQueue()

const RenderQueue & helios::rendering::LegacyRenderPass::renderQueue ()
inline nodiscard noexcept

Returns a const ref to the `RenderQueue` this `LegacyRenderPass` holds.

Returns

A const ref to this `LegacyRenderPass`' `RenderQueue`.

Definition at line 147 of file LegacyRenderPass.ixx.

147 [[nodiscard]] const RenderQueue& renderQueue() const noexcept {
148 return renderQueue_;
149 }

Referenced by LegacyRenderPass.

setFrameUniformValues()

void helios::rendering::LegacyRenderPass::setFrameUniformValues (const helios::rendering::shader::UniformValueMap & frameUniformValues)
inline noexcept

Sets the frame-specific uniform values for this pass.

Parameters
frameUniformValues

The `UniformValueMap` containing frame-specific uniform values.

Definition at line 165 of file LegacyRenderPass.ixx.

Reference frameUniformValues.

viewport()

const Viewport & helios::rendering::LegacyRenderPass::viewport ()
inline nodiscard noexcept

Returns a const ref to the `Viewport` this `LegacyRenderPass` holds.

Returns

A const ref to this `LegacyRenderPass`' `Viewport`.

Definition at line 156 of file LegacyRenderPass.ixx.

156 [[nodiscard]] const Viewport& viewport() const noexcept {
157 return *viewport_;
158 }

Referenced by LegacyRenderPass.

Private Member Attributes

frameUniformValues_

helios::rendering::shader::UniformValueMap helios::rendering::LegacyRenderPass::frameUniformValues_

Uniform values specific to the current frame.

This map contains uniforms that change once per frame, such as the view and the projection matrices.

Definition at line 77 of file LegacyRenderPass.ixx.

renderQueue_

helios::rendering::RenderQueue helios::rendering::LegacyRenderPass::renderQueue_

The `RenderQueue` for this pass, containing all render commands.

Definition at line 69 of file LegacyRenderPass.ixx.

viewport_

const helios::rendering::Viewport* helios::rendering::LegacyRenderPass::viewport_

Non-owning pointer to the `Viewport` processed by this pass.

The caller must ensure the viewport remains valid for the lifetime of this pass.

Definition at line 84 of file LegacyRenderPass.ixx.

84 const helios::rendering::Viewport* viewport_;

Protected Static Attributes

logger_

const helios::util::log::Logger& helios::rendering::LegacyRenderPass::logger_
protected static

Shared logger instance for all LegacyRenderPass objects.

Initialiser

Definition at line 90 of file LegacyRenderPass.ixx.


The documentation for this class was generated from the following file:


Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.15.0.