Scenarios file

After having read a GDML file, you can use (see the "Opening a GDML file" section) the "geom" panel to create interactively scene graphs visualizing part of the geometry.

But operating like that at each g4view session may be tedious. XML scenarios files had been created to strongly customize a geometry visualization but also a simulation.

From the main menu, choose "Files" and then ".scenarios". At least the g4view.scenarios file coming with the application should be proposed. Select this file. When done, the list of scenarion contained in the file is mapped. Here lhcbvelo and lhcbhcal. Choose lhcbhcal, you should see :


The XML scenario code is :

  <scenario name="lhcbhcal">




      <da>0.017</da> <!--one degree -->

      <position>0 0 20000</position>

<!--  <particle>proton</particle> -->
      <sigma_angle>0.17</sigma_angle> <!-- 1 degree = 0.017 -->

      <particle name="e-" color="yellow"/>
      <particle name="e+" color="yellow"/>
      <particle name="gamma" color="blue"/>
      <particle name="e-" color="green"/>
      <particle name="e+" color="blue"/>
      <particle name="gamma" color="red"/>
      <particle name="pi+" color="magenta"/>
      <particle name="pi-" color="magenta"/>
      <particle name="proton" color="cyan"/>
      <particle name="neutron" color="yellow"/>


In this "scenario", not only the gdml file to work with is specified but also the camera setup, some volume to visualize with coloring, the particle gun (here 1 GeV pi0 shooting is requested) but also the coloring of the trajectories.

If you do a "Start run", you should see (after an interactive zoom on the last event) :


The two blue spots are the two electromagnetic showers produced by the two photons issued by the quick decay of the initial pi0.