Ignore:
Timestamp:
Jun 14, 2010, 3:54:58 PM (14 years ago)
Author:
garnier
Message:

geant4.9.4 beta rc0

Location:
trunk/examples/advanced/air_shower
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/examples/advanced/air_shower/GNUmakefile

    r1230 r1313  
    88
    99ifndef G4INSTALL
    10   G4INSTALL = ../../..
     10  G4INSTALL = ../..
    1111endif
    1212
  • trunk/examples/advanced/air_shower/History

    r807 r1313  
    1 $Id: History,v 1.14 2007/09/30 23:05:58 gum Exp $
     1$Id: History,v 1.24 2010/06/06 06:13:59 perl Exp $
    22-------------------------------------------------------------------
    33
     
    88                           History file
    99                           ------------
     1002.06.2010 - J.Perl (air_shower-V09-03-00)
     11             Updated vis usage
     12
     1316.11.2009 -- B. Tomé,
     14              Tag air_shower-V09-02-06
     15              Changed UltraPhysicsList.cc to use new processes G4eMultipleScattering, G4MuMultipleScattering
     16              and G4hMultipleScattering
     17              Tested example air_shower with Geant4 tag geant4-09-02-ref-10
     18
     1915.05.2009 -- B. Tomé,
     20              Updated README file. Tag air_shower-V09-01-00
     21              Tested example with Geant4 tag geant4-09-02-ref-04 and iAIDA-1.0.14
     22
     2310.12.2008 -- G.A.P.Cirrone, Tag: air_shower-V09-01-05
     24              Updated README file;
     2503.07.2008 -- B. Tomé;  Tag air_shower-V09-01-04
     26              Access to private data members of UltraDetectorConstruction through Get functions.
     27
     2803.07.2008 -- B. Tomé;  Tag air_shower-V09-01-03
     29              Adjusted range of optical properties tables in UltraDetectorConstruction;
     30              Added check of optical photon energy in UltraPrimaryGeneratorAction;
     31              Cerenkov process attached to all applicable particles;
     32              Modified Visualisation.mac and UltraMacro.mac files
     33             
     3426.06.2008 -- G.A.P.Cirrone; Tag air_shower-V09-01-02
     35              Corrected a parameter in the UltraDetectorConstruction to remove a segmentation
     36              due to a non correct definition of the refraction index of the Quartz.
     37
     3815.06.2008 -- G.A.P.Cirrone; Tag: air_shower-V09-01-01
     39              Removed no more necessary AIDA commands from GNUmakefile
     40
     4111.06.2008 -- G.A.P.Cirrone air_shower-V09-01-00
     42              Solved a compilation error in the Analysis Manager
    1043
    114430.09.2007 -- P.Gumplinger - air_shower-V09-00-00
     
    3871           -- Corrected usage of <strstream> in RunActionMessenger.
    3972           -- Corrected call to Visualisation.mac from Ultra.cc.
    40               - Changed viewer to OGLSX in Visualisation.mac.
     73           -- Changed viewer to OGLSX in Visualisation.mac.
    4174
    427503.05.2005 -- J.Allison
  • trunk/examples/advanced/air_shower/Visualisation.mac

    r1230 r1313  
    33/run/verbose 2
    44#
    5 # create empty scene
     5# Use this open statement to create an OpenGL view:
     6#/vis/open OGL 600x600-0+0
    67#
    7 #/vis/scene/create Space
    8 #/vis/scene/notifyHandlers Space flush
    9 /vis/scene/create
     8# Use this open statement to create a .prim file suitable for
     9# viewing in DAWN:
     10/vis/open DAWNFILE
    1011#
    11 # Create a scene handler for a specific graphics system
    12 # (Edit the next line(s) to choose another graphic system)
     12# Use this open statement to create a .heprep file suitable for
     13# viewing in HepRApp:
     14#/vis/open HepRepFile
    1315#
    14 #/vis/open OGLIX
    15 #/vis/open RayTracer
    16 #/vis/open OGLSX
    17 /vis/open DAWNFILE
    18 #/vis/open HepRepFile
     16# Use this open statement to create a .wrl file suitable for
     17# viewing in a VRML viewer:
    1918#/vis/open VRML2FILE
    2019#
    21 /vis/viewer/set/viewpointThetaPhi 90.0 0.0 deg
    22 /vis/viewer/zoom 1.
    23 /vis/viewer/flush
     20# Disable auto refresh and quieten vis messages whilst scene and
     21# trajectories are established:
     22/vis/viewer/set/autoRefresh false
     23/vis/verbose errors
     24#
     25# Draw geometry:
     26/vis/drawVolume
     27#
     28# Specify view angle:
     29/vis/viewer/set/viewpointThetaPhi 90. 0.
     30#
     31# Specify zoom value:
     32#/vis/viewer/zoom 2.
     33#
     34# Specify style (surface or wireframe):
     35#/vis/viewer/set/style wireframe
     36#
     37# Draw coordinate axes:
     38#/vis/scene/add/axes 0 0 0 1 m
     39#
     40# Draw smooth trajectories at end of event, showing trajectory points
     41# as markers 2 pixels wide:
     42/vis/scene/add/trajectories smooth
     43/vis/modeling/trajectories/create/drawByCharge
     44/vis/modeling/trajectories/drawByCharge-0/default/setDrawStepPts true
     45/vis/modeling/trajectories/drawByCharge-0/default/setStepPtsSize 2
     46# (if too many tracks cause core dump => /tracking/storeTrajectory 0)
     47#
     48# Draw hits at end of event:
     49#/vis/scene/add/hits
     50#
     51# To draw only gammas:
     52#/vis/filtering/trajectories/create/particleFilter
     53#/vis/filtering/trajectories/particleFilter-0/add gamma
     54#
     55# To invert the above, drawing all particles except gammas,
     56# keep the above two lines but also add:
     57#/vis/filtering/trajectories/particleFilter-0/invert true
     58#
     59# Many other options are available with /vis/modeling and /vis/filtering.
     60# For example, to select colour by particle ID:
     61#/vis/modeling/trajectories/create/drawByParticleID
     62#/vis/modeling/trajectories/drawByParticleID-0/set e- blue
     63#
     64# To superimpose all of the events from a given run:
     65/vis/scene/endOfEventAction accumulate
     66#
     67# Re-establish auto refreshing and verbosity:
    2468/vis/viewer/set/autoRefresh true
     69/vis/verbose warnings
    2570#
    26 # for drawing the tracks
    27 # (if too many tracks cause core dump => storeTrajectory 0)
    28 /tracking/storeTrajectory 1
    29 /tracking/verbose 0
    30 #/vis/drawView
    31 
    32 /vis/scene/add/trajectories
    33 /vis/scene/endOfEventAction accumulate
    34 #/vis/drawVolume
     71# For file-based drivers, use this to create an empty detector view:
     72#/vis/viewer/flush
     73#
    3574/gps/particle opticalphoton
    3675/gps/energy 2.0 eV     
    3776/mysetrun/SetRunID 9999
    3877/run/beamOn 100
    39 
  • trunk/examples/advanced/air_shower/src/UltraEventAction.cc

    r807 r1313  
    5151#include "G4VHitsCollection.hh"
    5252#include "G4GeneralParticleSource.hh"
    53 
    54 #include "G4TrajectoryContainer.hh"
    55 #include "G4Trajectory.hh"
    56 #include "G4VVisManager.hh"
    5753
    5854#ifdef G4ANALYSIS_USE
     
    134130  analysis->FillHistogram(2,nOptHits);
    135131#endif
    136 
    137   // Define visualization atributes:
    138 
    139   G4String drawFlag = "all";
    140   G4VVisManager* pVVisManager = G4VVisManager::GetConcreteInstance();
    141 
    142   if(pVVisManager)
    143   {
    144    G4TrajectoryContainer* trajectoryContainer = evt->GetTrajectoryContainer();
    145    G4int n_trajectories = 0;
    146    if (trajectoryContainer) n_trajectories = trajectoryContainer->entries(); 
    147    for(G4int i=0; i<n_trajectories; i++)
    148       { G4Trajectory* trj = (G4Trajectory *)((*(evt->GetTrajectoryContainer()))[i]);
    149         if (drawFlag == "all") trj->DrawTrajectory();
    150         else if ((drawFlag == "charged")&&(trj->GetCharge() != 0.))
    151                                trj->DrawTrajectory();
    152       }
    153   }
    154 
    155132}
    156133
Note: See TracChangeset for help on using the changeset viewer.