ATLAS Offline Software
BCMPrimeGmxInterface.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #include "BCMPrimeGmxInterface.h"
6 
9 
10 namespace InDetDD
11 {
12 
14  : AthMessaging("BCMPrimeGmxInterface"),
15  m_detectorManager(detectorManager)
16 {}
17 
18 int BCMPrimeGmxInterface::sensorId(std::map<std::string, int> &index) const
19 {
20  // Return the Simulation HitID (nothing to do with "ATLAS Identifiers" aka "Offline Identifiers")
21  int hitIdOfModule = SiHitIdHelper::GetHelper()->buildHitId(0, 0, index["diamond_number"], index["module_number"], 0, 0);
22 
23  ATH_MSG_DEBUG("Index list: " << index["diamond_number"] << " " << index["module_number"]);
24  ATH_MSG_DEBUG("hitIdOfModule = " << std::hex << hitIdOfModule << std::dec);
25  ATH_MSG_DEBUG(" dia = " << SiHitIdHelper::GetHelper()->getLayerDisk(hitIdOfModule) <<
26  " mod = " << SiHitIdHelper::GetHelper()->getEtaModule(hitIdOfModule));
27  return hitIdOfModule;
28 }
29 
30 void BCMPrimeGmxInterface::addAlignable(int /*level*/, std::map<std::string, int> &index,
31  GeoVFullPhysVol *fpv, GeoAlignableTransform *transform)
32 {
33  ATH_MSG_DEBUG("alignable transform added for indices: " << index["diamond_number"] << " " << index["module_number"]);
34 
35  // A preliminary id scheme
36  int id = index["diamond_number"] + 8*index["module_number"];
37 
39 }
40 
41 } // namespace InDetDD
InDetDD::BCMPrimeGmxInterface::addAlignable
virtual void addAlignable(int level, std::map< std::string, int > &index, GeoVFullPhysVol *fpv, GeoAlignableTransform *transform) override final
Definition: BCMPrimeGmxInterface.cxx:30
InDetDD::BCMPrimeGmxInterface::BCMPrimeGmxInterface
BCMPrimeGmxInterface(BCMPrimeDetectorManager *detectorManager)
Definition: BCMPrimeGmxInterface.cxx:13
index
Definition: index.py:1
BCMPrimeDetectorManager.h
InDetDD::BCMPrimeDetectorManager
Definition: BCMPrimeDetectorManager.h:31
InDetDD::BCMPrimeDetectorManager::addAlignableTransform
void addAlignableTransform(int, GeoAlignableTransform *, const GeoVPhysVol *)
Definition: BCMPrimeDetectorManager.cxx:27
SiHitIdHelper.h
BCMPrimeGmxInterface.h
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
Amg::transform
Amg::Vector3D transform(Amg::Vector3D &v, Amg::Transform3D &tr)
Transform a point from a Trasformation3D.
Definition: GeoPrimitivesHelpers.h:156
AthMessaging
Class to provide easy MsgStream access and capabilities.
Definition: AthMessaging.h:55
InDetDD::BCMPrimeGmxInterface::m_detectorManager
BCMPrimeDetectorManager * m_detectorManager
Definition: BCMPrimeGmxInterface.h:30
InDetDD::BCMPrimeGmxInterface::sensorId
virtual int sensorId(std::map< std::string, int > &index) const override final
Definition: BCMPrimeGmxInterface.cxx:18
InDetDD
Message Stream Member.
Definition: FakeTrackBuilder.h:8
SiHitIdHelper::GetHelper
static const SiHitIdHelper * GetHelper()
Definition: SiHitIdHelper.cxx:19
SiHitIdHelper::buildHitId
int buildHitId(const int, const int, const int, const int, const int, const int) const
Definition: SiHitIdHelper.cxx:118