Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

point3d.h

Go to the documentation of this file.
00001 #ifndef MSL_POINT3D_H
00002 #define MSL_POINT3D_H
00003 
00004 #include <stream.h>
00005 #include <list.h>
00006 
00007 
00008 class MSLPoint3d
00009 {
00010   double xrep;
00011   double yrep;
00012   double zrep;
00013 
00014 public:
00015   
00016   MSLPoint3d();
00017   MSLPoint3d(double x, double y, double z);
00018   ~MSLPoint3d() {}
00019   double  xcoord()  const   { return xrep; }
00020   double  ycoord()  const   { return yrep; }
00021   double  zcoord()  const   { return zrep; }
00022   double  W()   const   { return 1; }
00023   double  WD()  const   { return 1; }
00024   int     dim() const { return 3; }
00025   double  sqr_dist(const MSLPoint3d& q) const;
00026   double xdist(const MSLPoint3d& q) const;
00027   double ydist(const MSLPoint3d& q) const;
00028   double zdist(const MSLPoint3d& q) const;
00029   double  distance(const MSLPoint3d& q) const;
00030   MSLPoint3d translate(double dx, double dy, double dz) const;
00031   MSLPoint3d reflect(const MSLPoint3d& q, const MSLPoint3d& r, 
00032                      const MSLPoint3d& s) const;
00033   MSLPoint3d reflect(const MSLPoint3d& q) const;
00034   bool operator==(const MSLPoint3d& q) const;
00035   bool operator!=(const MSLPoint3d& q)  const { return !operator==(q);}
00036   friend ostream& operator<<(ostream& O, const MSLPoint3d& p) ;
00037   friend istream& operator>>(istream& I, MSLPoint3d& p) ;
00038   friend istream& operator>>(istream& is, list<MSLPoint3d> & vl);
00039   friend ostream& operator<<(ostream& os, const list<MSLPoint3d> & vl);
00040 };
00041 
00042 #endif
00043 
00044 
00045 
00046 
00047 
Motion Strategy Library


Web page maintained by Steve LaValle
Partial support provided by NSF CAREER Award IRI-970228 (LaValle), Honda Research, and Iowa State University.
Contributors: Anna Atramentov, Peng Cheng, James Kuffner, Steve LaValle, and Libo Yang.