ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
|
This class builds a box detector with a configurable amount of surfaces in it. The idea is to allow a quick configuration of a detector for mostly unit test applications. Therefore this class does not demand to be a universal construction factory but a raw first draft of the idea of factory that may be extended in the future. More...
#include <acts/blob/master/Core/include/Acts/Geometry/CuboidVolumeBuilder.hpp>
Classes | |
struct | Config |
This struct stores the configuration of the tracking geometry. More... | |
struct | LayerConfig |
This struct stores the data for the construction of a PlaneLayer that has a single PlaneSurface encapsulated. More... | |
struct | SurfaceConfig |
This struct stores the data for the construction of a single PlaneSurface. More... | |
struct | VolumeConfig |
This struct stores the data for the construction of a cuboid TrackingVolume with a given number of PlaneLayers. More... | |
Public Member Functions | |
CuboidVolumeBuilder ()=default | |
Default constructor without a configuration. | |
CuboidVolumeBuilder (Config &cfg) | |
Constructor that sets the config. | |
void | setConfig (Config &cfg) |
Setter of the config. | |
std::shared_ptr< const PlaneSurface > | buildSurface (const GeometryContext &gctx, const SurfaceConfig &cfg) const |
This function creates a surface with a given configuration. A detector element is attached if the template parameter is non-void. | |
std::shared_ptr< const Layer > | buildLayer (const GeometryContext &gctx, LayerConfig &cfg) const |
This function creates a layer with a surface encaspulated with a given configuration. The surface gets a detector element attached if the template parameter is non-void. | |
std::shared_ptr< TrackingVolume > | buildVolume (const GeometryContext &gctx, VolumeConfig &cfg) const |
This function creates a TrackingVolume with a configurable number of layers and surfaces. Each surface gets a detector element attached if the template parameter is non-void. | |
std::pair< double, double > | binningRange (const GeometryContext &gctx, const VolumeConfig &cfg) const |
This function evaluates the minimum and maximum of the binning as given by the configurations of the surfaces and layers. The ordering depends on the binning value specified in the configuration of the volume. | |
void | sortVolumes (std::vector< std::pair< TrackingVolumePtr, Vector3D >> &tapVec, BinningValue bValue) const |
std::shared_ptr< TrackingVolume > | trackingVolume (const GeometryContext &gctx, std::shared_ptr< const TrackingVolume >, std::shared_ptr< const VolumeBounds >) const override |
This function builds a world TrackingVolume based on a given configuration. | |
Public Member Functions inherited from Acts::ITrackingVolumeBuilder | |
virtual | ~ITrackingVolumeBuilder ()=default |
Virtual destructor. | |
virtual MutableTrackingVolumePtr | trackingVolume (const GeometryContext &gctx, TrackingVolumePtr insideVolume=nullptr, VolumeBoundsPtr outsideBounds=nullptr) const =0 |
Private Attributes | |
Config | m_cfg |
Configuration of the world volume. | |
This class builds a box detector with a configurable amount of surfaces in it. The idea is to allow a quick configuration of a detector for mostly unit test applications. Therefore this class does not demand to be a universal construction factory but a raw first draft of the idea of factory that may be extended in the future.
Definition at line 34 of file CuboidVolumeBuilder.hpp.
View newest version in sPHENIX GitHub at line 34 of file CuboidVolumeBuilder.hpp
|
default |
Default constructor without a configuration.
|
inline |
Constructor that sets the config.
[in] | cfg | Configuration of the detector |
Definition at line 109 of file CuboidVolumeBuilder.hpp.
View newest version in sPHENIX GitHub at line 109 of file CuboidVolumeBuilder.hpp
std::pair< double, double > Acts::CuboidVolumeBuilder::binningRange | ( | const GeometryContext & | gctx, |
const VolumeConfig & | cfg | ||
) | const |
This function evaluates the minimum and maximum of the binning as given by the configurations of the surfaces and layers. The ordering depends on the binning value specified in the configuration of the volume.
[in] | gctx | the geometry context for this building |
[in] | cfg | Container with the given surfaces and layers |
Definition at line 72 of file CuboidVolumeBuilder.cpp.
View newest version in sPHENIX GitHub at line 72 of file CuboidVolumeBuilder.cpp
References Acts::units::_um, Acts::CuboidVolumeBuilder::VolumeConfig::layerCfg, and max.
std::shared_ptr< const Acts::Layer > Acts::CuboidVolumeBuilder::buildLayer | ( | const GeometryContext & | gctx, |
LayerConfig & | cfg | ||
) | const |
This function creates a layer with a surface encaspulated with a given configuration. The surface gets a detector element attached if the template parameter is non-void.
[in] | gctx | the geometry context for this building |
[in,out] | cfg | Configuration of the layer and the surface |
Definition at line 52 of file CuboidVolumeBuilder.cpp.
View newest version in sPHENIX GitHub at line 52 of file CuboidVolumeBuilder.cpp
References Acts::CuboidVolumeBuilder::LayerConfig::binsY, Acts::CuboidVolumeBuilder::LayerConfig::binsZ, Acts::binX, Acts::CuboidVolumeBuilder::SurfaceConfig::position, Acts::CuboidVolumeBuilder::SurfaceConfig::rotation, Acts::CuboidVolumeBuilder::LayerConfig::surface, Acts::LayerCreator::Config::surfaceArrayCreator, and Acts::CuboidVolumeBuilder::LayerConfig::surfaceCfg.
Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().
std::shared_ptr< const Acts::PlaneSurface > Acts::CuboidVolumeBuilder::buildSurface | ( | const GeometryContext & | gctx, |
const SurfaceConfig & | cfg | ||
) | const |
This function creates a surface with a given configuration. A detector element is attached if the template parameter is non-void.
[in] | gctx | the geometry context for this building |
[in] | cfg | Configuration of the surface |
Definition at line 29 of file CuboidVolumeBuilder.cpp.
View newest version in sPHENIX GitHub at line 29 of file CuboidVolumeBuilder.cpp
References Acts::CuboidVolumeBuilder::SurfaceConfig::detElementConstructor, Acts::CuboidVolumeBuilder::SurfaceConfig::position, Acts::CuboidVolumeBuilder::SurfaceConfig::rBounds, Acts::CuboidVolumeBuilder::SurfaceConfig::rotation, surface(), Acts::CuboidVolumeBuilder::SurfaceConfig::surMat, and Acts::CuboidVolumeBuilder::SurfaceConfig::thickness.
Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().
std::shared_ptr< Acts::TrackingVolume > Acts::CuboidVolumeBuilder::buildVolume | ( | const GeometryContext & | gctx, |
VolumeConfig & | cfg | ||
) | const |
This function creates a TrackingVolume with a configurable number of layers and surfaces. Each surface gets a detector element attached if the template parameter is non-void.
[in] | gctx | the geometry context for this building |
[in,out] | cfg | Configuration of the TrackingVolume |
Definition at line 91 of file CuboidVolumeBuilder.cpp.
View newest version in sPHENIX GitHub at line 91 of file CuboidVolumeBuilder.cpp
References Acts::arbitrary, Acts::binX, Acts::TrackingVolume::create(), Acts::getDefaultLogger(), Acts::Logging::INFO, Acts::LayerArrayCreator::layerArray(), Acts::CuboidVolumeBuilder::VolumeConfig::layerCfg, Acts::CuboidVolumeBuilder::VolumeConfig::layers, Acts::CuboidVolumeBuilder::VolumeConfig::length, Acts::CuboidVolumeBuilder::VolumeConfig::name, Acts::CuboidVolumeBuilder::SurfaceConfig::position, Acts::CuboidVolumeBuilder::VolumeConfig::position, Acts::CuboidVolumeBuilder::SurfaceConfig::rBounds, Acts::CuboidVolumeBuilder::SurfaceConfig::rotation, Acts::CuboidVolumeBuilder::LayerConfig::surfaceCfg, Acts::CuboidVolumeBuilder::VolumeConfig::trackingVolumes, Acts::CuboidVolumeBuilder::VolumeConfig::volumeCfg, and Acts::CuboidVolumeBuilder::VolumeConfig::volumeMaterial.
Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().
Setter of the config.
[in] | cfg | Configuration that is set |
Definition at line 114 of file CuboidVolumeBuilder.hpp.
View newest version in sPHENIX GitHub at line 114 of file CuboidVolumeBuilder.hpp
References m_cfg.
Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().
void Acts::CuboidVolumeBuilder::sortVolumes | ( | std::vector< std::pair< TrackingVolumePtr, Vector3D >> & | tapVec, |
BinningValue | bValue | ||
) | const |
|
override |
This function builds a world TrackingVolume based on a given configuration.
[in] | gctx | the geometry context for this building |
Definition at line 166 of file CuboidVolumeBuilder.cpp.
View newest version in sPHENIX GitHub at line 166 of file CuboidVolumeBuilder.cpp
References Acts::binX, Acts::TrackingVolume::create(), Acts::negativeFaceYZ, Acts::open, Acts::positiveFaceYZ, Acts::Test::volume, Acts::CuboidVolumeBuilder::VolumeConfig::volumeCfg, and x.
Referenced by Acts::Test::BOOST_AUTO_TEST_CASE(), and Acts::IntegrationTest::BOOST_DATA_TEST_CASE().
|
private |
Configuration of the world volume.
Definition at line 176 of file CuboidVolumeBuilder.hpp.
View newest version in sPHENIX GitHub at line 176 of file CuboidVolumeBuilder.hpp
Referenced by setConfig().