VR-Engage  2.2
Loading...
Searching...
No Matches
hudContactUpdate.h
Go to the documentation of this file.
1/*********************************************************************************
2** Copyright (c) 2025 MAK Technologies, Inc.
3** All rights reserved.
4*********************************************************************************/
5
6/*!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
7!!!!!!!!!This is an auto-generated file. Any changes will be destroyed!!!!!!!!!!!
8!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
9Generated from: /data/exports/DEV-CAM-BML-043/nightly/3085/libsrc/framework/vreMessages/radarScope.lua
10*/
11/*-----------------COMMENT----------------------
12Sends required information for detected contacts in screen coordinates for displaying on a HUD.
13-------------------COMMENT----------------------*/
14#pragma once
15
18#include <vreMessages/export.h>
19#include <vlpi/entityIdentifier.h>
20#include <vector>
21
22
23namespace makVre
24{
25
26
27constexpr const char* HudContactUpdateMessageType = "radarState.hudContactUpdate";
28
30{
31public:
32
34 {
36
37 int size() const;
38 void serialize(DtStreamWriter& writer) const;
40 bool operator==(const SensorContact& rhs) const;
41
43 double myScreenX;
44 double myScreenY;
47 DtVector myPosition;
48 DtVector32 myVelocity;
49
50 };
51
52
53 // Struct for defining data
55 {
57
58 DtEntityIdentifier myHostId;
59 std::vector<SensorContact> myContacts;
60
61 bool operator==(const HudContactUpdateData& rhs) const;
62 };
63
64 // Default static creators to promote the usage of not using new.
68
69 //! \brief static message identity functions
70 static const std::string& theType();
73
74 //! \brief Get the name of the message type
75 virtual const std::string& type() const override;
76 virtual const makVre::DtVreMessageId& messageId() const override;
77
78 // default destructor
79 virtual ~HudContactUpdateMessage() override;
80
81 virtual const DtEntityIdentifier& getHostId() const;
82 virtual void setHostId(const DtEntityIdentifier& val);
83
84 virtual const std::vector<SensorContact>& getContacts() const;
85 virtual void setContacts(const std::vector<SensorContact>& val);
86
87
88 // Accessors
89 virtual int messageSize() const override;
90 static makVre::DtVreMessage* decode(char* buffer, int length);
93
94 // Operators
95 bool operator==(const HudContactUpdateMessage& rhs) const;
96
97protected:
98 // Inaccessible default constructor to promote the usage of the static creator functions
100
101 virtual void serialize(DtStreamWriter& writer) const override;
102 virtual void deserialize(DtStreamReader& reader) override;
103
104protected:
107
108 // Store the data for future use
110};
111
112} // ::makVre
113
114
115
Reader class for decoding values from a byte array.
Definition byteStream.h:42
Writer class for encoding values into a byte array.
Definition byteStream.h:161
Abstract base class for all VREngage messages.
Definition vreMessage.h:50
Message identifier class for the VREngage messaging system.
Definition vreMessageId.h:35
virtual const std::string & type() const override
Get the name of the message type.
HudContactUpdateData getData()
virtual ~HudContactUpdateMessage() override
virtual void deserialize(DtStreamReader &reader) override
Deserializes the message from a stream reader.
static const std::string & theType()
static message identity functions
static makVre::DtVreMessage * decode(char *buffer, int length)
static makVre::DtVreMessageId theMessageId
Definition hudContactUpdate.h:105
static const makVre::DtVreMessageId & theId()
static UInt64 theVersion
Definition hudContactUpdate.h:106
virtual const DtEntityIdentifier & getHostId() const
virtual void setContacts(const std::vector< SensorContact > &val)
virtual int messageSize() const override
Static decode function pattern for derived classes.
static HudContactUpdateMessage * create()
static HudContactUpdateMessage * createFromData(const HudContactUpdateData)
HudContactUpdateData myData
Definition hudContactUpdate.h:109
virtual const makVre::DtVreMessageId & messageId() const override
Gets the message ID object.
HudContactUpdateData getData() const
bool operator==(const HudContactUpdateMessage &rhs) const
virtual void serialize(DtStreamWriter &writer) const override
Serializes the message to a stream writer.
virtual void setHostId(const DtEntityIdentifier &val)
virtual const std::vector< SensorContact > & getContacts() const
static HudContactUpdateMessage * createFrom(HudContactUpdateMessage *)
Defines export macros for the VREngage Messages library.
#define VREMESSAGES_DLL
Export/import macro for non-Windows platforms.
Definition export.h:39
Include export definitions for this library.
Definition glsVreMessageUtil.h:49
unsigned long long UInt64
Unsigned 64-bit integer type.
Definition utilFunctions.h:42
constexpr const char * HudContactUpdateMessageType
Definition hudContactUpdate.h:27
bool operator==(const HudContactUpdateData &rhs) const
std::vector< SensorContact > myContacts
Definition hudContactUpdate.h:59
DtEntityIdentifier myHostId
Definition hudContactUpdate.h:58
DtVector32 myVelocity
Definition hudContactUpdate.h:48
void serialize(DtStreamWriter &writer) const
double myScreenX
Definition hudContactUpdate.h:43
double myScreenY
Definition hudContactUpdate.h:44
void deserialize(DtStreamReader &reader)
bool myIsNextToShoot
Definition hudContactUpdate.h:46
bool myIsDesignated
Definition hudContactUpdate.h:45
bool operator==(const SensorContact &rhs) const
int myTrackId
Definition hudContactUpdate.h:42
DtVector myPosition
Definition hudContactUpdate.h:47
Defines the base class for all VREngage messages.
Defines message identifier class for the VREngage messaging system.