CEL

Public API Reference

propclass/defcam.h

00001 /*
00002     Crystal Space Entity Layer
00003     Copyright (C) 2001-2005 by Jorrit Tyberghein
00004 
00005     This library is free software; you can redistribute it and/or
00006     modify it under the terms of the GNU Library General Public
00007     License as published by the Free Software Foundation; either
00008     version 2 of the License, or (at your option) any later version.
00009 
00010     This library is distributed in the hope that it will be useful,
00011     but WITHOUT ANY WARRANTY; without even the implied warranty of
00012     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00013     Library General Public License for more details.
00014 
00015     You should have received a copy of the GNU Library General Public
00016     License along with this library; if not, write to the Free
00017     Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00018 */
00019 
00020 #ifndef __CEL_PF_DEFAULT_CAMERA__
00021 #define __CEL_PF_DEFAULT_CAMERA__
00022 
00023 #include "propclass/camera.h"
00024 
00025 struct iCelEntity;
00026 
00027 SCF_VERSION (iPcDefaultCamera, 0, 0, 3);
00028 
00055 struct iPcDefaultCamera : public iPcCamera
00056 {
00057 public:
00061   enum CameraMode
00062   {
00063     freelook = 0,
00064     firstperson,
00065     thirdperson,
00066     m64_thirdperson,
00067     lara_thirdperson,
00068 
00069     actual_data,        // The actual camera data
00070     last_actual,        // Keep reference to the actual data last frame
00071     transition,
00072     camerror,           // Error between actual camera pos and ideal.
00073 
00074     CameraMode_count
00075   };
00076 
00082   virtual void SetFollowEntity (iCelEntity* entity) = 0;
00083 
00087   virtual bool SetMode (CameraMode m, bool use_cd = true) = 0;
00088 
00092   virtual CameraMode GetMode () const = 0;
00093 
00097   virtual bool SetModeName (const char* m, bool use_cd = true) = 0;
00098 
00102   virtual const char* GetModeName () const = 0;
00103 
00108   virtual CameraMode GetNextMode () const = 0;
00109 
00114   virtual bool PointCamera (const char* start) = 0;
00115 
00119   virtual void SetSpringParameters (float springCoef,
00120         float intertialDampeningCoef, float springLength) = 0;
00121 
00127   virtual void SetMinMaxCameraDistance (float minDistance,
00128         float maxDistance) = 0;
00129 
00134   virtual void SetTurnSpeed (float turnSpeed) = 0;
00135 
00139   virtual void SetSwingCoef (float swingCoef) = 0;
00140 
00145   virtual void SetFirstPersonOffset (const csVector3& offset) = 0;
00146 
00151   virtual void SetThirdPersonOffset (const csVector3& offset) = 0;
00152 
00157   virtual void CenterCamera () = 0;
00158 
00162   virtual void SetPitch (float pitch) = 0;
00163 
00167   virtual float GetPitch () const = 0;
00168 
00173   virtual void SetPitchVelocity (float pitchVel) = 0;
00174 
00178   virtual float GetPitchVelocity () const = 0;
00179 
00186   virtual void MovePitch (float deltaPitch, int mode = -1) = 0;
00187 
00194   virtual void SetYaw (float yaw, int mode = -1) = 0;
00195 
00202   virtual void MoveYaw (float deltaYaw, int mode = -1) = 0;
00203 
00210   virtual float GetYaw (int mode = -1) const = 0;
00211 
00216   virtual void SetYawVelocity (float yawVel) = 0;
00217 
00222   virtual float GetYawVelocity () const = 0;
00223 
00229   virtual void SetDistance (float distance, int mode=-1) = 0;
00230 
00236   virtual float GetDistance (int mode=-1) = 0;
00237 
00242   virtual void SetDistanceVelocity (float distanceVel) = 0;
00243 
00248   virtual float GetDistanceVelocity () const = 0;
00249 
00250 };
00251 
00252 #endif // __CEL_PF_DEFAULT_CAMERA_FACTORY__
00253 

Generated for CEL: Crystal Entity Layer by doxygen 1.4.7