00001 //*************************************************************************************** 00002 // File supervisor: Crosswalk team 00012 //*************************************************************************************** 00013 00014 #ifndef _CAMERA_H 00015 #define _CAMERA_H 00016 00017 #include "Primitive.h" 00018 #include "ConstrainableType.h" 00019 00025 class XSIEXPORT CSLCamera 00026 : public CSLPrimitive, public CSLConstrainableType 00027 { 00028 public: 00029 00035 CSLCamera(CSLScene* in_pScene, CSLModel *in_pModel, CdotXSITemplate* in_pTemplate); 00036 00039 virtual ~CSLCamera(); 00040 00044 SI_Float GetFarPlane(); 00045 00049 SI_Void SetFarPlane(SI_Float in_fValue); 00050 00054 SI_Float GetFieldOfView(); 00055 00059 SI_Void SetFieldOfView(SI_Float in_fValue); 00060 00064 CSIBCVector3D GetInterestPosition(); 00065 00069 SI_Void SetInterestPosition(CSIBCVector3D& in_rValue); 00070 00074 CSIBCVector3D GetPosition(); 00075 00079 SI_Void SetPosition(CSIBCVector3D& in_rValue); 00080 00084 SI_Float GetNearPlane(); 00085 00089 SI_Void SetNearPlane(SI_Float in_fValue); 00090 00094 virtual SI_Float GetRoll(); 00095 00099 virtual SI_Void SetRoll(SI_Float in_fValue); 00100 00105 CSLConstraint* AddConstraint(CSLConstraint::EConstraintType in_ConstraintType); 00106 00107 virtual SI_Error Synchronize(); 00108 00109 /* Returns the type of this template 00110 \retval CSLTemplate::SI_CAMERA Template type 00111 */ 00112 virtual ETemplateType Type(); 00113 virtual CSLAnimatableType* ParameterFromName(SI_Char *in_szName); 00114 00143 virtual CSLAnimatableType* ParameterFromType(EFCurveType in_Type, SI_Char *in_szParameterName); 00144 00145 CSLVector3DProxy* GetInterestPositionProxy() { return &m_InterestPosition;}; 00146 CSLVector3DProxy* GetPositionProxy() { return &m_Position;}; 00147 CSLFloatProxy* GetRollProxy() { return &m_Roll;}; 00148 CSLFloatProxy* GetFOVProxy() { return &m_FieldOfView;}; 00149 CSLFloatProxy* GetNearPlaneProxy() { return &m_NearPlane;}; 00150 CSLFloatProxy* GetFarPlaneProxy() { return &m_FarPlane;}; 00151 00152 private: 00153 CSLVector3DProxy m_InterestPosition; 00154 CSLVector3DProxy m_Position; 00155 CSLFloatProxy m_Roll; 00156 CSLFloatProxy m_FieldOfView; 00157 CSLFloatProxy m_NearPlane; 00158 CSLFloatProxy m_FarPlane; 00159 00160 void *m_pReserved; // reserved for future extension 00161 }; 00162 00163 #endif