Geant4 Cross Reference |
1 ############################################## 1 ####################################################################### 2 # MACRO FILE NAME: exN03Vis13.mac 2 # MACRO FILE NAME: exN03Vis13.mac # 3 # 3 # # 4 # AUTHOR(S): John Allison 4 # AUTHOR(S): John Allison # 5 # 5 # # 6 # DATE: 18th August 2006 6 # DATE: 18th August 2006 # 7 # 7 # # 8 # CONTENTS: Time development of an electromag 8 # CONTENTS: Time development of an electromagnetic shower. # 9 # 9 # # 10 # USAGE: 10 # USAGE: # 11 # cp -pr <install-dir>/geant4/examples/bas 11 # cp -pr <install-dir>/geant4/examples/basic/B4/macros/visTutor . # 12 # <place-of-binary>/exampleB4a -m visTutor 12 # <place-of-binary>/exampleB4a -m visTutor/exN03Vis13.mac # 13 # 13 # # 14 # REQUIRED PLATFORMS & SOFTWARES: Mac/Unix wi 14 # REQUIRED PLATFORMS & SOFTWARES: Mac/Unix with X-Windows, OpenGL # 15 # 15 # # 16 ############################################## 16 ####################################################################### 17 17 18 /control/verbose 2 18 /control/verbose 2 19 /vis/verbose confirmations 19 /vis/verbose confirmations 20 /run/initialize 20 /run/initialize 21 21 22 /vis/open OGL 600x600-0+0 22 /vis/open OGL 600x600-0+0 23 /vis/drawVolume 23 /vis/drawVolume 24 24 25 # Disable auto refresh and quieten vis message 25 # Disable auto refresh and quieten vis messages whilst scene and 26 # trajectories are established: 26 # trajectories are established: 27 /vis/viewer/set/autoRefresh false 27 /vis/viewer/set/autoRefresh false 28 /vis/verbose errors 28 /vis/verbose errors 29 29 30 /vis/viewer/set/viewpointThetaPhi 90. 180. 30 /vis/viewer/set/viewpointThetaPhi 90. 180. 31 /vis/scene/add/eventID 31 /vis/scene/add/eventID 32 /vis/scene/add/trajectories rich 32 /vis/scene/add/trajectories rich 33 33 34 # Set up drawByParticleID with time slicing 34 # Set up drawByParticleID with time slicing 35 /vis/modeling/trajectories/create/drawByPartic 35 /vis/modeling/trajectories/create/drawByParticleID EmShowerByParticleID 36 /vis/modeling/trajectories/EmShowerByParticleI 36 /vis/modeling/trajectories/EmShowerByParticleID/set e- red 37 /vis/modeling/trajectories/EmShowerByParticleI 37 /vis/modeling/trajectories/EmShowerByParticleID/set e+ blue 38 /vis/modeling/trajectories/EmShowerByParticleI 38 /vis/modeling/trajectories/EmShowerByParticleID/set pi- cyan 39 /vis/modeling/trajectories/EmShowerByParticleI 39 /vis/modeling/trajectories/EmShowerByParticleID/set pi+ magenta 40 #/vis/modeling/trajectories/EmShowerByParticle 40 #/vis/modeling/trajectories/EmShowerByParticleID/default/setDrawStepPts true 41 /vis/modeling/trajectories/EmShowerByParticleI 41 /vis/modeling/trajectories/EmShowerByParticleID/default/setStepPtsSize 5 42 #/vis/modeling/trajectories/EmShowerByParticle 42 #/vis/modeling/trajectories/EmShowerByParticleID/default/setDrawAuxPts true 43 /vis/modeling/trajectories/EmShowerByParticleI 43 /vis/modeling/trajectories/EmShowerByParticleID/default/setAuxPtsSize 5 44 /control/alias interval 0.01 44 /control/alias interval 0.01 45 /control/alias halfInterval 0.005 45 /control/alias halfInterval 0.005 46 /vis/modeling/trajectories/EmShowerByParticleI 46 /vis/modeling/trajectories/EmShowerByParticleID/default/setTimeSliceInterval {interval} ns 47 /vis/modeling/trajectories/list 47 /vis/modeling/trajectories/list 48 48 49 # Remove gammas 49 # Remove gammas 50 /vis/filtering/trajectories/create/particleFil 50 /vis/filtering/trajectories/create/particleFilter EmShowerFilter 51 /vis/filtering/trajectories/EmShowerFilter/add 51 /vis/filtering/trajectories/EmShowerFilter/add gamma 52 /vis/filtering/trajectories/EmShowerFilter/inv 52 /vis/filtering/trajectories/EmShowerFilter/invert true 53 53 54 # Re-establish auto refreshing and verbosity: 54 # Re-establish auto refreshing and verbosity: 55 /vis/viewer/set/autoRefresh true 55 /vis/viewer/set/autoRefresh true 56 /vis/verbose warnings 56 /vis/verbose warnings 57 57 58 # Create trajectories 58 # Create trajectories 59 /gun/energy 10 GeV 59 /gun/energy 10 GeV 60 /vis/viewer/set/globalLineWidthScale 2 60 /vis/viewer/set/globalLineWidthScale 2 61 /run/beamOn 61 /run/beamOn 62 62 63 # Run time sequence 63 # Run time sequence 64 /vis/viewer/set/timeWindow/fadeFactor 1 64 /vis/viewer/set/timeWindow/fadeFactor 1 65 /vis/viewer/set/timeWindow/displayHeadTime tru 65 /vis/viewer/set/timeWindow/displayHeadTime true 66 # The trajectories can appear of jump ahead of 66 # The trajectories can appear of jump ahead of the light front because 67 # their time range overlaps the viewer's time 67 # their time range overlaps the viewer's time range. To mitigate this 68 # effect of discrete time intervals, advance t 68 # effect of discrete time intervals, advance the light front by half the 69 # trajectories interval... 69 # trajectories interval... 70 /vis/viewer/set/timeWindow/displayLightFront t 70 /vis/viewer/set/timeWindow/displayLightFront true 0 0 -90 mm -{halfInterval} ns 71 /vis/viewer/panTo -9 0 cm 71 /vis/viewer/panTo -9 0 cm 72 /vis/viewer/zoomTo 2 72 /vis/viewer/zoomTo 2 73 /control/alias timeRange 0.1 73 /control/alias timeRange 0.1 74 /control/alias dz 0.3 74 /control/alias dz 0.3 75 # Switch off auto-refresh to avoid refresh on 75 # Switch off auto-refresh to avoid refresh on /vis/viewer/pan in loop. 76 # (Then force refresh in loop.) 76 # (Then force refresh in loop.) 77 /vis/viewer/set/autoRefresh 0 77 /vis/viewer/set/autoRefresh 0 78 /vis/verbose errors 78 /vis/verbose errors 79 /control/verbose 0 79 /control/verbose 0 80 /control/loop visTutor/exN03Vis13.loop endTime 80 /control/loop visTutor/exN03Vis13.loop endTime 0 0.7 0.001 81 /control/verbose 2 81 /control/verbose 2 82 /vis/verbose confirmations 82 /vis/verbose confirmations