Difference between revisions of "Solgemc GDML Visualization"
From Hall A Wiki
(→ANOTHER OPTION: Directly through GEMC) |
|||
Line 12: | Line 12: | ||
* This will open the gemc window with a wireframe picture of solid (edit the gcard in order to picture your desired volumes from your desired geometry database). | * This will open the gemc window with a wireframe picture of solid (edit the gcard in order to picture your desired volumes from your desired geometry database). | ||
* In order to simplify the editing, I have added an external polycone volume. The perl script used to define the volume is [http://hallaweb.jlab.org/12GeV/SoLID/download/visualize/GEMC/solid_CLEO_ruler.pl here]. Edit the gcard or modify directly the visualization in gemc if you don't want it. This ruler volume is present in both user_geometry_6 (my geometry) and user_geometry (the default geometry) | * In order to simplify the editing, I have added an external polycone volume. The perl script used to define the volume is [http://hallaweb.jlab.org/12GeV/SoLID/download/visualize/GEMC/solid_CLEO_ruler.pl here]. Edit the gcard or modify directly the visualization in gemc if you don't want it. This ruler volume is present in both user_geometry_6 (my geometry) and user_geometry (the default geometry) | ||
+ | [[Image:solid_PVDIS_G4ruler.jpeg|200px|thumb|left|alt text]] | ||
[[File:solid_PVDIS_G4ruler.jpeg|thumb|upright=0.2|alt=SoLID PVDIS wireframe with ruler.|SoLID PVDIS wireframe with ruler.]] | [[File:solid_PVDIS_G4ruler.jpeg|thumb|upright=0.2|alt=SoLID PVDIS wireframe with ruler.|SoLID PVDIS wireframe with ruler.]] |
Revision as of 16:48, 31 August 2012
Visualization in a 2D format using GDML can be done with ROOT's OpenGL implementation. solgemc will write out a GDML file of the geometry last run to solgemc.gdml which can then be shown using the geometry facilities in ROOT.
An example script to do this can be found below
ANOTHER OPTION: Directly through GEMC
Another way to create a 2D with WIREFRAME style uses a macro directly with GEMC. After have saved the picture one can then use latex to add grid, text, etc.
- One needs to create a wireframe picture of the SoLID detector. An example of gcard in my geometry database is here (Save As to visualize). The macro is here
- One will need to just execute the gcard: gemc -gcard=example_PVDIS_2D.gcard
- This will open the gemc window with a wireframe picture of solid (edit the gcard in order to picture your desired volumes from your desired geometry database).
- In order to simplify the editing, I have added an external polycone volume. The perl script used to define the volume is here. Edit the gcard or modify directly the visualization in gemc if you don't want it. This ruler volume is present in both user_geometry_6 (my geometry) and user_geometry (the default geometry)