2 #include <utl/CoordinateSystem.h>
3 #include <utl/GeometryUtilities.h>
5 #include <utl/MathConstants.h>
8 #include <cppunit/extensions/HelperMacros.h>
16 #define TEST(x...) CPPUNIT_ASSERT(Test x)
30 CPPUNIT_TEST(testNormalizeAngleMinusPiPi);
31 CPPUNIT_TEST(testPlaneCtor);
32 CPPUNIT_TEST(testLineCtor);
33 CPPUNIT_TEST(testLineLineDistance);
34 CPPUNIT_TEST(testLinePointDistance);
35 CPPUNIT_TEST(testPlanePointDistance);
36 CPPUNIT_TEST(testPlanePlaneIntersection1);
37 CPPUNIT_TEST(testPlanePlaneIntersection2);
38 CPPUNIT_TEST(testPlanePlaneIntersection3);
39 CPPUNIT_TEST(testLinePlaneIntersection1);
40 CPPUNIT_TEST(testPerpendicularProjection);
41 CPPUNIT_TEST_SUITE_END();
55 TEST(<
CloseTo>(dir.GetCoordinates(fCS), resDirection.GetCoordinates(fCS)));
56 TEST(<
CloseTo>(anch.GetCoordinates(fCS), resAnchor.GetCoordinates(fCS)));
61 const Point& resPoint)
67 TEST(<
CloseTo>(point.GetCoordinates(fCS), resPoint.GetCoordinates(fCS)));
72 const Point& resPoint)
83 void setUp() { fCS = CoordinateSystem::GetRootCoordinateSystem(); }
182 Point(1.5,1.5,1, fCS));
double Plane(const utl::Point &point, const utl::Vector &normal, const utl::Photon &photonIn, utl::Photon &photonOut)
double NormalizeAngleMinusPiPi(const double x)
Normalize angle to lie between -pi and pi (-180 and 180 deg)
void testPlanePlaneIntersection2()
void testLineLineDistance()
void testNormalizeAngleMinusPiPi()
const Point & GetAnchor() const
void testPlanePlaneIntersection3()
CPPUNIT_TEST_SUITE_REGISTRATION(testAiresShowerFile)
Line Intersection(const Plane &p1, const Plane &p2)
boost::shared_ptr< const CoordinateTransformer > CoordinateSystemPtr
Shared pointer for coordinate systems.
boost::tuple< double, double, double > Triple
Coordinate triple for easy getting or setting of coordinates.
Class describing a Plane object.
void testLinePlaneIntersection1()
void CheckProjection(const Plane &plane, const Point &point, const Point &resPoint) const
double Distance(const Point &p, const sdet::Station &s)
void testPlanePlaneIntersection1()
void testLinePointDistance()
void testPlanePointDistance()
void CheckIntersection(const Plane &plane1, const Plane &plane2, const Vector &resDirection, const Point &resAnchor) const
const Vector & GetDirection() const
const Point & GetAnchor() const
const Vector & GetNormal() const
void testPerpendicularProjection()
Point PerpendicularProjection(const Point &point, const Plane &plane)
void CheckIntersection(const Plane &plane, const Line &line, const Point &resPoint) const
Predicate for approximate equality (for floating point)