Project
Loading...
Searching...
No Matches
Transformations.h
Go to the documentation of this file.
1// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3// All rights not expressly granted are reserved.
4//
5// This software is distributed under the terms of the GNU General Public
6// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7//
8// In applying this license CERN does not waive the privileges and immunities
9// granted to it by virtue of its status as an Intergovernmental Organization
10// or submit itself to any jurisdiction.
12
13#ifndef O2_MCH_GEOMETRY_TRANSFORMER_TRANSFORMATIONS_H
14#define O2_MCH_GEOMETRY_TRANSFORMER_TRANSFORMATIONS_H
15
16#include "MathUtils/Cartesian.h"
17#include <array>
18#include <tuple>
19#include <gsl/span>
20#include <functional>
21
22class TGeoManager;
23
24namespace o2::mch::geo
25{
26
39using TransformationCreator = std::function<o2::math_utils::Transform3D(int detElemId)>;
40
46
48
51extern std::array<int, 156> allDeIds;
52
62std::array<double, 9> angles2matrix(double yaw, double pitch, double roll);
63
71std::tuple<double, double, double> matrix2angles(gsl::span<double> rot);
72} // namespace o2::mch::geo
73
74#endif
get the local-to-global transformation for a given detection element
Definition Geometry.h:25
TransformationCreator transformationFromJSON(std::istream &in)
std::tuple< double, double, double > matrix2angles(gsl::span< double > rot)
std::array< int, 156 > allDeIds
std::array< double, 9 > angles2matrix(double yaw, double pitch, double roll)
TransformationCreator transformationFromTGeoManager(const TGeoManager &geo)
std::function< o2::math_utils::Transform3D(int detElemId)> TransformationCreator