CMS 3D CMS Logo

CaloGeometryLoader.h
Go to the documentation of this file.
1 #ifndef GEOMETRY_ECALGEOMETRYLOADER_H
2 #define GEOMETRY_ECALGEOMETRYLOADER_H
3 
10 
11 #include "CLHEP/Geometry/Transform3D.h"
12 #include <string>
13 #include <vector>
14 
20 template <class T>
22 public:
23  using ParmVec = std::vector<double>;
24  using PtrType = std::unique_ptr<CaloSubdetectorGeometry>;
27 
28  static constexpr double k_ScaleFromDDDtoGeant = 0.1;
29  static constexpr double k_ScaleFromDD4HeptoGeant = 1.0;
30 
32 
33  virtual ~CaloGeometryLoader<T>() = default;
34 
35  PtrType load(const DDCompactView* cpv, const Alignments* alignments = nullptr, const Alignments* globals = nullptr);
36  PtrType load(const cms::DDCompactView* cpv,
37  const Alignments* alignments = nullptr,
38  const Alignments* globals = nullptr);
39 
40 private:
41  void makeGeometry(const DDCompactView* cpv, T* geom, const Alignments* alignments, const Alignments* globals);
42  void makeGeometry(const cms::DDCompactView* cpv, T* geom, const Alignments* alignments, const Alignments* globals);
43 
44  void fillNamedParams(const DDFilteredView& fv, T* geom);
45  void fillNamedParams(const cms::DDFilteredView& fv, T* geom);
46 
47  void fillGeom(T* geom, const ParmVec& pv, const HepGeom::Transform3D& tr, const DetId& id, const double& scale);
48 
49  unsigned int getDetIdForDDDNode(const DDFilteredView& fv);
50  unsigned int getDetIdForDD4HepNode(const cms::DDFilteredView& fv);
51 
52  typename T::NumberingScheme m_scheme;
53 };
54 
55 #endif
CaloGeometryLoader::makeGeometry
void makeGeometry(const DDCompactView *cpv, T *geom, const Alignments *alignments, const Alignments *globals)
Alignments.h
cms::DDFilteredView
Definition: DDFilteredView.h:65
CaloGeometryLoader::m_scheme
T::NumberingScheme m_scheme
Definition: CaloGeometryLoader.h:52
EZArrayFL
Definition: EZArrayFL.h:20
CaloGeometryLoader
Definition: CaloGeometryLoader.h:21
DDCompactView.h
ParmVec
std::vector< float > ParmVec
Definition: FastTimeGeometry.cc:13
DetId
Definition: DetId.h:17
DDFilteredView.h
CaloGeometryLoader::load
PtrType load(const DDCompactView *cpv, const Alignments *alignments=nullptr, const Alignments *globals=nullptr)
CaloGeometryLoader::k_ScaleFromDDDtoGeant
static constexpr double k_ScaleFromDDDtoGeant
Definition: CaloGeometryLoader.h:28
DDCompactView
Compact representation of the geometrical detector hierarchy.
Definition: DDCompactView.h:80
relativeConstraints.geom
geom
Definition: relativeConstraints.py:72
DDFilteredView.h
DDCompactView.h
Scenarios_cff.scale
scale
Definition: Scenarios_cff.py:2186
CaloSubdetectorGeometry::ParVec
CaloCellGeometry::ParVec ParVec
Definition: CaloSubdetectorGeometry.h:30
CaloSubdetectorGeometry.h
CaloGeometryLoader::PtrType
std::unique_ptr< CaloSubdetectorGeometry > PtrType
Definition: CaloGeometryLoader.h:24
MetAnalyzer.pv
def pv(vc)
Definition: MetAnalyzer.py:7
CaloGeometryLoader::getDetIdForDD4HepNode
unsigned int getDetIdForDD4HepNode(const cms::DDFilteredView &fv)
CaloGeometryLoader::fillGeom
void fillGeom(T *geom, const ParmVec &pv, const HepGeom::Transform3D &tr, const DetId &id, const double &scale)
CaloSubdetectorGeometry::ParVecVec
CaloCellGeometry::ParVecVec ParVecVec
Definition: CaloSubdetectorGeometry.h:31
T
long double T
Definition: Basic3DVectorLD.h:48
CaloGeometryLoader::ParmVec
std::vector< double > ParmVec
Definition: CaloGeometryLoader.h:23
cms::DDCompactView
Definition: DDCompactView.h:29
CaloGeometryLoader::ParVecVec
CaloSubdetectorGeometry::ParVecVec ParVecVec
Definition: CaloGeometryLoader.h:26
CaloGeometryLoader< T >
CaloGeometryLoader::fillNamedParams
void fillNamedParams(const DDFilteredView &fv, T *geom)
DDFilteredView
Definition: DDFilteredView.h:20
CaloGeometryLoader::k_ScaleFromDD4HeptoGeant
static constexpr double k_ScaleFromDD4HeptoGeant
Definition: CaloGeometryLoader.h:29
CaloGeometryLoader::getDetIdForDDDNode
unsigned int getDetIdForDDDNode(const DDFilteredView &fv)
Alignments
Definition: Alignments.h:10