00001 /* 00002 * ExNihilo 3D Engine 00003 * 00004 * This program is free software; you can redistribute it and/or modify 00005 * it under the terms of the GNU General Public License as published by 00006 * the Free Software Foundation; either version 2 of the License, or 00007 * (at your option) any later version. 00008 * 00009 * This program is distributed in the hope that it will be useful, 00010 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00012 * GNU Library General Public License for more details. 00013 * 00014 * You should have received a copy of the GNU General Public License 00015 * along with this program; if not, write to the Free Software 00016 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00017 * 00018 * Please read AUTHORS file !!! 00019 * 00020 * $Id: ExCCamera.h,v 1.5 2002/07/02 13:48:46 data Exp $ 00021 * 00022 */ 00023 00024 #ifndef __EXCCAMERA_H__ 00025 #define __EXCCAMERA_H__ 00026 //-------------------------------- 00027 // File to include 00028 //-------------------------------- 00029 #include "ExDefine.h" 00030 #include "ExMath.h" 00031 #include "ExCObject.h" 00032 #include "ExManagerPVS.h" 00033 #include "ExManagerCollision.h" 00034 //-------------------------------- 00035 class ExCCamera : public ExCObject 00036 { 00037 protected: 00038 //-------------------------------- 00039 // Variable 00040 //-------------------------------- 00041 bool m_Actif; 00042 float m_Zoom; 00043 float m_ClipFar; 00044 float m_ClipNear; 00045 float m_ZoomDefault; 00046 float m_ZoomMax; 00047 float m_ZoomMin; 00048 ExCVec3D VecX,VecY,VecZ,VecDir; 00049 ExCVec3D m_vPosition,m_vView,m_vUpVector; 00050 public: 00051 int m_speed; 00052 //-------------------------------- 00053 // Constructor // Destructor 00054 //-------------------------------- 00055 ExCCamera(void); 00056 ~ExCCamera(void); 00057 //-------------------------------- 00058 // Methode 00059 //-------------------------------- 00060 void Draw(void); 00061 void ZoomIn(void); 00062 void ZoomOut(void); 00063 void ResetZoom(void); 00064 void ZoomIn(float zoom); 00065 void ZoomOut(float zoom); 00066 00067 void SetZoom(float zoom); 00068 void SetZoomMax(float zoom); 00069 void SetZoomMin(float zoom); 00070 void SetZoomDefault(float zoom); 00071 void SetClipFar(float clip); 00072 void SetClipNear(float clip); 00073 00074 00075 float GetZoomMax(void){return m_ZoomMax;} 00076 float GetZoomMin(void){return m_ZoomMin;} 00077 float GetZoom(void){return m_Zoom;} 00078 float GetZoomDefault(void){return m_ZoomDefault;} 00079 float GetClipFar(void){return m_ClipFar;} 00080 float GetClipNear(void){return m_ClipNear;} 00081 00082 void GoToView(bool state); 00083 00084 void RotateView(float X, float Y, float Z); 00085 void StrafeCamera(float speed); 00086 void MoveCamera(float speed); 00087 //-------------------------------- 00088 // Operator 00089 //-------------------------------- 00090 //-------------------------------- 00091 // friends 00092 //-------------------------------- 00093 }; 00094 #endif //__EXCCAMERA_H__