VR-Engage  2.2
Loading...
Searching...
No Matches
entityRoleDescriptorStructs.h
Go to the documentation of this file.
1/*******************************************************************************
2** Copyright (c) 2025 MAK Technologies
3** All rights reserved.
4*******************************************************************************/
5
6//! \file entityRoleDescriptorStructs.h
7//! \ingroup vreUtil
8//! \brief Defines data structures for entity role configurations
9//!
10//! This file contains the data structures used to describe entity roles,
11//! display configurations, and parameter mappings in the VREngage system.
12//! These structures support the management of role-based entity capabilities.
13
14#pragma once
15
16#include "vreUtil/export.h"
17#include "vreUtil/initializer.h"
18
19#include <string>
20
21namespace makVre
22{
23//! \brief Descriptor for a display configuration
24//!
25//! Contains information about a display configuration, including its file path
26//! and parameter overrides that modify the configuration for specific entities.
28{
29 //! \brief Location of the display configuration file
30 std::string path;
31
32 //! \brief Map of parameter override names to values
33 //!
34 //! The key is the name of a Lua table member in the display configuration, e.g.,
35 //! "savedViewUpdater.savedViews", and the value is the Lua code fragment
36 //! to replace in the given display configuration, e.g., "boxerApcViews.osrx".
37 std::map<std::string, std::string> parameters;
38};
39
40//! \brief Descriptor for an entity role
41//!
42//! Contains comprehensive information about an entity role, including its
43//! visibility settings, configuration path, parameters, and associated
44//! display configurations.
46{
47 //! \brief Flag indicating if this role should be hidden in the GUI
48 //!
49 //! When true, the role will not be listed explicitly in the Choose Role panel
51
52 //! \brief Name of the role as it appears in the Choose Role panel
53 std::string slotName;
54
55 //! \brief Location of the role configuration file
56 std::string path;
57
58 //! \brief Map of parameter override names to values
59 //!
60 //! Used for overriding portions of the role configuration file with data
61 //! specific to a given entity
62 std::map<std::string, std::string> parameters;
63
64 //! \brief Default display layout to use if none is specified
65 //!
66 //! Example: "1 Screen Horizontal"
68
69 //! \brief Map of display configuration names to their descriptors
70 std::map<std::string, DtDisplayConfigDescriptor> displayConfigDescriptors;
71};
72
73//! \brief Map of parameter names to values for entity configuration
74//!
75//! Used to store parameter overrides for entities
76using DtEntityParameterMap = std::map<std::string, std::string>;
77
78//! \brief Map of role names to role descriptor objects
79//!
80//! Used to store all roles associated with an entity
81using DtEntityRoleMap = std::map<std::string, std::shared_ptr<DtEntityRoleDescriptor>>;
82} // namespace makVre
Defines export macros for the VREngage Utility library.
#define UTIL_DLL
Export/import macro for non-Windows platforms.
Definition export.h:39
Provides configuration initialization for VREngage components.
Include export definitions for this library.
Definition glsVreMessageUtil.h:49
std::map< std::string, std::shared_ptr< DtEntityRoleDescriptor > > DtEntityRoleMap
Map of role names to role descriptor objects.
Definition entityRoleDescriptorStructs.h:81
std::map< std::string, std::string > DtEntityParameterMap
Map of parameter names to values for entity configuration.
Definition entityRoleDescriptorStructs.h:76
Descriptor for a display configuration.
Definition entityRoleDescriptorStructs.h:28
std::string path
Location of the display configuration file.
Definition entityRoleDescriptorStructs.h:30
std::map< std::string, std::string > parameters
Map of parameter override names to values.
Definition entityRoleDescriptorStructs.h:37
Descriptor for an entity role.
Definition entityRoleDescriptorStructs.h:46
std::string defaultDisplayLayout
Default display layout to use if none is specified.
Definition entityRoleDescriptorStructs.h:67
std::string path
Location of the role configuration file.
Definition entityRoleDescriptorStructs.h:56
std::map< std::string, DtDisplayConfigDescriptor > displayConfigDescriptors
Map of display configuration names to their descriptors.
Definition entityRoleDescriptorStructs.h:70
std::string slotName
Name of the role as it appears in the Choose Role panel.
Definition entityRoleDescriptorStructs.h:53
std::map< std::string, std::string > parameters
Map of parameter override names to values.
Definition entityRoleDescriptorStructs.h:62
bool unlisted
Flag indicating if this role should be hidden in the GUI.
Definition entityRoleDescriptorStructs.h:50