Project
Loading...
Searching...
No Matches
Polygon.cxx File Reference
#include <boost/test/unit_test.hpp>
#include <iostream>
#include "../include/MCHContour/Polygon.h"
#include "../include/MCHContour/BBox.h"

Go to the source code of this file.

Classes

struct  POLYGONS
 

Macros

#define BOOST_TEST_MODULE   Test MCHContour Polygon
 
#define BOOST_TEST_MAIN
 
#define BOOST_TEST_DYN_LINK
 

Functions

 BOOST_AUTO_TEST_CASE (CreateCounterClockwiseOrientedPolygon)
 
 BOOST_AUTO_TEST_CASE (CreateClockwiseOrientedPolygon)
 
 BOOST_AUTO_TEST_CASE (SignedArea)
 
 BOOST_AUTO_TEST_CASE (AClosePolygonIsAPolygonWhereLastVertexIsTheSameAsFirstOne)
 
 BOOST_AUTO_TEST_CASE (ClosingAClosedPolygonIsANop)
 
 BOOST_AUTO_TEST_CASE (ClosePolygon)
 
 BOOST_AUTO_TEST_CASE (ThrowIfClosingAPolygonResultInANonManhattanPolygon)
 
 BOOST_AUTO_TEST_CASE (AnOpenedPolygonCannotBeEqualToAClosedOneEvenWithSameSetOfVertices)
 
 BOOST_AUTO_TEST_CASE (PolygonAreEqualAsLongAsTheyContainTheSameVerticesIrrespectiveOfOrder)
 
 BOOST_AUTO_TEST_CASE (ContainsThrowsIfCalledOnNonClosedPolygon)
 
 BOOST_AUTO_TEST_CASE (ContainsReturnsTrueIfPointIsInsidePolygon)
 
 BOOST_AUTO_TEST_CASE (ContainsReturnsFalseIfPointIsExactlyOnAPolygonEdge)
 
 BOOST_AUTO_TEST_CASE (BBoxCreation)
 
 BOOST_AUTO_TEST_CASE (PolygonCenter)
 
 BOOST_AUTO_TEST_CASE (ConstructionByVectorIterators)
 
 BOOST_AUTO_TEST_CASE (PointOutsidePolygonDistanceToPolygonClosestToOneSegment)
 
 BOOST_AUTO_TEST_CASE (PointOutsidePolygonDistanceToPolygonClosestToOneSegmentEndPoint)
 

Macro Definition Documentation

◆ BOOST_TEST_DYN_LINK

#define BOOST_TEST_DYN_LINK

Definition at line 17 of file Polygon.cxx.

◆ BOOST_TEST_MAIN

#define BOOST_TEST_MAIN

Definition at line 16 of file Polygon.cxx.

◆ BOOST_TEST_MODULE

#define BOOST_TEST_MODULE   Test MCHContour Polygon
Author
Laurent Aphecetche

Definition at line 15 of file Polygon.cxx.

Function Documentation

◆ BOOST_AUTO_TEST_CASE() [1/17]

BOOST_AUTO_TEST_CASE ( AClosePolygonIsAPolygonWhereLastVertexIsTheSameAsFirstOne  )

Definition at line 70 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [2/17]

BOOST_AUTO_TEST_CASE ( AnOpenedPolygonCannotBeEqualToAClosedOneEvenWithSameSetOfVertices  )

Definition at line 93 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [3/17]

BOOST_AUTO_TEST_CASE ( BBoxCreation  )

Definition at line 138 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [4/17]

BOOST_AUTO_TEST_CASE ( ClosePolygon  )

Definition at line 78 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [5/17]

BOOST_AUTO_TEST_CASE ( ClosingAClosedPolygonIsANop  )

Definition at line 76 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [6/17]

BOOST_AUTO_TEST_CASE ( ConstructionByVectorIterators  )

Definition at line 154 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [7/17]

BOOST_AUTO_TEST_CASE ( ContainsReturnsFalseIfPointIsExactlyOnAPolygonEdge  )

Definition at line 133 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [8/17]

BOOST_AUTO_TEST_CASE ( ContainsReturnsTrueIfPointIsInsidePolygon  )

Definition at line 127 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [9/17]

BOOST_AUTO_TEST_CASE ( ContainsThrowsIfCalledOnNonClosedPolygon  )

Definition at line 121 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [10/17]

BOOST_AUTO_TEST_CASE ( CreateClockwiseOrientedPolygon  )

Definition at line 66 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [11/17]

BOOST_AUTO_TEST_CASE ( CreateCounterClockwiseOrientedPolygon  )

Definition at line 61 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [12/17]

BOOST_AUTO_TEST_CASE ( PointOutsidePolygonDistanceToPolygonClosestToOneSegment  )

Definition at line 163 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [13/17]

BOOST_AUTO_TEST_CASE ( PointOutsidePolygonDistanceToPolygonClosestToOneSegmentEndPoint  )

Definition at line 169 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [14/17]

BOOST_AUTO_TEST_CASE ( PolygonAreEqualAsLongAsTheyContainTheSameVerticesIrrespectiveOfOrder  )

Definition at line 109 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [15/17]

BOOST_AUTO_TEST_CASE ( PolygonCenter  )

Definition at line 144 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [16/17]

BOOST_AUTO_TEST_CASE ( SignedArea  )

Definition at line 68 of file Polygon.cxx.

◆ BOOST_AUTO_TEST_CASE() [17/17]

BOOST_AUTO_TEST_CASE ( ThrowIfClosingAPolygonResultInANonManhattanPolygon  )

Definition at line 86 of file Polygon.cxx.