2 #ifndef vgl_infinite_line_3d_h_ 3 #define vgl_infinite_line_3d_h_ 16 # include <vcl_msvc_warnings.h> 58 x0_ = inf_l.x0();
t_ = inf_l.direction();
65 x0_ = inf_l.x0();
t_ = inf_l.direction();
78 {
return (
this==&
l) || (
direction() ==
l.direction() &&
x0() ==
l.x0()); }
103 template <
class Type>
108 template <
class Type>
110 #define VGL_INFINITE_LINE_3D_INSTANTIATE(T) extern "please include vgl/vgl_infinite_line_3d.hxx first" 112 #endif // vgl_infinite_line_3d_h_ ~vgl_infinite_line_3d()=default
Destructor.
vgl_infinite_line_3d(vgl_vector_2d< Type > const &x_0, vgl_vector_3d< Type > const &direction)
Construct from x0 and direction.
vgl_point_3d< Type > point1() const
vgl_vector_2d< Type > x0() const
Accessors.
bool operator==(vgl_infinite_line_3d< Type > const &l) const
The comparison operator.
vgl_vector_3d< Type > direction() const
vgl_point_3d< Type > point2() const
direction vector in Euclidean 3D space
Represents a cartesian 3D point.
bool contains(const vgl_point_3d< Type > &p) const
Check if point p is on the line.
std::ostream & operator<<(std::ostream &s, vgl_orient_box_3d< Type > const &p)
Write box to stream.
vgl_infinite_line_3d(vgl_line_3d_2_points< Type > const &ls)
Construct from a line 2 points.
vgl_infinite_line_3d(vgl_line_segment_3d< Type > const &ls)
Construct from a line segment.
vgl_vector_2d< Type > x0_
line position vector
A class to hold a non-homogeneous representation of a 3D line.
vgl_vector_3d< Type > t_
line direction vector (tangent)
bool operator!=(vgl_infinite_line_3d< Type >const &other) const
a point in 3D nonhomogeneous space
line segment in 3D nonhomogeneous space
double length() const
Return the length of this vector.
vgl_point_3d< Type > point_t(const double t) const
Return a point on the line defined by a scalar parameter t.
vgl_point_3d< Type > point1() const
Return the first point representing this line.
vgl_infinite_line_3d(vgl_infinite_line_3d< Type > const &l)
Copy constructor.
Represents a 3D line segment using two points.
void set(vgl_vector_2d< Type > const &x_0, vgl_vector_3d< Type > const &direction)
Assignment.
direction vector in Euclidean 2D space
Represents a 3-d line with position defined in the orthogonal plane passing through the origin.
vgl_infinite_line_3d()=default
Default constructor - does not initialise!.
std::istream & operator>>(std::istream &is, vgl_orient_box_3d< Type > &p)
Read box from stream.
vgl_point_3d< Type > point2() const
Return the second point representing this line.
non-homogeneous 3D line, represented by 2 points.
void compute_uv_vectors(vgl_vector_3d< Type > &u, vgl_vector_3d< Type > &v) const
The unit vectors perpendicular to the line direction.
vgl_point_3d< Type > point() const
Return the point on the line closest to the origin.