open-dis-cpp
DirectedEnergyPrecisionAimpoint.h
1 #pragma once
2 
3 #include <dis7/Vector3Double.h>
4 #include <dis7/Vector3Float.h>
5 #include <dis7/Vector3Float.h>
6 #include <dis7/Vector3Float.h>
7 #include <dis7/EntityID.h>
8 #include <dis7/utils/DataStream.h>
9 #include <dis7/opendis7_export.h>
10 
11 
12 namespace DIS
13 {
14 // DE Precision Aimpoint Record. Section 6.2.21.3
15 
16 // Copyright (c) 2007-2009, MOVES Institute, Naval Postgraduate School. All rights reserved.
17 //
18 // @author DMcG, jkg
19 
20 class OPENDIS7_EXPORT DirectedEnergyPrecisionAimpoint
21 {
22 protected:
24  unsigned int _recordType;
25 
27  unsigned short _recordLength;
28 
30  unsigned short _padding;
31 
34 
37 
40 
43 
46 
48  unsigned char _targetComponentID;
49 
51  unsigned char _SpotShape;
52 
55 
58 
61 
62 
63  public:
66 
67  virtual void marshal(DataStream& dataStream) const;
68  virtual void unmarshal(DataStream& dataStream);
69 
70  unsigned int getRecordType() const;
71  void setRecordType(unsigned int pX);
72 
73  unsigned short getRecordLength() const;
74  void setRecordLength(unsigned short pX);
75 
76  unsigned short getPadding() const;
77  void setPadding(unsigned short pX);
78 
79  Vector3Double& getTargetSpotLocation();
80  const Vector3Double& getTargetSpotLocation() const;
81  void setTargetSpotLocation(const Vector3Double &pX);
82 
83  Vector3Float& getTargetSpotEntityLocation();
84  const Vector3Float& getTargetSpotEntityLocation() const;
85  void setTargetSpotEntityLocation(const Vector3Float &pX);
86 
87  Vector3Float& getTargetSpotVelocity();
88  const Vector3Float& getTargetSpotVelocity() const;
89  void setTargetSpotVelocity(const Vector3Float &pX);
90 
91  Vector3Float& getTargetSpotAcceleration();
92  const Vector3Float& getTargetSpotAcceleration() const;
93  void setTargetSpotAcceleration(const Vector3Float &pX);
94 
95  EntityID& getTargetEntityID();
96  const EntityID& getTargetEntityID() const;
97  void setTargetEntityID(const EntityID &pX);
98 
99  unsigned char getTargetComponentID() const;
100  void setTargetComponentID(unsigned char pX);
101 
102  unsigned char getSpotShape() const;
103  void setSpotShape(unsigned char pX);
104 
105  float getBeamSpotXSecSemiMajorAxis() const;
106  void setBeamSpotXSecSemiMajorAxis(float pX);
107 
108  float getBeamSpotCrossSectionSemiMinorAxis() const;
109  void setBeamSpotCrossSectionSemiMinorAxis(float pX);
110 
111  float getBeamSpotCrossSectionOrientAngle() const;
112  void setBeamSpotCrossSectionOrientAngle(float pX);
113 
114 
115 virtual int getMarshalledSize() const;
116 
117  bool operator ==(const DirectedEnergyPrecisionAimpoint& rhs) const;
118 };
119 }
120 
121 // Copyright (c) 1995-2009 held by the author(s). All rights reserved.
122 // Redistribution and use in source and binary forms, with or without
123 // modification, are permitted provided that the following conditions
124 // are met:
125 //
126 // * Redistributions of source code must retain the above copyright
127 // notice, this list of conditions and the following disclaimer.
128 // * Redistributions in binary form must reproduce the above copyright
129 // notice, this list of conditions and the following disclaimer
130 // in the documentation and/or other materials provided with the
131 // distribution.
132 // * Neither the names of the Naval Postgraduate School (NPS)
133 // Modeling Virtual Environments and Simulation (MOVES) Institute
134 // (http://www.nps.edu and http://www.MovesInstitute.org)
135 // nor the names of its contributors may be used to endorse or
136 // promote products derived from this software without specific
137 // prior written permission.
138 //
139 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
140 // AS IS AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
141 // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
142 // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
143 // COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
144 // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
145 // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
146 // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
147 // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
148 // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
149 // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
150 // POSSIBILITY OF SUCH DAMAGE.
float _BeamSpotCrossSectionSemiMinorAxis
Beam Spot Cross Section Semi-Major Axis.
Definition: DirectedEnergyPrecisionAimpoint.h:57
Symbolic names as defined in 5.1.4.
Definition: AcknowledgePdu.h:8
unsigned short _recordLength
Length of Record.
Definition: DirectedEnergyPrecisionAimpoint.h:27
unsigned int _recordType
Type of Record.
Definition: DirectedEnergyPrecisionAimpoint.h:24
a class to support managing a network buffer.
Definition: DataStream.h:28
Definition: DirectedEnergyPrecisionAimpoint.h:20
unsigned char _targetComponentID
Target Component ID ENUM, same as in DamageDescriptionRecord.
Definition: DirectedEnergyPrecisionAimpoint.h:48
float _BeamSpotXSecSemiMajorAxis
Beam Spot Cross Section Semi-Major Axis.
Definition: DirectedEnergyPrecisionAimpoint.h:54
Vector3Float _targetSpotAcceleration
Acceleration (meters/sec/sec) of Target Spot.
Definition: DirectedEnergyPrecisionAimpoint.h:42
Vector3Float _targetSpotVelocity
Velocity (meters/sec) of Target Spot.
Definition: DirectedEnergyPrecisionAimpoint.h:39
Definition: Vector3Float.h:15
Definition: EntityID.h:15
Definition: Vector3Double.h:15
unsigned short _padding
Padding.
Definition: DirectedEnergyPrecisionAimpoint.h:30
Vector3Float _targetSpotEntityLocation
Position (meters) of Target Spot relative to Entity Position.
Definition: DirectedEnergyPrecisionAimpoint.h:36
Vector3Double _targetSpotLocation
Position of Target Spot in World Coordinates.
Definition: DirectedEnergyPrecisionAimpoint.h:33
unsigned char _SpotShape
Spot Shape ENUM.
Definition: DirectedEnergyPrecisionAimpoint.h:51
EntityID _targetEntityID
Unique ID of the target entity.
Definition: DirectedEnergyPrecisionAimpoint.h:45
float _BeamSpotCrossSectionOrientAngle
Beam Spot Cross Section Orientation Angle.
Definition: DirectedEnergyPrecisionAimpoint.h:60