CigiBaseTrajectoryDef.h

Go to the documentation of this file.
00001 
00055 #if !defined(_CIGI_BASE_TRAJECTORY_DEF_INCLUDED_)
00056 #define _CIGI_BASE_TRAJECTORY_DEF_INCLUDED_
00057 
00058 #include "CigiBasePacket.h"
00059 
00060 // ====================================================================
00061 // preprocessor definitions
00062 // ====================================================================
00063 
00064 #define CIGI_TRAJECTORY_DEF_PACKET_ID_V1 21
00065 #define CIGI_TRAJECTORY_DEF_PACKET_SIZE_V1 28
00066 
00067 #define CIGI_TRAJECTORY_DEF_PACKET_ID_V2 21
00068 #define CIGI_TRAJECTORY_DEF_PACKET_SIZE_V2 16
00069 
00070 #define CIGI_TRAJECTORY_DEF_PACKET_ID_V3 20
00071 #define CIGI_TRAJECTORY_DEF_PACKET_SIZE_V3 24
00072 
00073 
00074 class CigiTrajectoryDefV1;
00075 class CigiTrajectoryDefV2;
00076 class CigiTrajectoryDefV3;
00077 
00078 
00079 class CIGI_SPEC CigiBaseTrajectoryDef : public CigiBasePacket
00080 {
00081 
00082 friend class CigiTrajectoryDefV1;
00083 friend class CigiTrajectoryDefV2;
00084 friend class CigiTrajectoryDefV3;
00085 
00086 public:
00087 
00088    //==> Management
00089 
00090    //=========================================================
00093    CigiBaseTrajectoryDef();
00094 
00095    //=========================================================
00098    virtual ~CigiBaseTrajectoryDef();
00099 
00100 
00101    //==> Buffer Packing/Unpacking
00102 
00103    //=========================================================
00114    virtual int Pack(CigiBasePacket * Base, Cigi_uint8 * Buff, void *Spec) const=0;
00115 
00116    //=========================================================
00127    virtual int Unpack(Cigi_uint8 * Buff, bool Swap, void *Spec) =0;
00128 
00129    //=========================================================
00141         virtual int GetCnvt(CigiVersionID &CnvtVersion,
00142                        CigiCnvtInfoType::Type &CnvtInfo);
00143 
00144 
00145 
00146    //==> Accessing Member Variable Values functions
00147 
00148    //+> EntityID
00149 
00150    //=========================================================
00157    int SetEntityID(const Cigi_uint16 EntityIDIn, bool bndchk=true)
00158    {
00159       EntityID = EntityIDIn;
00160       return(CIGI_SUCCESS);
00161    }
00162 
00163    //=========================================================
00166    Cigi_uint16 GetEntityID(void) const { return(EntityID); }
00167 
00168 
00169    //+> RetardationRate
00170 
00171    //=========================================================
00178    int SetRetardationRate(const float RetardationRateIn, bool bndchk=true)
00179    {
00180       RetardationRate = RetardationRateIn;
00181       return(CIGI_SUCCESS);
00182    }
00183 
00184    //=========================================================
00187    float GetRetardationRate(void) const { return(RetardationRate); }
00188 
00189 
00190    //+> TermVel
00191 
00192    //=========================================================
00199    int SetTermVel(const float TermVelIn, bool bndchk=true)
00200    {
00201       TermVel = TermVelIn;
00202       return(CIGI_SUCCESS);
00203    }
00204 
00205    //=========================================================
00208    float GetTermVel(void) const { return(TermVel); }
00209 
00210 
00211 
00212 protected:
00213 
00214    //==> Member variables
00215 
00216    //=========================================================
00221    Cigi_uint16 EntityID;
00222 
00223    //=========================================================
00227    float Accel;
00228 
00229    //=========================================================
00233    float RetardationRate;
00234 
00235    //=========================================================
00239    float TermVel;
00240 
00241    //=========================================================
00246    float Xoff;
00247 
00248    //=========================================================
00253    float Yoff;
00254 
00255    //=========================================================
00260    float Zoff;
00261 
00262    //=========================================================
00266    float AccelX;
00267 
00268    //=========================================================
00272    float AccelY;
00273 
00274    //=========================================================
00278    float AccelZ;
00279 
00280 
00281 
00282 };
00283 
00284 #endif // #if !defined(_CIGI_BASE_TRAJECTORY_DEF_INCLUDED_)

Generated on Wed Apr 29 08:59:56 2009 for CCL by  doxygen 1.4.7