VR-Engage  2.2
Loading...
Searching...
No Matches
hudUpdater.h
Go to the documentation of this file.
1/******************************************************************************
2** Copyright (c) 2025 MAK Technologies
3** All rights reserved.
4******************************************************************************/
5
6//! \file hudUpdater.h
7//! \brief Defines the HUD updater component for the spectator role
8//! \ingroup vreSpectatorFrontend
9
10#pragma once
11
13
15
16namespace makVre
17{
18//! \brief Type identifier for DtSpectatorHudUpdater component
19constexpr const char* DtSpectatorHudUpdaterType = "DtSpectatorHudUpdater";
20
21//! \brief Head-up display updater component for the spectator role
22//!
23//! This component manages the spectator's heads-up display (HUD),
24//! providing real-time information overlay and visual feedback.
25//! It updates HUD elements based on simulation state and spectator
26//! interactions, displaying relevant information such as objectives,
27//! location data, and event notifications.
29{
30public:
31 //! \brief Default constructor
33
34 //! \brief Virtual destructor
35 virtual ~DtSpectatorHudUpdater() override;
36
37 //! \brief Initializes the HUD updater component
38 //! \param player Pointer to the player station
39 //! \param config Reference to the initialization configuration
40 //! \return True if initialization was successful, false otherwise
41 //!
42 //! Sets up HUD elements and registers message handlers for HUD events
44
45 //! \brief Updates HUD state each frame
46 //! \param dt Delta time since the last update in seconds
47 //!
48 //! Updates HUD elements based on current simulation state
49 virtual void tick(double dt) override;
50
51 //! \brief Returns the component type identifier
52 //! \return The component type string
53 virtual const char* type() const override;
54
55 //! \brief Performs cleanup when the component is shut down
56 //!
57 //! Releases HUD resources and unregisters message handlers
58 virtual void shutdown() override;
59
60protected:
61};
62} // namespace makVre
Table-based access to Lua state for configuration data.
Definition initializer.h:38
Base class for all role components in VR-Engage.
Definition playerComponent.h:78
virtual DtPlayerStation & player()
Gets the player station.
Class for managing the user interface for engaged roles.
Definition playerStation.h:51
virtual ~DtSpectatorHudUpdater() override
Virtual destructor.
virtual void shutdown() override
Performs cleanup when the component is shut down.
virtual void tick(double dt) override
Updates HUD state each frame.
virtual bool initialize(makVre::DtPlayerStation *player, makVre::DtInitTable &config) override
Initializes the HUD updater component.
DtSpectatorHudUpdater()
Default constructor.
virtual const char * type() const override
Returns the component type identifier.
Defines export macros for the Spectator Frontend library.
#define SPECTATOR_DLL
Export/import macro for non-Windows platforms (empty)
Definition export.h:25
Include export definitions for this library.
Definition glsVreMessageUtil.h:49
constexpr const char * DtSpectatorHudUpdaterType
Type identifier for DtSpectatorHudUpdater component.
Definition hudUpdater.h:19
Defines the DtPlayerComponent base class for VR-Engage role components.