linear_segment.hpp
Go to the documentation of this file.
1 
4 /*****************************************************************************
5 ** Ifdefs
6 *****************************************************************************/
7 
8 #ifndef ecl_geometry_GEOMETRY_LINEAR_SEGMENT_HPP_
9 #define ecl_geometry_GEOMETRY_LINEAR_SEGMENT_HPP_
10 
11 /*****************************************************************************
12 ** Includes
13 *****************************************************************************/
14 
16 
17 /*****************************************************************************
18 ** Namespaces
19 *****************************************************************************/
20 
21 namespace ecl {
22 
23 /*****************************************************************************
24 ** Interfaces
25 *****************************************************************************/
26 
27 class LinearSegment {
28 public:
29  LinearSegment(const double& x_1,
30  const double& y_1,
31  const double& x_2,
32  const double& y_2);
33 
47  double squaredDistanceFromPoint(const double& x, const double& y) const;
48 
50 
51 private:
52  double x_1, y_1;
53  double x_2, y_2;
54 };
55 
56 /*****************************************************************************
57 ** Trailers
58 *****************************************************************************/
59 
60 } // namespace ecl
61 
62 #endif /* ecl_geometry_GEOMETRY_LINEAR_SEGMENT_HPP_ */
ecl::LinearSegment::x_1
double x_1
Definition: linear_segment.hpp:66
ecl::LinearSegment::A
ecl::Parameter< double > A
Definition: linear_segment.hpp:63
ecl::Parameter< double >
ecl::LinearSegment::y_2
double y_2
Definition: linear_segment.hpp:67
ecl::LinearSegment::C
ecl::Parameter< double > C
Definition: linear_segment.hpp:63
parameter.hpp
ecl::LinearSegment::B
ecl::Parameter< double > B
Definition: linear_segment.hpp:63
ecl::LinearSegment::LinearSegment
LinearSegment(const double &x_1, const double &y_1, const double &x_2, const double &y_2)
Definition: lib/linear_segment.cpp:24
ecl::LinearSegment::x_2
double x_2
Definition: linear_segment.hpp:67
ecl::LinearSegment::squaredDistanceFromPoint
double squaredDistanceFromPoint(const double &x, const double &y) const
Distance of a point from the segment.
Definition: lib/linear_segment.cpp:40
ecl::LinearSegment::y_1
double y_1
Definition: linear_segment.hpp:66
ecl
Embedded control libraries.


ecl_geometry
Author(s): Daniel Stonier
autogenerated on Wed Mar 2 2022 00:16:39