forked from AliceO2Group/AliceO2
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ALICE 3: Add ECal detector (AliceO2Group#12682)
* Resize Magnet accoding to SD * Add ECal as Pb Cylinder * Update GeometryTGeo.h
- Loading branch information
Showing
20 changed files
with
625 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# Copyright 2019-2020 CERN and copyright holders of ALICE O2. | ||
# See https://alice-o2.web.cern.ch/copyright for details of the copyright holders. | ||
# All rights not expressly granted are reserved. | ||
# | ||
# This software is distributed under the terms of the GNU General Public | ||
# License v3 (GPL Version 3), copied verbatim in the file "COPYING". | ||
# | ||
# In applying this license CERN does not waive the privileges and immunities | ||
# granted to it by virtue of its status as an Intergovernmental Organization | ||
# or submit itself to any jurisdiction. | ||
|
||
add_subdirectory(base) | ||
add_subdirectory(simulation) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<!-- doxy | ||
\page refDetectorsUpgradesALICE3TRK Tracker | ||
/doxy --> | ||
|
||
# ALICE 3 Electromagnetic Calorimenter | ||
|
||
This is top page for the ECL detector documentation. | ||
|
||
<!-- doxy | ||
/doxy --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# Copyright 2019-2020 CERN and copyright holders of ALICE O2. | ||
# See https://alice-o2.web.cern.ch/copyright for details of the copyright holders. | ||
# All rights not expressly granted are reserved. | ||
# | ||
# This software is distributed under the terms of the GNU General Public | ||
# License v3 (GPL Version 3), copied verbatim in the file "COPYING". | ||
# | ||
# In applying this license CERN does not waive the privileges and immunities | ||
# granted to it by virtue of its status as an Intergovernmental Organization | ||
# or submit itself to any jurisdiction. | ||
|
||
o2_add_library(ECalBase | ||
SOURCES src/GeometryTGeo.cxx | ||
src/ECalBaseParam.cxx | ||
PUBLIC_LINK_LIBRARIES O2::DetectorsBase) | ||
|
||
o2_target_root_dictionary(ECalBase | ||
HEADERS include/ECalBase/GeometryTGeo.h | ||
include/ECalBase/ECalBaseParam.h) |
33 changes: 33 additions & 0 deletions
33
Detectors/Upgrades/ALICE3/ECal/base/include/ECalBase/ECalBaseParam.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
// Copyright 2019-2020 CERN and copyright holders of ALICE O2. | ||
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders. | ||
// All rights not expressly granted are reserved. | ||
// | ||
// This software is distributed under the terms of the GNU General Public | ||
// License v3 (GPL Version 3), copied verbatim in the file "COPYING". | ||
// | ||
// In applying this license CERN does not waive the privileges and immunities | ||
// granted to it by virtue of its status as an Intergovernmental Organization | ||
// or submit itself to any jurisdiction. | ||
|
||
#ifndef O2_ECAL_BASEPARAM_H | ||
#define O2_ECAL_BASEPARAM_H | ||
|
||
#include "CommonUtils/ConfigurableParam.h" | ||
#include "CommonUtils/ConfigurableParamHelper.h" | ||
|
||
namespace o2 | ||
{ | ||
namespace ecal | ||
{ | ||
struct ECalBaseParam : public o2::conf::ConfigurableParamHelper<ECalBaseParam> { | ||
float rMin = 125.0; // cm | ||
float rMax = 155.0; // cm | ||
float zLength = 350.0; // cm | ||
|
||
O2ParamDef(ECalBaseParam, "ECalBase"); | ||
}; | ||
|
||
} // namespace ecal | ||
} // end namespace o2 | ||
|
||
#endif |
47 changes: 47 additions & 0 deletions
47
Detectors/Upgrades/ALICE3/ECal/base/include/ECalBase/GeometryTGeo.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
// Copyright 2019-2020 CERN and copyright holders of ALICE O2. | ||
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders. | ||
// All rights not expressly granted are reserved. | ||
// | ||
// This software is distributed under the terms of the GNU General Public | ||
// License v3 (GPL Version 3), copied verbatim in the file "COPYING". | ||
// | ||
// In applying this license CERN does not waive the privileges and immunities | ||
// granted to it by virtue of its status as an Intergovernmental Organization | ||
// or submit itself to any jurisdiction. | ||
|
||
#ifndef ALICEO2_ECAL_GEOMETRYTGEO_H | ||
#define ALICEO2_ECAL_GEOMETRYTGEO_H | ||
|
||
#include <DetectorsCommonDataFormats/DetMatrixCache.h> | ||
|
||
namespace o2 | ||
{ | ||
namespace ecal | ||
{ | ||
class GeometryTGeo : public o2::detectors::DetMatrixCache | ||
{ | ||
public: | ||
GeometryTGeo(bool build = false, int loadTrans = 0); | ||
void Build(int loadTrans); | ||
void fillMatrixCache(int mask); | ||
static GeometryTGeo* Instance(); | ||
|
||
static const char* getECalVolPattern() { return sVolumeName.c_str(); } | ||
static const char* getECalSensorPattern() { return sSensorName.c_str(); } | ||
|
||
static const char* composeSymNameECal() | ||
{ | ||
return Form("%s_%d", o2::detectors::DetID(o2::detectors::DetID::ECL).getName(), 0); | ||
} | ||
static const char* composeSymNameSensor(); // A single sensor for the moment | ||
|
||
protected: | ||
static std::string sVolumeName; | ||
static std::string sSensorName; | ||
|
||
private: | ||
static std::unique_ptr<o2::ecal::GeometryTGeo> sInstance; | ||
}; | ||
} // namespace ecal | ||
} // namespace o2 | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
// Copyright 2019-2020 CERN and copyright holders of ALICE O2. | ||
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders. | ||
// All rights not expressly granted are reserved. | ||
// | ||
// This software is distributed under the terms of the GNU General Public | ||
// License v3 (GPL Version 3), copied verbatim in the file "COPYING". | ||
// | ||
// In applying this license CERN does not waive the privileges and immunities | ||
// granted to it by virtue of its status as an Intergovernmental Organization | ||
// or submit itself to any jurisdiction. | ||
|
||
#ifdef __CLING__ | ||
|
||
#pragma link off all globals; | ||
#pragma link off all classes; | ||
#pragma link off all functions; | ||
|
||
#pragma link C++ class o2::ecal::GeometryTGeo + | ||
#pragma link C++ class o2::ecal::ECalBaseParam + ; | ||
#pragma link C++ class o2::conf::ConfigurableParamHelper < o2::ecal::ECalBaseParam> + ; | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// Copyright 2019-2020 CERN and copyright holders of ALICE O2. | ||
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders. | ||
// All rights not expressly granted are reserved. | ||
// | ||
// This software is distributed under the terms of the GNU General Public | ||
// License v3 (GPL Version 3), copied verbatim in the file "COPYING". | ||
// | ||
// In applying this license CERN does not waive the privileges and immunities | ||
// granted to it by virtue of its status as an Intergovernmental Organization | ||
// or submit itself to any jurisdiction. | ||
|
||
#include "ECalBase/ECalBaseParam.h" | ||
|
||
O2ParamImpl(o2::ecal::ECalBaseParam); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
// Copyright 2019-2020 CERN and copyright holders of ALICE O2. | ||
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders. | ||
// All rights not expressly granted are reserved. | ||
// | ||
// This software is distributed under the terms of the GNU General Public | ||
// License v3 (GPL Version 3), copied verbatim in the file "COPYING". | ||
// | ||
// In applying this license CERN does not waive the privileges and immunities | ||
// granted to it by virtue of its status as an Intergovernmental Organization | ||
// or submit itself to any jurisdiction. | ||
|
||
#include <ECalBase/GeometryTGeo.h> | ||
#include <TGeoManager.h> | ||
|
||
namespace o2 | ||
{ | ||
namespace ecal | ||
{ | ||
std::unique_ptr<o2::ecal::GeometryTGeo> GeometryTGeo::sInstance; | ||
|
||
std::string GeometryTGeo::sVolumeName = "ECALV"; | ||
std::string GeometryTGeo::sSensorName = "ECALSensor"; | ||
|
||
GeometryTGeo::GeometryTGeo(bool build, int loadTrans) : DetMatrixCache() | ||
{ | ||
if (sInstance) { | ||
LOGP(fatal, "Invalid use of public constructor: o2::ecal::GeometryTGeo instance exists"); | ||
} | ||
if (build) { | ||
Build(loadTrans); | ||
} | ||
} | ||
|
||
void GeometryTGeo::Build(int loadTrans) | ||
{ | ||
if (isBuilt()) { | ||
LOGP(warning, "Already built"); | ||
return; // already initialized | ||
} | ||
|
||
if (!gGeoManager) { | ||
LOGP(fatal, "Geometry is not loaded"); | ||
} | ||
|
||
fillMatrixCache(loadTrans); | ||
} | ||
|
||
void GeometryTGeo::fillMatrixCache(int mask) | ||
{ | ||
} | ||
|
||
GeometryTGeo* GeometryTGeo::Instance() | ||
{ | ||
if (!sInstance) { | ||
sInstance = std::unique_ptr<GeometryTGeo>(new GeometryTGeo(true, 0)); | ||
} | ||
return sInstance.get(); | ||
} | ||
|
||
const char* GeometryTGeo::composeSymNameSensor() | ||
{ | ||
return Form("%s/%d", composeSymNameECal(), 0); | ||
} | ||
|
||
} // namespace ecal | ||
} // namespace o2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# Copyright 2019-2020 CERN and copyright holders of ALICE O2. | ||
# See https://alice-o2.web.cern.ch/copyright for details of the copyright holders. | ||
# All rights not expressly granted are reserved. | ||
# | ||
# This software is distributed under the terms of the GNU General Public | ||
# License v3 (GPL Version 3), copied verbatim in the file "COPYING". | ||
# | ||
# In applying this license CERN does not waive the privileges and immunities | ||
# granted to it by virtue of its status as an Intergovernmental Organization | ||
# or submit itself to any jurisdiction. | ||
|
||
o2_add_library(ECalSimulation | ||
SOURCES src/Detector.cxx | ||
PUBLIC_LINK_LIBRARIES O2::ECalBase | ||
O2::ITSMFTSimulation) | ||
|
||
o2_target_root_dictionary(ECalSimulation | ||
HEADERS include/ECalSimulation/Detector.h) |
Oops, something went wrong.