The following is a n E-Mail from Rene Brun, which has been suitably edited to give the FNAL specific commands to get the Root macro e907_geometry_geant.C file.

 

                  Raja

_____________________________________________________________________________________________

Hi Raja,

When I was at FNAL in June, I presented the new Root geometry package.
A short introduction to the package could be:

"The new ROOT geometry package is a tool designed for building, browsing,
tracking and visualizing a detector
 geometry. The code works standalone with respect to any tracking
Monte-Carlo engine, therefore it does not
 contain any constraints related to physics. However, the package defines
a number of hooks in order to ease-up
 tracking, allowing user-defined objects to be attached to the basic
architectural structures. The modeling
 functionalities were designed to optimize particle transport thorough
complex geometries and they are accessible
 in an easy and transparent way. The package is currently under
development and new features will be
 implemented, but the basic functionality has already been extensively
tested on several detector geometries.
 The final goal is to be able to use the same geometry for several
purposes, such as tracking, reconstruction or
 visualization, taking advantage of the ROOT features related to
bookkeeping, I/O, histograming, browsing and graphical interfaces."

You can convert an existing Geant3 geometry in a RZ file to a C++ script
with

 

 setup root v3_03_07b -q GCC_3_1:opt (linux node preferred on FNAL)

  - g2root e907_geometry_geant.rz     e907_geometry_geant.C  where
 - g2root is in $ROOTSYS/bin/g2root (use version 3.03/08)
 - E907_GEOMETRY_GEANT.geom is the input RZ file
 - E907_GEOMETRY_GEANT.C is the C++ script generated

Now in an interactive Root session, you can do:
root > .x E907_GEOMETRY_GEANT.C
root > new TBrowser
and browse/draw your detector/sub-detectors, including dynamic 3-d
rotations with the X3D viewer.

For more info on the geometry package, see, eg:
http://root.cern.ch/root/htmldoc/TGeoManager.html

or play with the Root tutorial $ROOTSYS/tutorial/rootgeom.C

You can send me your file E907_GEOMETRY_GEANT.geom if you want. I will have a look at it.

We are still working on this package. We are expecting to have a fully
functional package this fall. Starting early next year, we intend to use
it with Geant3 or Geant4 via our VirtualMonteCarlo interface.

Rene
_____________________________________________________________________________________
On Fri, 13 Sep 2002, Rajendran Raja wrote:

> Dear Rene,
>
> The Fermilab hadron production experiment MIPP (E-907) has the following "generic" problem. We use Geant3 to simulate. We have a good description of Geometry. We use C++ for offline reconstruction. How do we convert the Geant3 geometry (in an fz/Rz file) into C++ objects?
>
> Is there a solution by which we convert the geometrical volumes into Root objects? Also are there geometrical routines in ROOT that can handle the needed geomery for offline reconstruction?
>
>                                        best regards
>
>                                            Rajendran Raja
>                                            Fermilab,
>                                            WH13E, Rm 1327
>                                            Tel: 630-840-4092
>                                            Fax: 630-840-6311
>