VR-Engage  2.2
Loading...
Searching...
No Matches
radarWarningReceiverDescriptor.h
Go to the documentation of this file.
1/*******************************************************************************
2** Copyright (c) 2025 MAK Technologies
3** All rights reserved.
4*******************************************************************************/
5
6//! \file radarWarningReceiverDescriptor.h
7//! \ingroup vreVrfobjparam
8//! \brief Radar Warning Receiver (RWR) descriptor for VREngage
9//!
10//! This file defines the DtRadarWarningReceiverDescriptor class, which configures
11//! Radar Warning Receiver components in VREngage. RWR systems detect and classify radar
12//! emissions, providing essential threat detection for military aircraft and vehicles.
13
14#pragma once
15
17#include <vrfobjparam/componentDescriptor.h>
18#include <readerWriter/rwReal.h>
19
20namespace makVre
21{
22//! \brief Type identifier string for the Radar Warning Receiver descriptor
23const char DtRadarWarningReceiverDescriptorType[] = "vre-radar-warning-receiver-descriptor";
24
25//! \brief Radar Warning Receiver (RWR) descriptor for VREngage
26//!
27//! This class defines a descriptor for the Radar Warning Receiver component,
28//! which allows entities to detect radar emissions from other entities in the
29//! simulation. It provides configuration for detection periods, ranges, and other
30//! parameters that control how radar emissions are detected and classified.
31class VREVRFOBJPARAM_DLL DtRadarWarningReceiverDescriptor : public DtComponentDescriptor
32{
33private:
34 //! \brief Default constructor (not implemented)
35 //!
36 //! Default constructor is private and not implemented to prevent
37 //! creation of instances without proper initialization.
39
40public:
41 //! \brief Constructor with component name
42 //! \param name The name of this component
43 //! \param parentRegistry Parent registry for reader/writer functionality (optional)
44 //!
45 //! Creates a new Radar Warning Receiver descriptor with the specified name.
46 DtRadarWarningReceiverDescriptor(const DtString& name, DtReaderWriterRegistry* parentRegistry = 0);
47
48 //! \brief Copy constructor
49 //! \param orig The source descriptor to copy from
50 //! \param parentRegistry Parent registry for reader/writer functionality (optional)
51 //!
52 //! Creates a new Radar Warning Receiver descriptor as a copy of the provided original.
54 const DtRadarWarningReceiverDescriptor& orig, DtReaderWriterRegistry* parentRegistry = 0);
55
56 //! \brief Assignment operator
57 //! \param orig The source descriptor to copy from
58 //! \return Reference to this descriptor after assignment
59 //!
60 //! Assigns the contents of the provided descriptor to this one.
62
63 //! \brief Virtual destructor
64 //!
65 //! Cleans up resources used by the descriptor.
67
68 //! \brief Gets the type identifier for this descriptor
69 //! \return String identifying this descriptor type
70 //!
71 //! Returns a unique type identifier string for this descriptor type.
72 //! Will return DtRadarWarningReceiverDescriptorType.
73 virtual DtString type() const override;
74
75 //! \brief Gets the detection period
76 //! \return The detection period in seconds
77 //!
78 //! Returns the time between checks for new radar emitters.
79 virtual DtReal detectionPeriod() const;
80
81 //! \brief Sets the detection period
82 //! \param detectionPeriod The detection period in seconds
83 //!
84 //! Sets the time between checks for new radar emitters.
85 virtual void setDetectionPeriod(DtReal detectionPeriod);
86
87 //! \brief Gets the detection period variance
88 //! \return The detection period variance in seconds
89 //!
90 //! Returns the magnitude of random variance added to the detection period.
91 virtual DtReal detectionPeriodVariance() const;
92
93 //! \brief Sets the detection period variance
94 //! \param detectionPeriodVariance The detection period variance in seconds
95 //!
96 //! Sets the magnitude of random variance added to the detection period.
98
99 //! \brief Sets the emitter detection range
100 //! \param range The maximum detection range in meters
101 //!
102 //! Sets the maximum range at which radar emitters can be detected.
103 virtual void setEmitterDetectionRange(double range);
104
105 //! \brief Gets the emitter detection range
106 //! \return The maximum detection range in meters
107 //!
108 //! Returns the maximum range at which radar emitters can be detected.
109 virtual double emitterDetectionRange() const;
110
111 //! \brief Creates a clone of this descriptor
112 //! \param parentRegistry Parent registry for reader/writer functionality (optional)
113 //! \return Pointer to a new descriptor that is a clone of this one
114 //!
115 //! Creates a new Radar Warning Receiver descriptor as a deep copy of this one.
116 virtual DtComponentDescriptor* clone(DtReaderWriterRegistry* parentRegistry = 0) const override;
117
118 //! \brief Factory function to create a new instance of this descriptor
119 //! \return Pointer to a newly created descriptor
120 //!
121 //! Static factory function used by the descriptor creation system to instantiate
122 //! new instances of this descriptor type.
123 static DtComponentDescriptor* creator();
124
125 //! \brief Gets configuration data for this descriptor from script arguments
126 //! \param args Script arguments to process
127 //! \param searchPaths Search paths for resolving file references
128 //! \param variableBindings Variable bindings for resolving script variables
129 //!
130 //! Processes script arguments to configure this descriptor instance.
131 virtual void getSelf(DtlObjPtr args,
132 const DtReaderWriter::SearchPaths& searchPaths,
133 const DtVariableBindingsList& variableBindings) override;
134
135protected:
136 //! \name Configuration Parameters
137 //! These parameters are available for setting in the OPD files.
138 //@{
139 //! \brief Time between radar emission detection checks
140 //!
141 //! The time interval between consecutive checks for new radar emitters or the
142 //! removal of previously detected emitters. If an emitter has a 1 in 10 chance
143 //! of being detected in each detection period, and the detection period is 1 second,
144 //! then the emitter can be expected to be detected within 10 seconds on average.
145 //!
146 //! Default value: 1.0
147 //! Units: seconds
149
150 //! \brief Random variance for detection period timing
151 //!
152 //! Magnitude of random variance added to the detection period to spread
153 //! checks out over different simulation ticks. This helps prevent synchronized
154 //! detection patterns and creates more realistic detection behavior.
155 //!
156 //! Default value: 0.0
157 //! Units: seconds
159
160 //! \brief Maximum detection range for radar emitters
161 //!
162 //! The maximum distance at which this Radar Warning Receiver can detect
163 //! radar emissions from other entities. Emissions beyond this range will
164 //! not be detected regardless of their power or characteristics.
165 //!
166 //! Default value: 5000.0
167 //! Units: meters
169
170 //@}
171};
172} // namespace makVre
virtual void getSelf(DtlObjPtr args, const DtReaderWriter::SearchPaths &searchPaths, const DtVariableBindingsList &variableBindings) override
Gets configuration data for this descriptor from script arguments.
virtual ~DtRadarWarningReceiverDescriptor() override
Virtual destructor.
virtual void setDetectionPeriod(DtReal detectionPeriod)
Sets the detection period.
virtual void setDetectionPeriodVariance(DtReal detectionPeriodVariance)
Sets the detection period variance.
DtRadarWarningReceiverDescriptor(const DtString &name, DtReaderWriterRegistry *parentRegistry=0)
Constructor with component name.
DtRadarWarningReceiverDescriptor & operator=(const DtRadarWarningReceiverDescriptor &orig)
Assignment operator.
virtual double emitterDetectionRange() const
Gets the emitter detection range.
DtRwReal myEmitterDetectionRange
Maximum detection range for radar emitters.
Definition radarWarningReceiverDescriptor.h:168
virtual DtString type() const override
Gets the type identifier for this descriptor.
DtRadarWarningReceiverDescriptor()
Default constructor (not implemented)
virtual DtComponentDescriptor * clone(DtReaderWriterRegistry *parentRegistry=0) const override
Creates a clone of this descriptor.
virtual DtReal detectionPeriod() const
Gets the detection period.
DtRwReal myDetectionPeriod
Time between radar emission detection checks.
Definition radarWarningReceiverDescriptor.h:148
virtual void setEmitterDetectionRange(double range)
Sets the emitter detection range.
DtRwReal myDetectionPeriodVariance
Random variance for detection period timing.
Definition radarWarningReceiverDescriptor.h:158
DtRadarWarningReceiverDescriptor(const DtRadarWarningReceiverDescriptor &orig, DtReaderWriterRegistry *parentRegistry=0)
Copy constructor.
static DtComponentDescriptor * creator()
Factory function to create a new instance of this descriptor.
virtual DtReal detectionPeriodVariance() const
Gets the detection period variance.
Export macros for the VREngage Object Parameter library.
#define VREVRFOBJPARAM_DLL
Platform-specific DLL export/import declaration.
Definition export.h:27
Include export definitions for this library.
Definition glsVreMessageUtil.h:49
const char DtRadarWarningReceiverDescriptorType[]
Type identifier string for the Radar Warning Receiver descriptor.
Definition radarWarningReceiverDescriptor.h:23