VR-Forces 4.3 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DtObserverSettingsRecord.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2008 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 /******************************************************************************
6 ** $RCSfile: DtObserverSettingsRecord.h,v $ $Revision: 1.5 $ $State: Exp $
7 ******************************************************************************/
8 
12 
13 #ifndef DtObserverSettingsRecord_H_
14 #define DtObserverSettingsRecord_H_
15 
17 
18 #include <string>
19 
20 namespace makArchives
21 {
25  {
26  public:
27 
29  {
37  AttachTypeSpaceFollow
38  };
39 
42 
45 
47  DtObserverSettingsRecord& operator=(const DtObserverSettingsRecord& orig);
48 
51 
53 
54 
55  void setObserverMode( const std::string& observerMode );
56  const std::string& observerMode() const;
57 
58  void setAttachType( AttachType type );
59  AttachType attachType() const;
60 
61  void setHideModelOnAttach( bool hide );
62  bool hideModelOnAttach() const;
63 
64  void setOrientToTargetConstraint( bool orient );
65  bool orientToTargetConstraint() const;
66 
67  void setOrbitSpeedGain( int gain );
68  int orbitSpeedGain() const;
69 
70  void setRotationSpeedGain( int gain );
71  int rotationSpeedGain() const;
72 
73  void setLinearScaledSpeedGain( int gain );
74  int linearScaledSpeedGain() const;
75 
76  void setLinearUnscaledSpeedGain( int gain );
77  int linearUnscaledSpeedGain() const;
78 
81 
82  void setOrbitSpeed( double speed );
83  double orbitSpeed() const;
84 
85  void setRotationSpeed( double speed );
86  double rotationSpeed() const;
87 
88  void setLinearSpeed( double speed );
89  double linearSpeed() const;
90 
92 
93 
94  protected:
95 
96  friend class boost::serialization::access;
97 
101  template<class Archive>
102  void serialize(Archive & ar, const unsigned int version)
103  {
104  ar & BOOST_SERIALIZATION_NVP(myAttachType);
105  ar & BOOST_SERIALIZATION_NVP(myHideModelOnAttach);
106  ar & BOOST_SERIALIZATION_NVP(myOrientToTargetConstraint);
107  // no longer used
108  ar & BOOST_SERIALIZATION_NVP(mySpeedScaling);
109  // no longer used
110  ar & BOOST_SERIALIZATION_NVP(myConstrainToTerrain);
111  ar & BOOST_SERIALIZATION_NVP(myOrbitSpeedGain);
112  ar & BOOST_SERIALIZATION_NVP(myRotationSpeedGain);
113  ar & BOOST_SERIALIZATION_NVP(myLinearScaledSpeedGain);
114  ar & BOOST_SERIALIZATION_NVP(myLinearUnscaledSpeedGain);
115  //ar & BOOST_SERIALIZATION_NVP(myGainPrecision);
116  ar & BOOST_SERIALIZATION_NVP(myOrbitSpeed);
117  ar & BOOST_SERIALIZATION_NVP(myRotationSpeed);
118  ar & BOOST_SERIALIZATION_NVP(myLinearSpeed);
119  if ( version >= 2 )
120  {
121  ar & BOOST_SERIALIZATION_NVP(myObserverMode);
122  }
123  }
124 
125  protected:
126 
127  std::string myObserverMode;
137  //int myGainPrecision;
138  double myOrbitSpeed;
141 
142  };
143 }
144 
146 
147 #endif
148 

Document ID: Generated on Wed Mar 11 21:20:57 EDT 2015 from SVN revision 150940
Copyright © 2005-2014 VT MÄK. All Rights Reserved (www.mak.com)