DAWN
Dawn is a tool to visualize detector geometries. Dawn uses
*.prim
files which are produced for example by
GEANT4. Using the Dawn GUI you can choose angle, zoom, etc. before producing the output postscript image.
DawnCut is used to modify the
*.prim
file before drawing it with Dawn. It removes certain sections to produce cut views of your geometry.
Installation
Dawn
- Download the source code from here
.
- Untar the file:
tar -xvzf dawn-[version].taz
- Go to the freshly created directory:
cd dawn
- Set up the installation by typing:
configure
You have to fill in several settings. This list shows configuration which should work out of the box for SLC5.
- Compiler:
g++
- Optimization:
-O2
- Window shell:
wish
- XLib includes:
-I/usr/include/X11
- XLib libraries:
-L/usr/lib/X11
- OpenGL includes:
-L/usr/include/GL
- OpenGL libraries:
-L/usr/lib
- Afterwards execute
make
and make install
DawnCut
- Download the source code from here
.
- Untar the file:
tar -xvzf dawncut-[version].taz
- Go to the freshly created directory:
cd dawncut
- Build the code:
make
How to make a nice display
- Define macro (
take_picture.mac
) with content
-
/vis/open DAWNFILE 1000x1000+600+400
-
/vis/drawVolume
-
/vis/geometry/set/forceSolid all -1 true
-
/vis/geometry/set/visibility world_volume 0 0
(only if you want to draw surfaces not wireframe)
-
/vis/viewer/flush
- Run
ddsim --runType=vis --compact=CLIC_o2_v03.xml
- Execute
/control/execute take_picture.mac
- Use
dawncut 0 1 0 0 g4_00.prim out.prim
to cut the output primitive (execute dawncut once to see the meaning of the numbers)
- Run again to make a small layer
dawncut 0 -1 0 2 out.prim out2.prim
- Visualize with
dawn out2.prim
- Set polar to 90 and azimuth to 90 on Page1/4 Camera