00001 // rdV3D.h 00002 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 00003 // Copyright 2002 Realistic Dynamics, Inc. 00004 // All rights reserved. 00005 // 00006 // Please do not read, copy, distribute, or use without permission. 00007 // Contact: Frank C. Anderson, fca@RealisticDynamics.com 00008 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 00009 #ifndef __rdV3D_h__ 00010 #define __rdV3D_h__ 00011 00012 // INCLUDES 00013 #include "rdTools.h" 00014 #include "rdObject.h" 00015 00016 //============================================================================= 00017 //============================================================================= 00021 class RDTOOLS_API rdV3D : public rdObject 00022 { 00023 //============================================================================= 00024 // DATA 00025 //============================================================================= 00026 private: 00027 double _v3d[3]; 00028 00029 //============================================================================= 00030 // METHODS 00031 //============================================================================= 00032 public: 00033 //-------------------------------------------------------------------------- 00034 // CONSTRUCTION 00035 //-------------------------------------------------------------------------- 00036 rdV3D(); 00037 rdV3D(const double aVertex[3]); 00038 rdV3D(IDOM_Element *aElement); 00039 virtual ~rdV3D(); 00040 private: 00041 void setNull(); 00042 00043 //-------------------------------------------------------------------------- 00044 // GET AND SET 00045 //-------------------------------------------------------------------------- 00046 public: 00047 void setVertex(const double aVertex[3]); 00048 void getVertex(double rVertex[3]) const; 00049 double getX() const; 00050 double getY() const; 00051 double getZ() const; 00052 00053 //-------------------------------------------------------------------------- 00054 // OPERATIONS 00055 //-------------------------------------------------------------------------- 00056 void translate(double aX,double aY,double aZ); 00057 void rotate(int aXYZ,double aRadians); 00058 00059 //-------------------------------------------------------------------------- 00060 // XML 00061 //-------------------------------------------------------------------------- 00062 virtual void updateObject(bool aDeep=true); 00063 virtual void updateNode(bool aDeep=true); 00064 void updateData(); 00065 00066 //============================================================================= 00067 }; // END class rdV3D 00068 //============================================================================= 00069 //============================================================================= 00070 00071 #endif // __rdV3D_h__
1.3