Analysis Software
Documentation for sPHENIX simulation software
|
Toolsets to do geometry operations. More...
#include <coresoftware/blob/master/offline/packages/PHGeometry/PHGeomUtility.h>
Static Public Member Functions | |
static TGeoManager * | GetTGeoManager (PHCompositeNode *topNode) |
Main user interface: DST node -> TGeoManager for downstream use. | |
static int | ImportGeomFile (PHCompositeNode *topNode, const std::string &geometry_file) |
TGeo ROOT/GDML/Macro file -> DST node with automatic file type discrimination based on file names. | |
static int | ImportCurrentTGeoManager (PHCompositeNode *topNode) |
gGeoManager -> DST node | |
static void | ExportGeomtry (PHCompositeNode *topNode, const std::string &geometry_file) |
DST node -> TGeoManager -> export files, like gdml, .root or .C formats. | |
static PHGeomTGeo * | GetGeomTGeoNode (PHCompositeNode *topNode, bool build_new=true) |
Get non-persistent PHGeomTGeo from DST nodes. If not found, make a new one. | |
static PHGeomIOTGeo * | GetGeomIOTGeoNode (PHCompositeNode *topNode, bool build_new=true) |
Get persistent PHGeomIOTGeo from DST nodes. If not found, make a new one. | |
static PHGeomIOTGeo * | UpdateIONode (PHCompositeNode *topNode) |
static PHGeomTGeo * | LoadFromIONode (PHCompositeNode *topNode) |
static std::string | GenerateGeometryFileName (const std::string &filename_extension="gdml") |
static bool | RemoveGeometryFile (const std::string &file_name) |
delete the geometry file after use | |
static void | SetVerbosity (int v) |
Verbosity for geometry IO like, TGeoMangers. | |
static int | GetVerbosity () |
Verbosity for geometry IO like, TGeoMangers. | |
static std::string | GetDSTNodeName () |
DST node name for RunTime geometry object. | |
static std::string | GetDSTIONodeName () |
DST node name for persistent geometry storage node. | |
static void | SetGenerateGeometryFileNameBase (const std::string &base) |
Private Member Functions | |
PHGeomUtility ()=delete | |
~PHGeomUtility ()=delete | |
Static Private Attributes | |
static std::string | mg_GenerateGeometryFileNameBase = "/tmp" |
Toolsets to do geometry operations.
Definition at line 12 of file PHGeomUtility.h.
View newest version in sPHENIX GitHub at line 12 of file PHGeomUtility.h
|
privatedelete |
|
privatedelete |
|
static |
DST node -> TGeoManager -> export files, like gdml, .root or .C formats.
Definition at line 64 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 64 of file PHGeomUtility.cc
References assert.
Referenced by MakeActsGeometry::buildAllGeometry(), ConstructGeometry(), Fun4All_ExportGeom(), Fun4All_ImportGeom(), and PHG4Reco::InitRun().
|
static |
Make a name for tmp geometry file Geometry files gain a size of ~10MB and it used in translation from Geant4 to DST format. This tmp file should be on a local file system (/tmp/) and write/deletable
Definition at line 189 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 189 of file PHGeomUtility.cc
References file.
Referenced by PHG4Reco::InitRun().
|
inlinestatic |
DST node name for persistent geometry storage node.
Definition at line 74 of file PHGeomUtility.h.
View newest version in sPHENIX GitHub at line 74 of file PHGeomUtility.h
|
inlinestatic |
DST node name for RunTime geometry object.
Definition at line 67 of file PHGeomUtility.h.
View newest version in sPHENIX GitHub at line 67 of file PHGeomUtility.h
|
static |
Get persistent PHGeomIOTGeo from DST nodes. If not found, make a new one.
Definition at line 157 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 157 of file PHGeomUtility.cc
References PHNodeIterator::findFirst().
Referenced by MakeActsGeometry::editTPCGeometry().
|
static |
Get non-persistent PHGeomTGeo from DST nodes. If not found, make a new one.
Definition at line 124 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 124 of file PHGeomUtility.cc
References PHNodeIterator::findFirst().
Referenced by MakeActsGeometry::editTPCGeometry().
|
static |
Main user interface: DST node -> TGeoManager for downstream use.
DST node -> TGeoManager for downstream use.
Definition at line 33 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 33 of file PHGeomUtility.cc
References PHGeomTGeo::GetGeometry(), and PHGeomTGeo::isValid().
Referenced by MakeActsGeometry::getNodes(), PHGenFitTrackProjection::InitRun(), TpcPrototypeGenFitTrkFinder::InitRun(), SVReco::InitRun(), GenFitTrackProp::InitRun(), PHRaveVertexing::InitRun(), BDiJetModule::InitRun(), PHG4TrackFastSim::InitRun(), TpcPrototypeGenFitTrkFitter::InitRun(), PHGenFitTrkFitter::InitRun(), PHGeom_DSTInspection(), TrackProjectorPid::TrackProjectorPid(), and TrackProjectorPlaneECAL::TrackProjectorPlaneECAL().
|
static |
Verbosity for geometry IO like, TGeoMangers.
Definition at line 300 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 300 of file PHGeomUtility.cc
References PHFlag::FlagExist(), PHFlag::get_IntFlag(), and recoConsts::instance().
|
static |
gGeoManager -> DST node
Definition at line 107 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 107 of file PHGeomUtility.cc
References assert, Fun4AllReturnCodes::EVENT_OK, PHGeomTGeo::GetGeometry(), PHGeomTGeo::isValid(), and PHGeomTGeo::SetGeometry().
|
static |
TGeo ROOT/GDML/Macro file -> DST node with automatic file type discrimination based on file names.
Definition at line 74 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 74 of file PHGeomUtility.cc
References Fun4AllReturnCodes::ABORTRUN, assert, Fun4AllReturnCodes::EVENT_OK, PHGeomTGeo::GetGeometry(), PHGeomTGeo::Reset(), and PHGeomTGeo::SetGeometry().
Referenced by PHGeomFileImport::InitRun(), and PHG4Reco::InitRun().
|
static |
Build or update PHGeomTGeo node RUN/GEOMETRY based on the persistent PHGeomIOTGeo node RUN/GEOMETRY_IO
Definition at line 261 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 261 of file PHGeomUtility.cc
References assert, and PHGeomTGeo::SetGeometry().
|
static |
delete the geometry file after use
Definition at line 208 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 208 of file PHGeomUtility.cc
References in.
Referenced by PHG4Reco::InitRun().
|
inlinestatic |
Base path name for temp geometry GDML file used in GenerateGeometryFileName(). User can overwrite it to e.g. local directory with PHGeomUtility::SetGenerateGeometryFileNameBase('./');
Definition at line 81 of file PHGeomUtility.h.
View newest version in sPHENIX GitHub at line 81 of file PHGeomUtility.h
References mg_GenerateGeometryFileNameBase.
|
static |
Verbosity for geometry IO like, TGeoMangers.
Definition at line 293 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 293 of file PHGeomUtility.cc
References recoConsts::instance(), and PHFlag::set_IntFlag().
|
static |
Update persistent PHGeomIOTGeo node RUN/GEOMETRY_IO based on run-time object PHGeomTGeo at RUN/GEOMETRY
Definition at line 231 of file PHGeomUtility.cc.
View newest version in sPHENIX GitHub at line 231 of file PHGeomUtility.cc
References assert, and PHGeomIOTGeo::SetGeometry().
Referenced by MakeActsGeometry::editTPCGeometry().
|
staticprivate |
Base path name for temp geometry GDML file used in GenerateGeometryFileName(). User can overwrite it to e.g. local directory with PHGeomUtility::SetGenerateGeometryFileNameBase('./');
Definition at line 89 of file PHGeomUtility.h.
View newest version in sPHENIX GitHub at line 89 of file PHGeomUtility.h
Referenced by SetGenerateGeometryFileNameBase().