OpenWalnut
1.5.0dev
|
Unit tests wmath's helper functions. More...
#include <WMath_test.h>
Public Member Functions | |
void | testTrianglePlaneIntersectionWithPointsInPlane (void) |
If some points are inside the plane the triangle is considered to intersect with that plane. More... | |
void | testTrianglePlaneIntersectionWithNoPointInPlane (void) |
If no point is in plane but at not all are on one side the trinagle intersects. More... | |
void | testTrianglePlaneIntersectionWithAllPointsOnOneSide (void) |
If all point are on one side of the plane no intersection can take place. More... | |
void | testIntersectionOfPlaneWithSegment (void) |
The intersection of a plane plane with a segment, having a starting and an endpoint. More... | |
void | testNoIntersectionOfPlaneWithSegment (void) |
If there is no intersection at all the position 0,0,0 should be written into the point of intersection and false should be returned. More... | |
void | testIntersectionOfPlaneWithSegmentHavingOnePointInPlane (void) |
If an endpoint is inside of the plane then a point of intersection must exists and true must be returned. More... | |
void | testIntersectionOfPlaneWithSegmentInPlane (void) |
If the segment is totally inside of the plane, the first point must be returned which is actually one (of many intersecting points) intersecting point and true must be returned. More... | |
void | testIntersectionOfPlaneWithLine (void) |
If a set of consecutive segements (aka line) is tested again intersection with that plane, each segment should be tested. More... | |
void | testNoIntersectionOfPlaneWithLine (void) |
If none of the segments of the line intersects with the plane, false and 0,0,0 should be returned. More... | |
void | testIntersectionPlaneLineWithJustOnePoint (void) |
If an endpoint of a line intersects with the plane, this point should be returned and ofcourse true. More... | |
void | testIntersectionPlaneLineWithSegmentInPlane (void) |
If a whole segment of the line is insisde that plane the first point should be returned along with true as return code. More... | |
void | testMultipleIntersectionPlaneLine (void) |
If many points of intersection occurs the closest to the base point should be selected and return true. More... | |
void | testFactorials (void) |
Test the factorial calculation. More... | |
void | testAreEqual (void) |
Test the areEqual function. More... | |
Unit tests wmath's helper functions.
Definition at line 41 of file WMath_test.h.
|
inline |
Test the areEqual function.
Definition at line 273 of file WMath_test.h.
|
inline |
Test the factorial calculation.
Definition at line 256 of file WMath_test.h.
|
inline |
If a set of consecutive segements (aka line) is tested again intersection with that plane, each segment should be tested.
Definition at line 147 of file WMath_test.h.
References wlimits::DBL_EPS, and WMixinVector< ValueT >::push_back().
|
inline |
The intersection of a plane plane with a segment, having a starting and an endpoint.
It should be a commutative operation in terms of staring and ending points.
Definition at line 79 of file WMath_test.h.
|
inline |
If an endpoint is inside of the plane then a point of intersection must exists and true must be returned.
Definition at line 110 of file WMath_test.h.
References wlimits::DBL_EPS.
|
inline |
If the segment is totally inside of the plane, the first point must be returned which is actually one (of many intersecting points) intersecting point and true must be returned.
Definition at line 131 of file WMath_test.h.
|
inline |
If an endpoint of a line intersects with the plane, this point should be returned and ofcourse true.
Definition at line 189 of file WMath_test.h.
References wlimits::DBL_EPS, and WMixinVector< ValueT >::push_back().
|
inline |
If a whole segment of the line is insisde that plane the first point should be returned along with true as return code.
Definition at line 210 of file WMath_test.h.
References wlimits::DBL_EPS, and WMixinVector< ValueT >::push_back().
|
inline |
If many points of intersection occurs the closest to the base point should be selected and return true.
Definition at line 231 of file WMath_test.h.
References wlimits::DBL_EPS, and WMixinVector< ValueT >::push_back().
|
inline |
If none of the segments of the line intersects with the plane, false and 0,0,0 should be returned.
Definition at line 168 of file WMath_test.h.
References WMixinVector< ValueT >::push_back().
|
inline |
If there is no intersection at all the position 0,0,0 should be written into the point of intersection and false should be returned.
Definition at line 95 of file WMath_test.h.
References wlimits::DBL_EPS.
|
inline |
If all point are on one side of the plane no intersection can take place.
Definition at line 67 of file WMath_test.h.
|
inline |
If no point is in plane but at not all are on one side the trinagle intersects.
Definition at line 58 of file WMath_test.h.
|
inline |
If some points are inside the plane the triangle is considered to intersect with that plane.
Definition at line 47 of file WMath_test.h.