Geant4 Cross Reference (Editor's cut) |
Version:
[ ReleaseNotes ] [ 10.2 ] [ 10.2.p1 ] [ 10.2.p2 ] [ 10.2.p3 ] [ 10.3 ] [ 10.3.p1 ] [ 10.3.p2 ] [ 10.3.p3 ] [ 10.4 ] [ 10.4.p1 ] [ 10.4.p2 ] [ 10.4.p3 ] [ 10.5 ] [ 10.5.p1 ] [ 10.6 ] [ 10.6.p1 ] [ 10.6.p2 ] [ 10.6.p3 ] [ 10.7 ] [ 10.7.p1 ] [ 10.7.p2 ] [ 10.7.p3 ] [ 10.7.p4 ] [ 11.0 ] [ 11.0.p1 ] [ 11.0.p2 ] [ 11.0.p3 ] [ 11.0.p4 ] [ 11.1 ] [ 11.1.1 ] [ 11.1.2 ] [ 11.1.3 ] [ 11.2 ] [ 11.2.1 ] [ 11.2.2 ]
1
2 G4RayTracer version 1.0 (29/Jan/00)
3
4 1. Introduction
5
6 G4RayTracer is a "ray tracing" package which uses Geant4 kernel mechanism
7 of tracking/navigation. It visualizes any kinds of solids that Geant4
8 kernel can navigate.
9
10 2. Building a library
11
12 G4RayTracer is one of visualization driver which Geant4 supports. To build
13 a library of G4RayTracer (library name G4RayTracer), set an environment
14 variable G4VIS_BUILD_RAYTRACER_DRIVER.
15
16 $ setenv G4VIS_BUILD_RAYTRACER_DRIVER 1
17
18 3. Using G4RayTracer
19
20 To use G4RayTracer, set an environment variable G4VIS_USE_RAYTRACER.
21
22 $ setenv G4VIS_USE_RAYTRACER 1
23
24 Also, G4RayTracer has to be registored to the user's concrete VisManager.
25 Refer an example given in
26 geant4/source/visualization/management/include/MyVisManager.cc.
27
28 4. Notes
29
30 a) G4RayTracer generates JPEG file(s). To visualize these files, use your
31 local program such as NetScape or xview, etc.
32
33 b) The eye position must be inside of the defined world volume. If you want
34 to draw your detector setup from very far position, you need to enlarge
35 your world volume.
36
37 c) G4RayTracer ignores volumes without G4VisAttributes, volumes which are
38 set as "forced wire frame", and volumes which are set as "invisible".
39
40 d) In case you get unexpected figure, check
41 d.1) eye position and target position are properly set,
42 d.2) light direction is properly set (note light direction is from
43 illumination light source to the objects),
44 d.3) span angle (given by angle for 100 pixels) is reasonable,
45 d.4) there is no surrounding volume(s) without transparency.
46
47 e) G4RayTracer can be executed ONLY AT "Idle" state.
48
49 5. Basic UI commands
50
51 a) /vis/rayTracer/eyePosition x y z unit
52 eye position
53
54 b) /vis/rayTracer/target x y z unit
55 target position
56 in default it is set to the origine
57
58 c) /vis/rayTracer/lightDirection ex ey ez
59 vector of the illuminating light (need not to be a unit vector)
60 note light direction is from illumination light source to the objects
61
62 d) /vis/rayTracer/column nColumn
63 number of holizontal pixels
64 in default 640 pixels
65
66 e) /vis/rayTracer/row nRow
67 number of virtical pixels
68 in default 640 pixels
69
70 f) /vis/rayTracer/span angle unit
71 angle for 100 pixels
72 in default 5 degree
73
74 g) /vis/rayTracer/trace fileName
75 execution of G4RayTracer
76 "fileName" is the out put JPEG file name
77 in default "g4RayTracer.jpeg"
78 NOTE THAT THIS COMMAND IS AVAILABLE ONLY AT IDLE STATE
79
80
81
82