File indexing completed on 2024-04-06 12:14:37
0001 #ifndef GEOMETRY_ECALGEOMETRYLOADER_H
0002 #define GEOMETRY_ECALGEOMETRYLOADER_H 1
0003
0004 #include "DetectorDescription/Core/interface/DDSolid.h"
0005 #include "Geometry/CaloGeometry/interface/CaloSubdetectorGeometry.h"
0006 #include "DetectorDescription/Core/interface/DDFilteredView.h"
0007 #include "CondFormats/Alignment/interface/Alignments.h"
0008
0009 #include "CLHEP/Geometry/Transform3D.h"
0010 #include <memory>
0011 #include <vector>
0012
0013
0014
0015
0016
0017
0018
0019 class DDCompactView;
0020
0021 template <class T>
0022 class CaloGeometryLoaderTest {
0023 public:
0024 typedef std::vector<double> ParmVec;
0025
0026 using PtrType = std::unique_ptr<CaloSubdetectorGeometry>;
0027
0028 typedef CaloSubdetectorGeometry::ParVec ParVec;
0029 typedef CaloSubdetectorGeometry::ParVecVec ParVecVec;
0030
0031 static const double k_ScaleFromDDDtoGeant;
0032
0033 CaloGeometryLoaderTest();
0034
0035 virtual ~CaloGeometryLoaderTest() {}
0036
0037 PtrType load(const DDCompactView* cpv, const Alignments* alignments = nullptr, const Alignments* globals = nullptr);
0038
0039 private:
0040 void makeGeometry(const DDCompactView* cpv, T* geom, const Alignments* alignments, const Alignments* globals);
0041
0042 void fillNamedParams(DDFilteredView fv, T* geom);
0043
0044 void fillGeom(T* geom, const ParmVec& pv, const HepGeom::Transform3D& tr, const DetId& id);
0045
0046 void myFillGeom(T* geom, const ParmVec& pv, const HepGeom::Transform3D& tr, const unsigned int id);
0047
0048 unsigned int getDetIdForDDDNode(const DDFilteredView& fv);
0049
0050 typename T::NumberingScheme m_scheme;
0051 DDSpecificsFilter m_filter;
0052 };
0053
0054 #endif