Back to home page

sPhenix code displayed by LXR

 
 

    


Warning, /g4exampledetector/simple/macros/vis.mac is written in an unsupported language. File is not indexed.

0001 # $Id: vis.mac,v 1.4 2010/04/14 18:32:59 lindenle Exp $
0002 #
0003 # Macro file for the initialization phase of "exampleN03.cc"
0004 # when running in interactive mode
0005 #
0006 # Sets some default verbose
0007 #
0008 /control/verbose 2
0009 /control/saveHistory
0010 /run/verbose 2
0011 #
0012 # create empty scene
0013 #
0014 /vis/scene/create
0015 #
0016 # Create a scene handler for a specific graphics system
0017 # (Edit the next line(s) to choose another graphic system)
0018 #
0019 # Use this open statement to get an .eps and .prim files
0020 # suitable for viewing in DAWN.
0021 ###/vis/open DAWNFILE
0022 #
0023 # Use this open statement instead for OpenGL in immediate mode.
0024 # OGLIX works on the desktops in 1008 while OGLSX terminates
0025 # the X server. I've heard similar stories about OGLIX on other
0026 # machines. You might have to play with it. GEANT prints out a
0027 # list of available graphics systems at some point.
0028 /vis/open OGLIX 1200x900-0+0
0029 #/vis/open OGLSX 1200x900-0+0
0030 # increase display limit for more complex detectors
0031 /vis/ogl/set/displayListLimit 500000
0032 /vis/viewer/set/viewpointThetaPhi 240 -10
0033 /vis/viewer/addCutawayPlane 0 0 0 m 1 0 0
0034 # our world is 4x4 meters, the detector is about 1m across
0035 # zooming by 4 makes it fill the display
0036 /vis/viewer/zoom 1.5
0037 #
0038 # Use this open statement instead to get a HepRep version 1 file
0039 # suitable for viewing in WIRED.
0040 #/vis/open HepRepFile
0041 #
0042 # Use this open statement instead to get a HepRep version 2 file
0043 # suitable for viewing in WIRED.
0044 #/vis/open HepRepXML
0045 #
0046 # Output an empty detector
0047 /vis/viewer/flush
0048 #
0049 # Draw trajectories at end of event, showing trajectory points as
0050 # markers of size 2 pixels
0051 /vis/scene/add/trajectories smooth
0052 /vis/modeling/trajectories/create/drawByCharge
0053 /vis/modeling/trajectories/drawByCharge-0/default/setDrawStepPts true
0054 /vis/modeling/trajectories/drawByCharge-0/default/setStepPtsSize 2
0055 # (if too many tracks cause core dump => /tracking/storeTrajectory 0)
0056 #
0057 # To draw gammas only
0058 #/vis/filtering/trajectories/create/particleFilter
0059 #/vis/filtering/trajectories/particleFilter-0/add gamma
0060 #
0061 # To draw charged particles only
0062 #/vis/filtering/trajectories/particleFilter-0/invert true
0063 #
0064 # Many other options available with /vis/modeling and /vis/filtering.
0065 # For example, select colour by particle ID
0066 #/vis/modeling/trajectories/create/drawByParticleID
0067 #/vis/modeling/trajectories/drawByParticleID-0/set e- red
0068 # remove low energy stuff
0069 /vis/filtering/trajectories/create/attributeFilter
0070 /vis/filtering/trajectories/attributeFilter-0/setAttribute IMag
0071 /vis/filtering/trajectories/attributeFilter-0/addInterval 2 MeV 1000 GeV
0072 #
0073 /vis/scene/endOfEventAction accumulate
0074 #
0075 # At end of each run, an automatic flush causes graphical output.
0076 #/run/beamOn 1
0077 # When you exit Geant4, you will find a file called scene-0.heprep.zip.
0078 # Unzipping this will give you three separate HepRep files suitable for
0079 # viewing in WIRED.
0080 # The first file will contain just detector geometry.
0081 # The second file will contain the detector plus one event.
0082 # The third file will contain the detector plus ten events.