GEOS  3.9.1dev
Distance.h
Go to the documentation of this file.
1 /**********************************************************************
2  *
3  * GEOS - Geometry Engine Open Source
4  * http://geos.osgeo.org
5  *
6  * Copyright (C) 2018 Paul Ramsey <pramsey@cleverlephant.ca>
7  *
8  * This is free software; you can redistribute and/or modify it under
9  * the terms of the GNU Lesser General Public Licence as published
10  * by the Free Software Foundation.
11  * See the COPYING file for more information.
12  *
13  **********************************************************************
14  *
15  * Last port: algorithm/Distance.java @ 2017-09-04
16  *
17  **********************************************************************/
18 
19 #ifndef GEOS_ALGORITHM_DISTANCE_H
20 #define GEOS_ALGORITHM_DISTANCE_H
21 
22 #include <geos/export.h>
23 #include <geos/geom/Coordinate.h>
25 
26 namespace geos {
27 namespace algorithm { // geos::algorithm
28 
36 public:
37 
52  // formerly distanceLineLine
53  static double segmentToSegment(const geom::Coordinate& A,
54  const geom::Coordinate& B,
55  const geom::Coordinate& C,
56  const geom::Coordinate& D);
57 
67  static double pointToSegmentString(const geom::Coordinate& p,
68  const geom::CoordinateSequence* seq);
69 
83  // formerly distancePointLine
84  static double pointToSegment(const geom::Coordinate& p,
85  const geom::Coordinate& A,
86  const geom::Coordinate& B);
87 
100  // formerly distancePointLinePerpendicular
101  static double pointToLinePerpendicular(const geom::Coordinate& p,
102  const geom::Coordinate& A,
103  const geom::Coordinate& B);
104 
105 };
106 
107 } // namespace geos::algorithm
108 } // namespace geos
109 
110 #endif // GEOS_ALGORITHM_DISTANCE_H
#define GEOS_DLL
Definition: export.h:28
Coordinate is the lightweight class used to store coordinates.
Definition: Coordinate.h:60
Functions to compute distance between basic geometric structures.
Definition: Distance.h:35
Basic namespace for all GEOS functionalities.
The internal representation of a list of coordinates inside a Geometry.