-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPoint.h
55 lines (46 loc) · 1.44 KB
/
Point.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
/***************************************************************************
* Point.h
* Created on: Jan 12, 2010
* Author: TF
* \copyright
* Copyright (c) 2015, OpenGeoSys Community (http://www.opengeosys.org)
* Distributed under a Modified BSD License.
* See accompanying file LICENSE.txt or
* http://www.opengeosys.org/project/license
**************************************************************************/
#ifndef POINT_H_
#define POINT_H_
#include "TemplatePoint.h"
namespace GEOLIB
{
/**
* \ingroup GEOLIB
*/
typedef TemplatePoint<double> Point;
/**
* comparison based on the x coordinate
* @param p0 first point
* @param p1 second point
* @return true if the x coordinate of p0 is smaller equal the x coordinate of p1, else false
*/
bool lessX(Point const& p0, Point const& p1);
/**
* comparison based on the y coordinate
* @param p0 first point
* @param p1 second point
* @return true if the y coordinate of p0 is smaller equal the y coordinate of p1, else false
*/
bool lessY(Point const& p0, Point const& p1);
/**
* comparison based on the z coordinate
* @param p0 first point
* @param p1 second point
* @return true if the z coordinate of p0 is smaller equal the z coordinate of p1, else false
*/
bool lessZ(Point const& p0, Point const& p1);
}
/**
* lexicographic comparison of points
*/
bool operator<=(GEOLIB::Point const& p0, GEOLIB::Point const& p1);
#endif /* POINT_H_ */