diff --git a/Tracking/TrkEvent/TrkCaloClusterROI/CMakeLists.txt b/Tracking/TrkEvent/TrkCaloClusterROI/CMakeLists.txt new file mode 100644 index 0000000000000000000000000000000000000000..bbacb6928b0bfa02cfe747515d75f0c35bc96f92 --- /dev/null +++ b/Tracking/TrkEvent/TrkCaloClusterROI/CMakeLists.txt @@ -0,0 +1,31 @@ +################################################################################ +# Package: TrkCaloClusterROI +################################################################################ + +# Declare the package name: +atlas_subdir( TrkCaloClusterROI ) + +# Declare the package's dependencies: +atlas_depends_on_subdirs( PUBLIC + Control/CLIDSvc + Control/DataModel + Control/SGTools + DetectorDescription/GeoPrimitives + Event/EventPrimitives + PRIVATE + Tracking/TrkDetDescr/TrkSurfaces + Tracking/TrkEvent/TrkEventPrimitives ) + +# External dependencies: +find_package( Eigen ) +find_package( ROOT COMPONENTS Core Tree MathCore Hist RIO pthread ) + +# Component(s) in the package: +atlas_add_library( TrkCaloClusterROI + src/*.cxx + PUBLIC_HEADERS TrkCaloClusterROI + INCLUDE_DIRS ${EIGEN_INCLUDE_DIRS} + PRIVATE_INCLUDE_DIRS ${ROOT_INCLUDE_DIRS} + LINK_LIBRARIES ${EIGEN_LIBRARIES} DataModel SGTools GeoPrimitives EventPrimitives + PRIVATE_LINK_LIBRARIES ${ROOT_LIBRARIES} TrkSurfaces TrkEventPrimitives ) + diff --git a/Tracking/TrkEvent/TrkCaloClusterROI/src/CaloClusterROI.cxx b/Tracking/TrkEvent/TrkCaloClusterROI/src/CaloClusterROI.cxx index 44a3f211d5ea1df60dc6ba2f7f32717023606990..952b0d81f97922e3708c0d5a5c6a7cc139821e77 100644 --- a/Tracking/TrkEvent/TrkCaloClusterROI/src/CaloClusterROI.cxx +++ b/Tracking/TrkEvent/TrkCaloClusterROI/src/CaloClusterROI.cxx @@ -20,7 +20,7 @@ Trk::CaloClusterROI::CaloClusterROI( const Trk::LocalParameters* locpars, double widtheta) : m_localParams(locpars), - m_globalpos(0), + m_globalpos(nullptr), m_energy( energy ), m_phiWidth( widthphi ), m_etaWidth( widtheta ) @@ -39,9 +39,12 @@ Trk::CaloClusterROI::~CaloClusterROI() // default constructor: Trk::CaloClusterROI::CaloClusterROI() : - m_localParams(0), - m_surface(0), - m_globalpos(0) + m_localParams(nullptr), + m_surface(nullptr), + m_globalpos(nullptr), + m_energy(0.0), + m_phiWidth(0.0), + m_etaWidth(0.0) { } @@ -49,7 +52,10 @@ Trk::CaloClusterROI::CaloClusterROI() : Trk::CaloClusterROI::CaloClusterROI( const Trk::CaloClusterROI& cot) : m_localParams( new Trk::LocalParameters(*cot.m_localParams) ), m_surface( cot.m_surface? (cot.m_surface->isFree() ? cot.m_surface->clone():cot.m_surface) : 0), - m_globalpos( new Amg::Vector3D(*cot.m_globalpos) ) + m_globalpos( new Amg::Vector3D(*cot.m_globalpos) ), + m_energy(cot.m_energy), + m_phiWidth(cot.m_phiWidth), + m_etaWidth(cot.m_etaWidth) { } @@ -69,6 +75,9 @@ Trk::CaloClusterROI& Trk::CaloClusterROI::operator=(const Trk::CaloClusterROI& c m_localParams = new Trk::LocalParameters(*cot.m_localParams); m_surface = (cot.m_surface? (cot.m_surface->isFree() ? cot.m_surface->clone():cot.m_surface) : 0); m_globalpos = new Amg::Vector3D(*cot.m_globalpos); + m_energy=cot.m_energy; + m_phiWidth=cot.m_phiWidth; + m_etaWidth=cot.m_etaWidth; } return *this; }