diff --git a/Simulation/G4Faser/G4FaserAlg/src/G4FaserAlg.cxx b/Simulation/G4Faser/G4FaserAlg/src/G4FaserAlg.cxx index 3ce528b032fd0ce76494e114623aa753dbc0345c..45b30b961663ccd9131a29c7cfc450743796c297 100644 --- a/Simulation/G4Faser/G4FaserAlg/src/G4FaserAlg.cxx +++ b/Simulation/G4Faser/G4FaserAlg/src/G4FaserAlg.cxx @@ -30,6 +30,9 @@ #include "G4VModularPhysicsList.hh" #include "G4ParallelWorldPhysics.hh" +#include "G4LogicalVolumeStore.hh" +#include "G4GDMLParser.hh" + // CLHEP includes #include "CLHEP/Random/RandomEngine.h" @@ -198,6 +201,12 @@ void G4FaserAlg::initializeOnce() throw std::runtime_error("Could not initialize ATLAS UserLimitsSvc!"); } + G4LogicalVolumeStore* store = G4LogicalVolumeStore::GetInstance(); + G4LogicalVolume* world = store->GetVolume("Faser::Faser"); + G4GDMLParser parser {}; + parser.Write("Faser.gdml", world); + ATH_MSG_ALWAYS("Wrote detector geometry to GDML file"); + if (m_activateParallelGeometries) { G4VModularPhysicsList* thePhysicsList=dynamic_cast<G4VModularPhysicsList*>(m_physListSvc->GetPhysicsList()); if (!thePhysicsList) {