Back to home page

EIC code displayed by LXR

 
 

    


Warning, /geant4/examples/extended/persistency/gdml/G02/README is written in an unsupported language. File is not indexed.

0001 -------------------------------------------------------------------
0002 
0003  Example of use GDML reader/writer in  Detector Construction
0004  -----------------------------------------------------------
0005 
0006  In this directory you can find a example showing how to use GDML module for
0007  reading and writing. It is also shown how to Read STEP Tools files.
0008  In this example the DetectorConstruction consists of a Simple Detector, then
0009  this Detector is filled/written in GDML.
0010  The different options for writing and reading GDML files are shown in the
0011  Detector Construction: writing modular files, using different schema location,
0012  setting parameters for names in GDML file, etc.
0013  For more information, please, refer to the GDML Documentation.
0014   
0015  The Geometry is a Simple Detector Box with 4 Subdetectors. 
0016  This setup shows how to use Reflection Factory, Assembly of Volumes and
0017  Parameterisation. 
0018  Using commands or macros it possible to read or write GDML file.
0019   
0020  HOW TO BUILD THE EXAMPLE ?
0021  
0022  - You need to have built the persistency/gdml module by having
0023    set the -DGEANT4_USE_GDML=ON flag during the CMAKE configuration step, 
0024    as well as the -DXERCESC_ROOT_DIR=<path_to_xercesc> flag pointing to 
0025    the path where the XercesC XML parser package is installed in your system.
0026  
0027  - Compile and link to generate the executable (in your CMAKE build directory):
0028                % make
0029  
0030  - Execute the application:
0031                % geotest [macro-file].mac
0032 
0033  You can run this application with the following macro file:
0034    
0035     write_gdml.mac : This macro will write the Geometry defined in file
0036                      "test.gdml" and output to a new file wtest.gdml
0037                      To change this name you can use command :
0038                      /mydet/writeFile FileName.gdml
0039 
0040     read_gdml.mac : This macro will read the Geometry from file "test.gdml"
0041                      To change this name you can use command :
0042                      /mydet/readFile FileName.gdml
0043 
0044     read_step.mac : This macro will read the STEP Tool files "mbb.geom" and
0045                     "mbb.tree" and load them in memory.
0046                      To change this name you can use command :
0047                      /mydet/StepFile FileName