ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
G4VisCommandsSceneAdd.hh
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file G4VisCommandsSceneAdd.hh
1
//
2
// ********************************************************************
3
// * License and Disclaimer *
4
// * *
5
// * The Geant4 software is copyright of the Copyright Holders of *
6
// * the Geant4 Collaboration. It is provided under the terms and *
7
// * conditions of the Geant4 Software License, included in the file *
8
// * LICENSE and available at http://cern.ch/geant4/license . These *
9
// * include a list of copyright holders. *
10
// * *
11
// * Neither the authors of this software system, nor their employing *
12
// * institutes,nor the agencies providing financial support for this *
13
// * work make any representation or warranty, express or implied, *
14
// * regarding this software system or assume any liability for its *
15
// * use. Please see the license in the file LICENSE and URL above *
16
// * for the full disclaimer and the limitation of liability. *
17
// * *
18
// * This code implementation is the result of the scientific and *
19
// * technical work of the GEANT4 collaboration. *
20
// * By using, copying, modifying or distributing the software (or *
21
// * any work based on the software) you agree to acknowledge its *
22
// * use in resulting scientific publications, and indicate your *
23
// * acceptance of all terms of the Geant4 Software license. *
24
// ********************************************************************
25
//
26
//
27
28
// /vis/scene commands - John Allison 9th August 1998
29
// Michael Kelsey 31 Jan 2019 -- Add new command for electric field
30
31
#ifndef G4VISCOMMANDSSCENEADD_HH
32
#define G4VISCOMMANDSSCENEADD_HH
33
34
#include "
G4VisCommandsScene.hh
"
35
36
class
G4UIcmdWithoutParameter
;
37
class
G4UIcmdWithAString
;
38
class
G4UIcmdWithAnInteger
;
39
40
#include "
G4Transform3D.hh
"
41
#include "
G4VisAttributes.hh
"
42
#include "
G4Polyline.hh
"
43
#include "
G4Text.hh
"
44
#include "
G4Timer.hh
"
45
46
class
G4VisCommandSceneAddArrow
:
public
G4VVisCommandScene
{
47
public
:
48
G4VisCommandSceneAddArrow
();
49
virtual
~G4VisCommandSceneAddArrow
();
50
G4String
GetCurrentValue
(
G4UIcommand
* command);
51
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
52
private
:
53
G4VisCommandSceneAddArrow
(
const
G4VisCommandSceneAddArrow
&);
54
G4VisCommandSceneAddArrow
&
operator =
(
const
G4VisCommandSceneAddArrow
&);
55
G4UIcommand
*
fpCommand
;
56
};
57
58
class
G4VisCommandSceneAddArrow2D
:
public
G4VVisCommandScene
{
59
public
:
60
G4VisCommandSceneAddArrow2D
();
61
virtual
~G4VisCommandSceneAddArrow2D
();
62
G4String
GetCurrentValue
(
G4UIcommand
* command);
63
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
64
private
:
65
G4VisCommandSceneAddArrow2D
(
const
G4VisCommandSceneAddArrow2D
&);
66
G4VisCommandSceneAddArrow2D
&
operator =
(
const
G4VisCommandSceneAddArrow2D
&);
67
struct
Arrow2D
{
68
Arrow2D
(
G4double
x1
,
G4double
y1
,
69
G4double
x2
,
G4double
y2
,
70
G4double
width
,
const
G4Colour
& colour);
71
void
operator()
(
G4VGraphicsScene
&,
const
G4Transform3D
&,
const
G4ModelingParameters
* fpMp);
72
G4Polyline
fShaftPolyline
;
73
G4Polyline
fHeadPolyline
;
74
G4double
fWidth
;
75
G4Colour
fColour
;
76
};
77
G4UIcommand
*
fpCommand
;
78
};
79
80
class
G4VisCommandSceneAddAxes
:
public
G4VVisCommandScene
{
81
public
:
82
G4VisCommandSceneAddAxes
();
83
virtual
~G4VisCommandSceneAddAxes
();
84
G4String
GetCurrentValue
(
G4UIcommand
* command);
85
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
86
private
:
87
G4VisCommandSceneAddAxes
(
const
G4VisCommandSceneAddAxes
&);
88
G4VisCommandSceneAddAxes
&
operator =
(
const
G4VisCommandSceneAddAxes
&);
89
G4UIcommand
*
fpCommand
;
90
};
91
92
class
G4VisCommandSceneAddDate
:
public
G4VVisCommandScene
{
93
public
:
94
G4VisCommandSceneAddDate
();
95
virtual
~G4VisCommandSceneAddDate
();
96
G4String
GetCurrentValue
(
G4UIcommand
* command);
97
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
98
private
:
99
G4VisCommandSceneAddDate
(
const
G4VisCommandSceneAddDate
&);
100
G4VisCommandSceneAddDate
&
operator =
(
const
G4VisCommandSceneAddDate
&);
101
struct
Date
{
102
Date
103
(
G4VisManager
* vm,
G4int
size,
104
G4double
x
,
G4double
y
,
G4Text::Layout
layout,
105
const
G4String
& date):
106
fpVisManager
(vm),
fSize
(size),
107
fX
(x),
fY
(y),
fLayout
(layout),
fDate
(date) {}
108
void
operator()
(
G4VGraphicsScene
&,
const
G4Transform3D
&,
const
G4ModelingParameters
*);
109
G4VisManager
*
fpVisManager
;
110
G4Timer
fTimer
;
111
G4int
fSize
;
112
G4double
fX
,
fY
;
113
G4Text::Layout
fLayout
;
114
G4String
fDate
;
115
};
116
G4UIcommand
*
fpCommand
;
117
};
118
119
class
G4VisCommandSceneAddDigis
:
public
G4VVisCommandScene
{
120
public
:
121
G4VisCommandSceneAddDigis
();
122
virtual
~G4VisCommandSceneAddDigis
();
123
G4String
GetCurrentValue
(
G4UIcommand
* command);
124
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
125
private
:
126
G4VisCommandSceneAddDigis
(
const
G4VisCommandSceneAddDigis
&);
127
G4VisCommandSceneAddDigis
&
operator =
(
const
G4VisCommandSceneAddDigis
&);
128
G4UIcmdWithoutParameter
*
fpCommand
;
129
};
130
131
class
G4VisCommandSceneAddEventID
:
public
G4VVisCommandScene
{
132
public
:
133
G4VisCommandSceneAddEventID
();
134
virtual
~G4VisCommandSceneAddEventID
();
135
G4String
GetCurrentValue
(
G4UIcommand
* command);
136
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
137
private
:
138
G4VisCommandSceneAddEventID
(
const
G4VisCommandSceneAddEventID
&);
139
G4VisCommandSceneAddEventID
&
operator =
(
const
G4VisCommandSceneAddEventID
&);
140
enum
ForWhat
{
forEndOfEvent
,
forEndOfRun
};
141
struct
EventID
{
142
EventID
(
ForWhat
w
,
G4VisManager
* vm,
G4int
size,
143
G4double
x
,
G4double
y
,
G4Text::Layout
layout):
144
fForWhat
(w),
fpVisManager
(vm),
fSize
(size),
145
fX
(x),
fY
(y),
fLayout
(layout) {}
146
void
operator()
(
G4VGraphicsScene
&,
const
G4Transform3D
&,
const
G4ModelingParameters
*);
147
ForWhat
fForWhat
;
148
G4VisManager
*
fpVisManager
;
149
G4int
fSize
;
150
G4double
fX
,
fY
;
151
G4Text::Layout
fLayout
;
152
};
153
G4UIcommand
*
fpCommand
;
154
};
155
156
class
G4VisCommandSceneAddExtent
:
public
G4VVisCommandScene
{
157
public
:
158
G4VisCommandSceneAddExtent
();
159
virtual
~G4VisCommandSceneAddExtent
();
160
G4String
GetCurrentValue
(
G4UIcommand
* command);
161
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
162
private
:
163
G4VisCommandSceneAddExtent
(
const
G4VisCommandSceneAddExtent
&);
164
G4VisCommandSceneAddExtent
&
operator =
(
const
G4VisCommandSceneAddExtent
&);
165
struct
Extent
{
166
Extent
(
G4double
xmin
,
G4double
xmax
,
167
G4double
ymin
,
G4double
ymax
,
168
G4double
zmin,
G4double
zmax);
169
void
operator()
(
G4VGraphicsScene
&,
const
G4Transform3D
&,
const
G4ModelingParameters
*);
170
G4VisExtent
fExtent
;
171
};
172
G4UIcommand
*
fpCommand
;
173
};
174
175
class
G4VisCommandSceneAddElectricField
:
public
G4VVisCommandScene
{
176
public
:
177
G4VisCommandSceneAddElectricField
();
178
virtual
~G4VisCommandSceneAddElectricField
();
179
G4String
GetCurrentValue
(
G4UIcommand
* command);
180
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
181
private
:
182
G4VisCommandSceneAddElectricField
(
const
G4VisCommandSceneAddElectricField
&);
183
G4VisCommandSceneAddElectricField
&
operator =
(
const
G4VisCommandSceneAddElectricField
&);
184
G4UIcommand
*
fpCommand
;
185
};
186
187
class
G4VisCommandSceneAddFrame
:
public
G4VVisCommandScene
{
188
public
:
189
G4VisCommandSceneAddFrame
();
190
virtual
~G4VisCommandSceneAddFrame
();
191
G4String
GetCurrentValue
(
G4UIcommand
* command);
192
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
193
private
:
194
G4VisCommandSceneAddFrame
(
const
G4VisCommandSceneAddFrame
&);
195
G4VisCommandSceneAddFrame
&
operator =
(
const
G4VisCommandSceneAddFrame
&);
196
struct
Frame
{
197
Frame
(
G4double
size,
G4double
width,
const
G4Colour
& colour):
198
fSize
(size),
fWidth
(width),
fColour
(colour) {}
199
void
operator()
(
G4VGraphicsScene
&,
const
G4Transform3D
&,
const
G4ModelingParameters
*);
200
G4double
fSize
;
201
G4double
fWidth
;
202
G4Colour
fColour
;
203
};
204
G4UIcommand
*
fpCommand
;
205
};
206
207
class
G4VisCommandSceneAddGPS
:
public
G4VVisCommandScene
{
208
public
:
209
G4VisCommandSceneAddGPS
();
210
virtual
~G4VisCommandSceneAddGPS
();
211
G4String
GetCurrentValue
(
G4UIcommand
* command);
212
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
213
private
:
214
G4VisCommandSceneAddGPS
(
const
G4VisCommandSceneAddGPS
&);
215
G4VisCommandSceneAddGPS
&
operator =
(
const
G4VisCommandSceneAddGPS
&);
216
G4UIcommand
*
fpCommand
;
217
};
218
219
class
G4VisCommandSceneAddGhosts
:
public
G4VVisCommandScene
{
220
public
:
221
G4VisCommandSceneAddGhosts
();
222
virtual
~G4VisCommandSceneAddGhosts
();
223
G4String
GetCurrentValue
(
G4UIcommand
* command);
224
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
225
private
:
226
G4VisCommandSceneAddGhosts
(
const
G4VisCommandSceneAddGhosts
&);
227
G4VisCommandSceneAddGhosts
&
operator
=
228
(
const
G4VisCommandSceneAddGhosts
&);
229
G4UIcmdWithAString
*
fpCommand
;
230
};
231
232
class
G4VisCommandSceneAddHits
:
public
G4VVisCommandScene
{
233
public
:
234
G4VisCommandSceneAddHits
();
235
virtual
~G4VisCommandSceneAddHits
();
236
G4String
GetCurrentValue
(
G4UIcommand
* command);
237
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
238
private
:
239
G4VisCommandSceneAddHits
(
const
G4VisCommandSceneAddHits
&);
240
G4VisCommandSceneAddHits
&
operator =
(
const
G4VisCommandSceneAddHits
&);
241
G4UIcmdWithoutParameter
*
fpCommand
;
242
};
243
244
class
G4VisCommandSceneAddLine
:
public
G4VVisCommandScene
{
245
public
:
246
G4VisCommandSceneAddLine
();
247
virtual
~G4VisCommandSceneAddLine
();
248
G4String
GetCurrentValue
(
G4UIcommand
* command);
249
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
250
private
:
251
G4VisCommandSceneAddLine
(
const
G4VisCommandSceneAddLine
&);
252
G4VisCommandSceneAddLine
&
operator =
(
const
G4VisCommandSceneAddLine
&);
253
struct
Line
{
254
Line
(
G4double
x1
,
G4double
y1
,
G4double
z1
,
255
G4double
x2
,
G4double
y2
,
G4double
z2
,
256
G4double
width
,
const
G4Colour
& colour);
257
void
operator()
(
G4VGraphicsScene
&,
const
G4Transform3D
&,
const
G4ModelingParameters
*);
258
G4Polyline
fPolyline
;
259
G4double
fWidth
;
260
G4Colour
fColour
;
261
};
262
G4UIcommand
*
fpCommand
;
263
};
264
265
class
G4VisCommandSceneAddLine2D
:
public
G4VVisCommandScene
{
266
public
:
267
G4VisCommandSceneAddLine2D
();
268
virtual
~G4VisCommandSceneAddLine2D
();
269
G4String
GetCurrentValue
(
G4UIcommand
* command);
270
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
271
private
:
272
G4VisCommandSceneAddLine2D
(
const
G4VisCommandSceneAddLine2D
&);
273
G4VisCommandSceneAddLine2D
&
operator =
(
const
G4VisCommandSceneAddLine2D
&);
274
struct
Line2D
{
275
Line2D
(
G4double
x1
,
G4double
y1
,
276
G4double
x2
,
G4double
y2
,
277
G4double
width
,
const
G4Colour
& colour);
278
void
operator()
(
G4VGraphicsScene
&,
const
G4Transform3D
&,
const
G4ModelingParameters
*);
279
G4Polyline
fPolyline
;
280
G4double
fWidth
;
281
G4Colour
fColour
;
282
};
283
G4UIcommand
*
fpCommand
;
284
};
285
286
class
G4VisCommandSceneAddLogicalVolume
:
public
G4VVisCommandScene
{
287
public
:
288
G4VisCommandSceneAddLogicalVolume
();
289
virtual
~G4VisCommandSceneAddLogicalVolume
();
290
G4String
GetCurrentValue
(
G4UIcommand
* command);
291
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
292
private
:
293
G4VisCommandSceneAddLogicalVolume
(
const
G4VisCommandSceneAddLogicalVolume
&);
294
G4VisCommandSceneAddLogicalVolume
&
operator
=
295
(
const
G4VisCommandSceneAddLogicalVolume
&);
296
G4UIcommand
*
fpCommand
;
297
};
298
299
class
G4VisCommandSceneAddLogo
:
public
G4VVisCommandScene
{
300
public
:
301
G4VisCommandSceneAddLogo
();
302
virtual
~G4VisCommandSceneAddLogo
();
303
G4String
GetCurrentValue
(
G4UIcommand
* command);
304
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
305
private
:
306
G4VisCommandSceneAddLogo
(
const
G4VisCommandSceneAddLogo
&);
307
G4VisCommandSceneAddLogo
&
operator =
(
const
G4VisCommandSceneAddLogo
&);
308
// Direction of outward-facing normal to front face of logo.
309
enum
Direction
{
X
,
minusX
,
Y
,
minusY
,
Z
,
minusZ
};
310
struct
G4Logo
{
311
G4Logo
(
G4double
height,
const
G4VisAttributes
&);
312
~G4Logo
();
313
void
operator()
(
G4VGraphicsScene
&,
const
G4Transform3D
&,
const
G4ModelingParameters
*);
314
private
:
315
G4VisAttributes
fVisAtts
;
316
G4Polyhedron
*
fpG
, *
fp4
;
317
};
318
G4UIcommand
*
fpCommand
;
319
};
320
321
class
G4VisCommandSceneAddLogo2D
:
public
G4VVisCommandScene
{
322
public
:
323
G4VisCommandSceneAddLogo2D
();
324
virtual
~G4VisCommandSceneAddLogo2D
();
325
G4String
GetCurrentValue
(
G4UIcommand
* command);
326
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
327
private
:
328
G4VisCommandSceneAddLogo2D
(
const
G4VisCommandSceneAddLogo2D
&);
329
G4VisCommandSceneAddLogo2D
&
operator =
(
const
G4VisCommandSceneAddLogo2D
&);
330
struct
Logo2D
{
331
Logo2D
332
(
G4VisManager
* vm,
G4int
size,
333
G4double
x
,
G4double
y
,
G4Text::Layout
layout):
334
fpVisManager
(vm),
fSize
(size),
335
fX
(x),
fY
(y),
fLayout
(layout) {}
336
void
operator()
(
G4VGraphicsScene
&,
const
G4Transform3D
&,
const
G4ModelingParameters
*);
337
G4VisManager
*
fpVisManager
;
338
G4int
fSize
;
339
G4double
fX
,
fY
;
340
G4Text::Layout
fLayout
;
341
};
342
G4UIcommand
*
fpCommand
;
343
};
344
345
class
G4VisCommandSceneAddMagneticField
:
public
G4VVisCommandScene
{
346
public
:
347
G4VisCommandSceneAddMagneticField
();
348
virtual
~G4VisCommandSceneAddMagneticField
();
349
G4String
GetCurrentValue
(
G4UIcommand
* command);
350
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
351
private
:
352
G4VisCommandSceneAddMagneticField
(
const
G4VisCommandSceneAddMagneticField
&);
353
G4VisCommandSceneAddMagneticField
&
operator =
(
const
G4VisCommandSceneAddMagneticField
&);
354
G4UIcommand
*
fpCommand
;
355
};
356
357
class
G4VisCommandSceneAddPSHits
:
public
G4VVisCommandScene
{
358
public
:
359
G4VisCommandSceneAddPSHits
();
360
virtual
~G4VisCommandSceneAddPSHits
();
361
G4String
GetCurrentValue
(
G4UIcommand
* command);
362
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
363
private
:
364
G4VisCommandSceneAddPSHits
(
const
G4VisCommandSceneAddPSHits
&);
365
G4VisCommandSceneAddPSHits
&
operator =
(
const
G4VisCommandSceneAddPSHits
&);
366
G4UIcmdWithAString
*
fpCommand
;
367
};
368
369
class
G4VisCommandSceneAddScale
:
public
G4VVisCommandScene
{
370
public
:
371
G4VisCommandSceneAddScale
();
372
virtual
~G4VisCommandSceneAddScale
();
373
G4String
GetCurrentValue
(
G4UIcommand
* command);
374
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
375
private
:
376
G4VisCommandSceneAddScale
(
const
G4VisCommandSceneAddScale
&);
377
G4VisCommandSceneAddScale
&
operator =
(
const
G4VisCommandSceneAddScale
&);
378
G4UIcommand
*
fpCommand
;
379
};
380
381
class
G4VisCommandSceneAddText
:
public
G4VVisCommandScene
{
382
public
:
383
G4VisCommandSceneAddText
();
384
virtual
~G4VisCommandSceneAddText
();
385
G4String
GetCurrentValue
(
G4UIcommand
* command);
386
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
387
private
:
388
G4VisCommandSceneAddText
(
const
G4VisCommandSceneAddText
&);
389
G4VisCommandSceneAddText
&
operator =
(
const
G4VisCommandSceneAddText
&);
390
G4UIcommand
*
fpCommand
;
391
};
392
393
class
G4VisCommandSceneAddText2D
:
public
G4VVisCommandScene
{
394
public
:
395
G4VisCommandSceneAddText2D
();
396
virtual
~G4VisCommandSceneAddText2D
();
397
G4String
GetCurrentValue
(
G4UIcommand
* command);
398
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
399
private
:
400
G4VisCommandSceneAddText2D
(
const
G4VisCommandSceneAddText2D
&);
401
G4VisCommandSceneAddText2D
&
operator =
(
const
G4VisCommandSceneAddText2D
&);
402
struct
G4Text2D
{
403
G4Text2D
(
const
G4Text
&);
404
void
operator()
(
G4VGraphicsScene
&,
const
G4Transform3D
&,
const
G4ModelingParameters
*);
405
private
:
406
G4Text
fText
;
407
};
408
G4UIcommand
*
fpCommand
;
409
};
410
411
class
G4VisCommandSceneAddTrajectories
:
public
G4VVisCommandScene
{
412
public
:
413
G4VisCommandSceneAddTrajectories
();
414
virtual
~G4VisCommandSceneAddTrajectories
();
415
G4String
GetCurrentValue
(
G4UIcommand
* command);
416
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
417
private
:
418
G4VisCommandSceneAddTrajectories
(
const
G4VisCommandSceneAddTrajectories
&);
419
G4VisCommandSceneAddTrajectories
&
operator
=
420
(
const
G4VisCommandSceneAddTrajectories
&);
421
G4UIcmdWithAString
*
fpCommand
;
422
};
423
424
class
G4VisCommandSceneAddUserAction
:
public
G4VVisCommandScene
{
425
public
:
426
G4VisCommandSceneAddUserAction
();
427
virtual
~G4VisCommandSceneAddUserAction
();
428
G4String
GetCurrentValue
(
G4UIcommand
* command);
429
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
430
private
:
431
G4VisCommandSceneAddUserAction
(
const
G4VisCommandSceneAddUserAction
&);
432
G4VisCommandSceneAddUserAction
&
operator =
(
const
G4VisCommandSceneAddUserAction
&);
433
enum
ActionType
{
runDuration
,
endOfEvent
,
endOfRun
};
434
void
AddVisAction
(
const
G4String
&
name
,
G4VUserVisAction
*,
435
G4Scene
*,
ActionType
,
G4VisManager::Verbosity
);
436
G4UIcmdWithAString
*
fpCommand
;
437
};
438
439
class
G4VisCommandSceneAddVolume
:
public
G4VVisCommandScene
{
440
public
:
441
G4VisCommandSceneAddVolume
();
442
virtual
~G4VisCommandSceneAddVolume
();
443
G4String
GetCurrentValue
(
G4UIcommand
* command);
444
void
SetNewValue
(
G4UIcommand
* command,
G4String
newValue);
445
private
:
446
G4VisCommandSceneAddVolume
(
const
G4VisCommandSceneAddVolume
&);
447
G4VisCommandSceneAddVolume
&
operator =
(
const
G4VisCommandSceneAddVolume
&);
448
G4UIcommand
*
fpCommand
;
449
};
450
451
#endif
geant4
tree
geant4-10.6-release
source
visualization
management
include
G4VisCommandsSceneAdd.hh
Built by
Jin Huang
. updated:
Wed Jun 29 2022 17:25:55
using
1.8.2 with
ECCE GitHub integration