|
LDMX Software
|
This class is a abstract base class (ABC) doing common tasks that tracking geometries need done. More...
#include <TrackingGeometry.h>
Public Member Functions | |
| TrackingGeometry (const std::string &name, const Acts::GeometryContext &gctx, const std::string &gdml) | |
| virtual | ~TrackingGeometry ()=default |
| Destructor. | |
| G4VPhysicalVolume * | findDaughterByName (G4VPhysicalVolume *pvol, G4String name) |
| void | getAllDaughters (G4VPhysicalVolume *pvol) |
| void | convertG4Rot (const G4RotationMatrix *g4rot, Acts::RotationMatrix3 &rot) const |
| Acts::Vector3 | convertG4Pos (const G4ThreeVector &g4pos) const |
| void | dumpGeometry (const std::string &outputDir, const Acts::GeometryContext &gctx) const |
| std::shared_ptr< const Acts::TrackingGeometry > | getTG () const |
| Acts::Transform3 | getTransform (const G4VPhysicalVolume &phex, bool toTrackingFrame=false) const |
| Acts::Transform3 | toTracker (const Acts::Transform3 &trans) const |
| void | makeLayerSurfacesMap () |
| void | getSurfaces (std::vector< const Acts::Surface * > &surfaces) const |
| const Acts::Surface * | getSurface (int layerid) const |
| const std::string & | fieldMapFile () const |
| Full path to the field map file extracted from the GDML auxiliary data. | |
Public Member Functions inherited from framework::ConditionsObject | |
| ConditionsObject (const std::string &name) | |
| Class constructor. | |
| virtual | ~ConditionsObject () |
| Destructor. | |
| std::string | getName () const |
| Get the name of this object. | |
Static Public Member Functions | |
| static bool | compareZlocation (const G4VPhysicalVolume &pvol_a, const G4VPhysicalVolume &pvol_b) |
Public Attributes | |
| std::unordered_map< unsigned int, const Acts::Surface * > | layer_surface_map_ |
| std::vector< std::shared_ptr< tracking::geo::DetectorElement > > | det_elements_ |
Protected Attributes | |
| const Acts::GeometryContext & | gctx_ |
| std::string | gdml_ {""} |
| Acts::RotationMatrix3 | x_rot_ |
| Acts::RotationMatrix3 | y_rot_ |
| std::shared_ptr< const Acts::TrackingGeometry > | t_geometry_ {nullptr} |
| G4VPhysicalVolume * | f_world_phys_vol_ {nullptr} |
Private Attributes | |
| std::string | field_map_file_ {""} |
This class is a abstract base class (ABC) doing common tasks that tracking geometries need done.
Right now, in LDMX, there are two (or three) distinct tracking geometries: The tagger tracker, the recoil tracker, and the ECal. Sometimes the tagger and recoil are combined into a single tracker geometry but the ECal is always distinct.
While this class inherits from ConditionsObject, it should never have a provider. Only the concrete derived classes should have providers.
Definition at line 33 of file TrackingGeometry.h.
| tracking::geo::TrackingGeometry::TrackingGeometry | ( | const std::string & | name, |
| const Acts::GeometryContext & | gctx, | ||
| const std::string & | gdml ) |
| [in] | name | the name of this geometry condition object |
| [in] | gctx | the geometry context for this geometry |
| [in] | gdml | the path to the detector GDML to load |
We are about to use the G4GDMLParser and would like to silence the output from parsing the geometry. This can only be done by redirecting G4cout and G4cerr via the G4UImanager.
The Simulator (if it is running) will already do this redirection for us and we don't want to override it, so we check if there is a simulation running by seeing if the run manager is created. If it isn't, then we redirect G4cout and G4cerr to a G4Session that just throws away all those messages.
Definition at line 33 of file TrackingGeometry.cxx.
|
inlinestatic |
Definition at line 49 of file TrackingGeometry.h.
| Acts::Vector3 tracking::geo::TrackingGeometry::convertG4Pos | ( | const G4ThreeVector & | g4pos | ) | const |
Definition at line 281 of file TrackingGeometry.cxx.
| void tracking::geo::TrackingGeometry::convertG4Rot | ( | const G4RotationMatrix * | g4rot, |
| Acts::RotationMatrix3 & | rot ) const |
Definition at line 257 of file TrackingGeometry.cxx.
| void tracking::geo::TrackingGeometry::dumpGeometry | ( | const std::string & | outputDir, |
| const Acts::GeometryContext & | gctx ) const |
Definition at line 180 of file TrackingGeometry.cxx.
|
inline |
Full path to the field map file extracted from the GDML auxiliary data.
Empty if no MagneticField auxiliary block was found.
Definition at line 85 of file TrackingGeometry.h.
| G4VPhysicalVolume * tracking::geo::TrackingGeometry::findDaughterByName | ( | G4VPhysicalVolume * | pvol, |
| G4String | name ) |
Definition at line 133 of file TrackingGeometry.cxx.
| void tracking::geo::TrackingGeometry::getAllDaughters | ( | G4VPhysicalVolume * | pvol | ) |
Definition at line 146 of file TrackingGeometry.cxx.
|
inline |
Definition at line 77 of file TrackingGeometry.h.
| void tracking::geo::TrackingGeometry::getSurfaces | ( | std::vector< const Acts::Surface * > & | surfaces | ) | const |
Definition at line 292 of file TrackingGeometry.cxx.
|
inline |
Definition at line 61 of file TrackingGeometry.h.
| Acts::Transform3 tracking::geo::TrackingGeometry::getTransform | ( | const G4VPhysicalVolume & | phex, |
| bool | toTrackingFrame = false ) const |
Definition at line 217 of file TrackingGeometry.cxx.
| void tracking::geo::TrackingGeometry::makeLayerSurfacesMap | ( | ) |
Definition at line 316 of file TrackingGeometry.cxx.
| Acts::Transform3 tracking::geo::TrackingGeometry::toTracker | ( | const Acts::Transform3 & | trans | ) | const |
Definition at line 242 of file TrackingGeometry.cxx.
| std::vector<std::shared_ptr<tracking::geo::DetectorElement> > tracking::geo::TrackingGeometry::det_elements_ |
Definition at line 90 of file TrackingGeometry.h.
|
protected |
Definition at line 98 of file TrackingGeometry.h.
|
private |
Definition at line 101 of file TrackingGeometry.h.
|
protected |
Definition at line 93 of file TrackingGeometry.h.
|
protected |
Definition at line 94 of file TrackingGeometry.h.
| std::unordered_map<unsigned int, const Acts::Surface*> tracking::geo::TrackingGeometry::layer_surface_map_ |
Definition at line 81 of file TrackingGeometry.h.
|
protected |
Definition at line 97 of file TrackingGeometry.h.
|
protected |
Definition at line 96 of file TrackingGeometry.h.
|
protected |
Definition at line 96 of file TrackingGeometry.h.