Skip to main content

ActiveViewportIdsStateComponent Class

Stores the currently active viewport IDs based on game/match state. More...

Declaration

class helios::engine::modules::rendering::viewport::components::ActiveViewportIdsStateComponent { ... }

Public Member Functions Index

voidsetViewportIds (std::span< const ViewportId > &viewportIds)

Replaces the current viewport IDs with the provided list. More...

std::span< const ViewportId >viewportIds () const noexcept

Returns a span over all active viewport IDs. More...

voidclear () const noexcept

Clears all active viewport IDs. More...

Private Member Attributes Index

std::vector< ViewportId >viewportIds_

Currently active viewport identifiers. More...

Description

Stores the currently active viewport IDs based on game/match state.

This component maintains a list of ViewportIds that should be rendered for the current game and match state combination. It is updated by StateToViewportPolicyUpdateSystem each frame based on the configured StateToViewportPolicy.

Definition at line 32 of file ActiveViewportIdsStateComponent.ixx.

Public Member Functions

clear()

void helios::engine::modules::rendering::viewport::components::ActiveViewportIdsStateComponent::clear ()
inline noexcept

Clears all active viewport IDs.

Definition at line 63 of file ActiveViewportIdsStateComponent.ixx.

63 void clear() const noexcept {
64 viewportIds_.clear();
65 }

setViewportIds()

void helios::engine::modules::rendering::viewport::components::ActiveViewportIdsStateComponent::setViewportIds (std::span< const ViewportId > & viewportIds)
inline

Replaces the current viewport IDs with the provided list.

Parameters
viewportIds

The new list of active viewport IDs.

Definition at line 47 of file ActiveViewportIdsStateComponent.ixx.

47 void setViewportIds(std::span<const ViewportId>& viewportIds) {
48 viewportIds_.assign(viewportIds.begin(), viewportIds.end());
49 }

Reference viewportIds.

viewportIds()

std::span< const ViewportId > helios::engine::modules::rendering::viewport::components::ActiveViewportIdsStateComponent::viewportIds ()
inline nodiscard noexcept

Returns a span over all active viewport IDs.

Returns

Read-only span of viewport identifiers.

Definition at line 56 of file ActiveViewportIdsStateComponent.ixx.

56 [[nodiscard]] std::span<const ViewportId> viewportIds() const noexcept {
57 return viewportIds_;
58 }

Referenced by setViewportIds.

Private Member Attributes

viewportIds_

std::vector<ViewportId> helios::engine::modules::rendering::viewport::components::ActiveViewportIdsStateComponent::viewportIds_
mutable

Currently active viewport identifiers.

Definition at line 37 of file ActiveViewportIdsStateComponent.ixx.

37 mutable std::vector<ViewportId> viewportIds_;

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


Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.15.0.