00001 #ifndef ELLIPSE_CLASS
00002 #define ELLIPSE_CLASS
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #include "geometric_dll.h"
00019
00020 namespace geometric {
00021
00022
00023 class cartesian_point;
00024 class double_angle;
00025
00027
00029 class GEOMETRIC_CLASS_STYLE ellipse
00030 {
00031 public:
00032 ellipse();
00033 ellipse(const cartesian_point ¢er, double width_from_center,
00034 double height_from_center);
00035 ellipse(const ellipse &to_copy);
00036
00037 ~ellipse();
00038
00039 ellipse &operator = (const ellipse &to_copy);
00040
00041 double area() const;
00043
00044 double perimeter() const;
00046
00049 bool inside(const cartesian_point &where) const;
00051
00052 cartesian_point location(const double_angle &where) const;
00054
00057 cartesian_point center() const;
00058 double width_from_center() const;
00059 double height_from_center() const;
00060
00061 void center(const cartesian_point &to_set);
00062 void width_from_center(double to_set);
00063 void height_from_center(double to_set);
00064
00065 protected:
00066 cartesian_point *_center;
00067 double _width_from_center;
00068 double _height_from_center;
00069 };
00070
00071 }
00072
00073 #endif
00074