VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtIntervisibilitySettingsRecord.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * Copyright (c) 2022 MAK Technologies, Inc.
3  * All rights reserved.
4  *****************************************************************************/
5 
9 
10 #pragma once
11 
13 
14 namespace makArchives
15 {
16 
20  {
21  public:
22 
25 
28 
31 
34 
36  bool operator == ( const DtIntervisibilitySettingsRecord& rhs ) const;
37 
39  inline bool operator != ( const DtIntervisibilitySettingsRecord& rhs ) const
40  {
41  return !( *this == rhs );
42  }
43 
46 
48  void setIntervisibilityEnabled( bool enabled );
50  bool intervisibilityEnabled() const;
51 
53  void setLeftClickMakesObjectsPermanent( bool enabled );
55  bool leftClickMakesObjectsPermanent() const;
56 
58  void setOriginIntervisibilityElevation( double height );
60  double originIntervisibilityElevation() const;
61 
63  void setEndPointIntervisibilityElevation( double height );
65  double endPointIntervisibilityElevation() const;
66 
68  void setFanModeSamplingRate( double radAngle );
70  double fanModeSamplingRate() const;
71 
74  void setEntityFanUpdateRate( double interval );
77  double entityFanUpdateRate() const;
78 
80  void setHatLinesEnabled( bool hatEnabled );
82  bool hatLinesEnabled() const;
83 
85  void setHatLinesOnSelectionOnly( bool selOnly );
87  bool hatLinesOnSelectionOnly() const;
88 
90  void setVisibleColor( float r, float g, float b, float a );
92  void visibleColor( float& r, float& g, float& b, float& a ) const;
93 
95  void setBlockedColor( float r, float g, float b, float a );
97  void blockedColor( float& r, float& g, float& b, float& a ) const;
98 
100  void setCircleColor( float r, float g, float b, float a );
102  void circleColor( float& r, float& g, float& b, float& a ) const;
103 
105 
106  protected:
107 
108  friend class boost::serialization::access;
109 
113  template<class Archive>
114  void serialize(Archive & ar, const unsigned int version)
115  {
116  ar & BOOST_SERIALIZATION_NVP(myLeftClickMakesObjectsPermanent);
117  ar & BOOST_SERIALIZATION_NVP(myOriginIntervisibilityElevation);
118  ar & BOOST_SERIALIZATION_NVP(myEndPointIntervisibilityElevation);
119  ar & BOOST_SERIALIZATION_NVP(myFanModeSamplingRate);
120  ar & BOOST_SERIALIZATION_NVP(myEntityFanUpdateRate);
121  ar & BOOST_SERIALIZATION_NVP(myHatLinesEnabled);
122  ar & BOOST_SERIALIZATION_NVP(myHatLinesOnSelectionOnly);
123 
124  ar & BOOST_SERIALIZATION_NVP(myVisibleColorR);
125  ar & BOOST_SERIALIZATION_NVP(myVisibleColorG);
126  ar & BOOST_SERIALIZATION_NVP(myVisibleColorB);
127  ar & BOOST_SERIALIZATION_NVP(myVisibleColorA);
128 
129  ar & BOOST_SERIALIZATION_NVP(myBlockedColorR);
130  ar & BOOST_SERIALIZATION_NVP(myBlockedColorG);
131  ar & BOOST_SERIALIZATION_NVP(myBlockedColorB);
132  ar & BOOST_SERIALIZATION_NVP(myBlockedColorA);
133 
134  ar & BOOST_SERIALIZATION_NVP(myCircleColorR);
135  ar & BOOST_SERIALIZATION_NVP(myCircleColorG);
136  ar & BOOST_SERIALIZATION_NVP(myCircleColorB);
137  ar & BOOST_SERIALIZATION_NVP(myCircleColorA);
138 
139  if ( version >= 2 )
140  {
141  ar & BOOST_SERIALIZATION_NVP( myIntervisibilityEnabled );
142  }
143 
144  if ( version == 3 )
145  {
146  ar & BOOST_SERIALIZATION_NVP( myRangeInfoLabelsEnabled );
147  ar & BOOST_SERIALIZATION_NVP( myRangeInfoLabelBackgroundColorR );
148  ar & BOOST_SERIALIZATION_NVP( myRangeInfoLabelBackgroundColorG );
149  ar & BOOST_SERIALIZATION_NVP( myRangeInfoLabelBackgroundColorB );
150  ar & BOOST_SERIALIZATION_NVP( myRangeInfoLabelBackgroundColorA );
151  ar & BOOST_SERIALIZATION_NVP( myRangeInfoAltChangeFieldEnabledFlag );
152  ar & BOOST_SERIALIZATION_NVP( myRangeInfoLocationFieldEnabledFlag );
153  ar & BOOST_SERIALIZATION_NVP( myRangeInfoHeadingFieldEnabledFlag );
154  ar & BOOST_SERIALIZATION_NVP( myRangeInfoRangeFieldEnabledFlag );
155  }
156  }
157 
158  protected:
159 
162 
165 
170 
171  float myVisibleColorR, myVisibleColorG, myVisibleColorB, myVisibleColorA;
172  float myBlockedColorR, myBlockedColorG, myBlockedColorB, myBlockedColorA;
173  float myCircleColorR, myCircleColorG, myCircleColorB, myCircleColorA;
174 
177  bool myRangeInfoLabelsEnabled, myRangeInfoAltChangeFieldEnabledFlag, myRangeInfoLocationFieldEnabledFlag,
178  myRangeInfoHeadingFieldEnabledFlag, myRangeInfoRangeFieldEnabledFlag;
179  float myRangeInfoLabelBackgroundColorR, myRangeInfoLabelBackgroundColorG,
180  myRangeInfoLabelBackgroundColorB, myRangeInfoLabelBackgroundColorA;
182 
183  };
184 
185 }
186 
bool myHatLinesEnabled
Definition: DtIntervisibilitySettingsRecord.h:163
BOOST_CLASS_VERSION(makArchives::DtDiGuySettingsRecord, 3)
double myOriginIntervisibilityElevation
Definition: DtIntervisibilitySettingsRecord.h:166
float myRangeInfoLabelBackgroundColorR
Deprecated as of Version 4.
Definition: DtIntervisibilitySettingsRecord.h:179
double myFanModeSamplingRate
Definition: DtIntervisibilitySettingsRecord.h:168
void serialize(Archive &ar, const unsigned int version)
When the class Archive corresponds to an output archive, the &amp; operator is defined similar to &lt;&lt;...
Definition: DtIntervisibilitySettingsRecord.h:114
float myVisibleColorR
Definition: DtIntervisibilitySettingsRecord.h:171
DT_DLL_terrainCS bool operator==(const DtDegMinSec &lhs, const DtDegMinSec &rhs)
float myCircleColorR
Definition: DtIntervisibilitySettingsRecord.h:173
Contains DLL export macros.
float myBlockedColorR
Definition: DtIntervisibilitySettingsRecord.h:172
bool myRangeInfoRangeFieldEnabledFlag
Deprecated as of Version 4.
Definition: DtIntervisibilitySettingsRecord.h:177
bool myHatLinesOnSelectionOnly
Definition: DtIntervisibilitySettingsRecord.h:164
double myEndPointIntervisibilityElevation
Definition: DtIntervisibilitySettingsRecord.h:167
bool myLeftClickMakesObjectsPermanent
Definition: DtIntervisibilitySettingsRecord.h:161
double myEntityFanUpdateRate
Definition: DtIntervisibilitySettingsRecord.h:169
DT_DLL_terrainCS bool operator!=(const DtDegMinSec &lhs, const DtDegMinSec &rhs)
Record class for Intervisibility settings.
Definition: DtIntervisibilitySettingsRecord.h:19
#define DT_DLL_MAKARCHIVES
Definition: makArchives.h:31
bool myIntervisibilityEnabled
Definition: DtIntervisibilitySettingsRecord.h:160

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)