35 virtual const std::string
classname() {
return "a_segment";}
36 static const std::string
help();
83 virtual void read(std::istream &i);
84 virtual void write(std::ostream &o)
const;
a_point & translate(double x, double y, double z)
bool operator==(const a_segment &p)
double dist(const a_point &p) const
distance betweeen p and segment
static const std::string help()
a_point dir() const
get direction defined by segment
a_point vec() const
get vector between the two apices
virtual const std::string classname()
a_segment shortest(const a_segment &s, double &m1, double &m2) const
intersection between two segments, returns a segment between the closest point between the two segmen...
a_segment & rotate(const a_point &x_axis, const a_point &y_axis, const a_point &z_axis)
a_segment(const a_point p1, const a_point p2)
double project(const a_point v) const
a_segment(const a_segment &s)
void p1(const a_point v)
set first apex of segment
a_point c() const
center of segment
a_segment & translate(double x, double y, double z)
virtual void read(std::istream &i)
a_mat_sq inertia() const
inertia of the segment
a_segment intersect(const a_segment &s, double &m1, double &m2) const
intersection between two segments, returns a segment between the closest point between the two lines ...
a_point closestl(const a_point &p) const
point closest to p on line defined by segment
a_point p2() const
get second apex of segment
a_point closest(const a_point &p) const
point closest to p inside segment
double distl(const a_point &p) const
distance between p and line defined by segment
a_segment & operator=(const a_segment &v)
virtual void write(std::ostream &o) const
void p2(const a_point v)
set second apex of segment
a_point p1() const
get first apex of segment