00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #ifndef CybWinMouseVPCtrlC_H
00027 #define CybWinMouseVPCtrlC_H
00028
00029
00030 #include "oaw/ctk/cybviewc.h"
00031 #include "oaw/ctk/cybviewpointsensorc.h"
00032 #include "../oawconfig.h"
00033
00034 OAW_BEGIN_NAMESPACE
00035
00036
00037 class Cyb2DViewPointingDeviceC;
00038 class CybScriptC;
00039 class CybGraphicChannelC;
00040
00041 class OAW_DLLMAPPING CybWinMouseVPCtrlC{
00042
00043 public:
00044 enum NavMode{cFLY,cSTUDY};
00045 CybWinMouseVPCtrlC(CybWorldC*);
00046 void SetViewpointSensor(CybViewpointSensorC* pS);
00047
00048 void SetNavMode(NavMode);
00049 void Button(int button, int state, int x, int y);
00050 void Motion(int x,int y);
00051
00052 void Update();
00053
00054 protected:
00055 void MoveViewpoint(double);
00056
00057 void SetViewpointPos(const VectorC&);
00058 void SetViewpointNormal(const VectorC&);
00059
00060 protected:
00061
00062
00063 CybWorldC* m_pWorld;
00064
00065 TimeC m_lastUpdateView;
00066 TimeC m_lastFramecounterReset;
00067 int m_framecounter;
00068 double m_minFrameRate;
00069
00070 int m_blickmodus;
00071 double m_dYScale;
00072 double m_dSpeed;
00073
00074 SFVec2f m_p;
00075 SFVec2f m_pp;
00076 int m_bt;
00077
00078 CybViewpointSensorC* m_pViewpointSensor;
00079
00080 SFVec3f m_viewpointPos;
00081 SFVec3f m_viewpointNorm;
00082 double m_viewpointRol;
00083
00084 };
00085
00086 OAW_END_NAMESPACE
00087
00088
00089 #endif
00090
00091
00092
00093
00094
00095
00096