OpenStructure
composite2_op.hh
Go to the documentation of this file.
1 //------------------------------------------------------------------------------
2 // This file is part of the OpenStructure project <www.openstructure.org>
3 //
4 // Copyright (C) 2008-2020 by the OpenStructure authors
5 //
6 // This library is free software; you can redistribute it and/or modify it under
7 // the terms of the GNU Lesser General Public License as published by the Free
8 // Software Foundation; either version 3.0 of the License, or (at your option)
9 // any later version.
10 // This library is distributed in the hope that it will be useful, but WITHOUT
11 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12 // FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
13 // details.
14 //
15 // You should have received a copy of the GNU Lesser General Public License
16 // along with this library; if not, write to the Free Software Foundation, Inc.,
17 // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 //------------------------------------------------------------------------------
19 #ifndef GEOM_COMPOSITE2_OP_HH
20 #define GEOM_COMPOSITE2_OP_HH
21 
22 #include "constants.hh"
23 #include "vec2.hh"
24 #include "composite2.hh"
25 
26 namespace geom {
27 
28 
29 Real DLLEXPORT_OST_GEOM Angle(const Line2& l1, const Line2& l2);
31 
33 
34 bool DLLEXPORT_OST_GEOM IsOnLine(const Line2& l, const Vec2& v, Real ephilon=EPSILON);
35 bool DLLEXPORT_OST_GEOM operator==(const Line2& l1, const Line2& l2);
36 bool DLLEXPORT_OST_GEOM Equal(const Line2& l1, const Line2& l2,Real ephilon=EPSILON);
37 bool DLLEXPORT_OST_GEOM EqualPosition(const Line2& l1, const Line2& l2,Real ephilon=EPSILON);
38 
39 bool DLLEXPORT_OST_GEOM AreParallel(const Line2& l1, const Line2& l2,Real ephilon=EPSILON);
40 
41 DLLEXPORT_OST_GEOM bool IsInPolygon(const Polygon2& p, const Vec2& v);
44 DLLEXPORT_OST_GEOM bool IsInCircle(const Circle2& c, const Vec2& v);
45 
46 } // ns
47 
48 
49 #endif
Line2.
Definition: composite2.hh:33
#define DLLEXPORT_OST_GEOM
float Real
Definition: base.hh:44
Real DLLEXPORT_OST_GEOM Angle(const Line2 &l1, const Line2 &l2)
Real DLLEXPORT_OST_GEOM Distance(const Line2 &l, const Vec2 &v)
Vec2 DLLEXPORT_OST_GEOM IntersectionPoint(const Line2 &l1, const Line2 &l2)
DLLEXPORT_OST_GEOM bool IsInRectangle(const Rectangle2 &r, const Vec2 &v)
bool DLLEXPORT_OST_GEOM IsOnLine(const Line2 &l, const Vec2 &v, Real ephilon=EPSILON)
DLLEXPORT_OST_GEOM bool IsInCircle(const Circle2 &c, const Vec2 &v)
bool DLLEXPORT_OST_GEOM EqualPosition(const Line2 &l1, const Line2 &l2, Real ephilon=EPSILON)
DLLEXPORT_OST_GEOM bool IsInPolygon(const Polygon2 &p, const Vec2 &v)
static const Real EPSILON
Definition: constants.hh:28
bool DLLEXPORT_OST_GEOM Equal(const Line2 &l1, const Line2 &l2, Real ephilon=EPSILON)
bool DLLEXPORT_OST_GEOM AreParallel(const Line2 &l1, const Line2 &l2, Real ephilon=EPSILON)
bool DLLEXPORT_OST_GEOM operator==(const Line2 &l1, const Line2 &l2)
DLLEXPORT_OST_GEOM Polygon2 SimplifyPolygon(const Polygon2 &p)