GSI Forum
GSI Helmholtzzentrum für Schwerionenforschung

Home » PANDA » PandaRoot » General » gGeoManager existing?
Re: gGeoManager existing? [message #5249 is a reply to message #5241] Thu, 18 October 2007 13:33 Go to previous messageGo to previous message
Mohammad Al-Turany is currently offline  Mohammad Al-Turany
Messages: 518
Registered: April 2004
Location: GSI, Germany
first-grade participant
From: *gsi.de
Hallo Tobias,
There is two ways to do this:

1. if you know the name of the TGeoManager object, you can use:

gROOT->FindObjectAny("ObjectName")

this will return a pointer to TGeo if it exist or a zero if not.
in case of PandaRoot it is always created with the default name "CBMGeom".

2. In case you do not no the name, you can call:

gROOT->GetListOfGeometries()

which will return you a TSeqCollection of existing geometries (TGeoManager objects) which you can check if it is empty or has some entries which will be the existing geometries.


regards

Mohammad

 
Read Message
Read Message
Read Message
Previous Topic: DataFlow
Next Topic: GeoManager questions
Goto Forum:
  


Current Time: Thu Jul 18 13:05:52 CEST 2024

Total time taken to generate the page: 0.00681 seconds