All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GeoVectorLocalTransformation.h
Go to the documentation of this file.
1 /**
2  * @file larcorealg/Geometry/GeoVectorLocalTransformation.h
3  * @brief Specialization of local-to-world transformations for ROOT GenVector.
4  * @author Gianluca Petrillo (petrillo@slac.stanford.edu)
5  * @date January 31, 2019
6  * @ingroup Geometry
7  *
8  * This is a header-only library.
9  */
10 
11 #ifndef LARCOREALG_GEOMETRY_GEOVECTORLOCALTRANSFORMATION_H
12 #define LARCOREALG_GEOMETRY_GEOVECTORLOCALTRANSFORMATION_H
13 
14 // LArSoft libraries
16 
17 // ROOT libraries
18 #include "Math/GenVector/Transform3D.h"
19 
20 // C/C++ standard libraries
21 #include <stddef.h>
22 #include <vector>
23 
24 // ROOT forward declaration (should be redundant)
25 class TGeoNode;
26 
27 namespace geo {
28 
29  //----------------------------------------------------------------------------
30  //--- template specialization forward declarations
31  //----------------------------------------------------------------------------
32  //--- LocalTransformation<ROOT::Math::Transform3D>
33  //----------------------------------------------------------------------------
34  template <>
36  (double const* local, double* world) const;
37 
38  //------------------------------------------------------------------------------
39  template <>
41  (double const* local, double* world) const;
42 
43  //------------------------------------------------------------------------------
44  template <>
46  (double const* world, double* local) const;
47 
48  //------------------------------------------------------------------------------
49  template <>
51  (const double* world, double* local) const;
52 
53  //------------------------------------------------------------------------------
54  template <>
55  template <typename DestPoint, typename SrcPoint>
56  DestPoint
58  (SrcPoint const& world) const;
59 
60  //......................................................................
61  template <>
62  template <typename DestVector, typename SrcVector>
63  DestVector
65  (SrcVector const& world) const;
66 
67  //......................................................................
68  template <>
69  template <typename DestPoint, typename SrcPoint>
70  DestPoint
72  (SrcPoint const& local) const;
73 
74  //......................................................................
75  template <>
76  template <typename DestVector, typename SrcVector>
77  DestVector
79  (SrcVector const& local) const;
80 
81  //------------------------------------------------------------------------------
82 
83 } // namespace geo
84 
85 
86 //------------------------------------------------------------------------------
87 // template implementation
88 
89 #include "GeoVectorLocalTransformation.tcc"
90 
91 //------------------------------------------------------------------------------
92 
93 
94 #endif // LARCOREALG_GEOMETRY_GEOVECTORLOCALTRANSFORMATION_H
DestPoint WorldToLocalImpl(SrcPoint const &world) const
void LocalToWorld(double const *local, double *world) const
Transforms a point from local frame to world frame.
void LocalToWorldVect(double const *local, double *world) const
Transforms a vector from local frame to world frame.
Class containing local-to-world transformations.
then local
DestVector LocalToWorldVectImpl(SrcVector const &local) const
void WorldToLocal(double const *world, double *local) const
Transforms a point from world frame to local frame.
DestVector WorldToLocalVectImpl(SrcVector const &world) const
void WorldToLocalVect(const double *world, double *local) const
Transforms a vector from world frame to local frame.
DestPoint LocalToWorldImpl(SrcPoint const &local) const