GSI Forum
GSI Helmholtzzentrum für Schwerionenforschung

Home » PANDA » PandaRoot » General » TGeoManager and TGeoVolume
Re: TGeoManager and TGeoVolume [message #5976 is a reply to message #5963] Tue, 26 February 2008 13:19 Go to previous messageGo to previous message
George Serbanut is currently offline  George Serbanut
Messages: 4
Registered: May 2007
occasional visitor
From: *to.infn.it
Hi,

I experienced that problem as well and I managed to worked around that problem. If you inherit CbmDetector for your class, you have access to gGeoManager which is the simulation manager (the instance of TGeoManager). Once you registered the materials (as materials or mixtures) and media in gGeoManager, all you have to do is to set the geometry which, in the case you are not using the "standard" way (meaning, in ConstructGeometry member), you can register your volumes to gGeoManager by accessing gGeoManager->AddVolume(<volume>), and to access it further (in any other member) by calling gGeoManager->GetVolume("<volume name>"). For more information, have a look on http://root.cern.ch/root/html/TGeoManager.html (gGeoManager is the instance of that class).

You will need one more thing: register your class in the DB (see the examples how to register a class of parameters in DB).

Good luck!
George
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Includes for MacOs X for different detectors.
Next Topic: root files with the same hitcolection structure
Goto Forum:
  


Current Time: Mon Dec 02 18:24:08 CET 2024

Total time taken to generate the page: 0.00757 seconds