VR-Forces Development_Version Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DtTritonWaterClampingUpdater.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2016 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #pragma once
11 #include <vrvTriton/vrvTriton.h>
12 
14 #include <matrix/vlVector.h>
15 #include <matrix/vlTaitBryan.h>
17 
18 namespace makVrv
19 {
20  class DtRk4MotionModel;
21  class DtTritonManager;
22  class DtObserverObject;
23 
31  {
32 
33  public:
34 
37 
40 
42  virtual bool clampToWater(DtTime tNow);
43 
45  virtual void setPaused(bool isPaused);
46 
48  virtual void setLOD(float lodDistance);
49 
51  virtual void setWaterlineOriginOffset(float offset);
52 
53  protected:
55  virtual double altitudeAt(const DtVector& pos);
56 
58  virtual void addAltitude(DtVector& pos, float altitudeToAdd );
59 
61  virtual DtVector moveToAltitude(const DtVector& pos, double alt);
62 
67  virtual DtTaitBryan computeMotionOrientation();
68 
70  virtual bool isFullyImmersed();
71 
72  virtual void adjustSinkingSpeedScale( const DtVector& inputPosition,
73  const DtVector& currentPosition );
74 
77  virtual void smoothMotionAndSeaLevel(double percent,
78  DtVector& outputPos, DtTaitBryan &outputOri);
79 
80  //handle sea level change signals
81  virtual void slot_oceanLayerSeaLevelChanged(double sealevel);
82 
83  //helper method to set the water line alitude based on the offset and sealevel
84  virtual void updateWaterLineAltitude(double sealevel);
85 
86  //Initialize the extents of the motion model based on the scene object
87  virtual bool initializeExtents(double sealevel);
88 
89  // Using the cull type, determines if the entity should suppress its buoyancy
90  // calculation because it is out of view of any observer
91  virtual bool checkCull( DtObserverObject* const observer, const DtVector& eyeToShip ) const;
92 
93  protected:
94 
95  static const double theMotionTimeout;
96  static const double theSmoothTime;
97  static const double theFullyLodScaler;
98 
107  DtTaitBryan myLastMotionOri;
117 
118  };
119 }

Document ID: Generated on Mon Jul 4 01:00:18 EDT 2016 from SVN revision 166489
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)