00001 // rdBody.cpp 00002 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 00003 // Copyright 2000 Realistic Dynamics, Inc. 00004 // All rights reserved. 00005 // 00006 // CONFIDENTIAL 00007 // 00008 // The material contain within this file is the sole property of 00009 // Realistic Dynamics, Inc., and may not be read, copied, or distributed 00010 // without the expressed writen consent of Realistic Dynamics, Inc. 00011 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 00012 #include "rdModel.h" 00013 //============================================================================ 00014 #ifndef __rdBody_h__ 00015 #define __rdBody_h__ 00016 00017 00018 00019 //============================================================================= 00020 //============================================================================= 00024 class RDSIMULATION_API rdBody 00025 { 00026 00027 //============================================================================= 00028 // DATA 00029 //============================================================================= 00030 private: 00031 double _M; 00032 double _I[6]; 00033 00034 //============================================================================= 00035 // METHODS 00036 //============================================================================= 00037 public: 00038 rdBody(double aM=1.0,double *aI=NULL); 00039 virtual ~rdBody(); 00040 00041 //-------------------------------------------------------------------------- 00042 // GET AND SET 00043 //-------------------------------------------------------------------------- 00044 void setMass(double aM); 00045 double getMass(); 00046 void setInertia(double *aI); 00047 void setInertia(double I1,double I2,double I3); 00048 void setInertia(double I1,double I2,double I3, 00049 double I12,double I23,double I31); 00050 void getInertia(double aI[6]); 00051 void getInertia(double aI[3][3]); 00052 00053 }; 00054 00055 #endif //__rdBody_h__
1.3