VR-Forces 4.1 Class Documentation
DtDiGuyMotionModel.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2008 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 /******************************************************************************
6 ** $RCSfile: DtDiGuyMotionModel.h,v $ $Revision: 1.18 $ $State: Exp $
7 ******************************************************************************/
8 
12 
13 #pragma once
14 #include <vrvDiGuy/vrvDiGuy.h>
15 #include <vrvCore/DtMotionModel.h>
17 
18 class DtTaitBryan;
19 class DtVector;
20 
21 namespace makVrv
22 {
23  class DtModel;
24  class DtDiGuyCharacterModel;
25  class DtDe;
26 
30  {
31  public:
32 
35 
37  DtDiGuyMotionModel(const DtDiGuyMotionModel& orig, double time);
38 
40  virtual ~DtDiGuyMotionModel();
41 
43  virtual DtMotionModel* clone(double simTime);
44 
47  virtual bool motionModelHandlesUpdate() const;
48 
49  virtual void updateMotion(double simulationTime);
50 
52  virtual void modelAdded(DtModel*);
53 
55  virtual void modelRemoved(DtModel*);
56 
57  protected:
58 
59  //Calculate the direction Forward/Back/Left/Right
60  int calculateDirectionFBLR( const DtTaitBryan& ori, const DtVector& vel);
61 
62  //Calculate the direction Forward/Back
63  int calculateDirectionFB( const DtTaitBryan& ori, const DtVector& vel);
64 
65  void setCharacter(DtDiGuyCharacterModel* character);
66 
67  protected:
69 
71  mutable DtTaitBryan myOrientationReturn;
72 
74 
79  double myLastSpeed;
80  const char* myLastAction;
83 
84  };
85 
89  {
90  public:
92  virtual ~DtDiGuyMotionModelCreator();
93 
95  virtual DtMotionModel* create(DtSceneObject* owner,DtDe& de);
96  };
97 }

Document ID: Generated on Tue Jan 29 18:21:16 EST 2013 from SVN revision 123193
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (www.mak.com)