Geant4  10.02.p03
python.g4viscp.G4Scene Class Reference
Collaboration diagram for python.g4viscp.G4Scene:

Public Member Functions

def __init__ (self, aname, vol="world", acopyno=0, amode=0, bmode=1)
 
def create_scene (self)
 
def update_scene (self)
 

Public Attributes

 name
 
 volume
 
 copyno
 
 mode_eventaction
 
 mode_runaction
 
 mode
 

Detailed Description

Definition at line 16 of file g4viscp.py.

Constructor & Destructor Documentation

◆ __init__()

def python.g4viscp.G4Scene.__init__ (   self,
  aname,
  vol = "world",
  acopyno = 0,
  amode = 0,
  bmode = 1 
)

Definition at line 19 of file g4viscp.py.

19  amode=0, bmode=1):
20  self.name= aname
21  self.volume= vol
22  self.copyno= acopyno
23  self.mode_eventaction= amode # 0: accumulate / 1: refresh
24  self.mode_runaction= bmode # 0: accumulate / 1: refresh
25  self.mode= ("accumulate", "refresh")
26 

Member Function Documentation

◆ create_scene()

def python.g4viscp.G4Scene.create_scene (   self)

Definition at line 27 of file g4viscp.py.

27  def create_scene(self):
28  ApplyUICommand("/vis/scene/create " + self.name)
29  ApplyUICommand("/vis/scene/add/volume %s %d" %
30  (self.volume, self.copyno))
31  ApplyUICommand("/vis/scene/add/trajectories")
32  self.update_scene()
33 
Here is the call graph for this function:

◆ update_scene()

def python.g4viscp.G4Scene.update_scene (   self)

Definition at line 34 of file g4viscp.py.

34  def update_scene(self):
35  ApplyUICommand("/vis/scene/select " + self.name)
36  ApplyUICommand("/vis/sceneHandler/attach")
37  ApplyUICommand("/vis/scene/endOfEventAction %s" %
38  (self.mode[self.mode_eventaction]) )
39  ApplyUICommand("/vis/scene/endOfRunAction %s" %
40  (self.mode[self.mode_runaction]) )
41 
42 # ------------------------------------------------------------------
43 # Visualization Control Panel
44 # ------------------------------------------------------------------
Here is the caller graph for this function:

Member Data Documentation

◆ copyno

python.g4viscp.G4Scene.copyno

Definition at line 22 of file g4viscp.py.

◆ mode

python.g4viscp.G4Scene.mode

Definition at line 25 of file g4viscp.py.

◆ mode_eventaction

python.g4viscp.G4Scene.mode_eventaction

Definition at line 23 of file g4viscp.py.

◆ mode_runaction

python.g4viscp.G4Scene.mode_runaction

Definition at line 24 of file g4viscp.py.

◆ name

python.g4viscp.G4Scene.name

Definition at line 20 of file g4viscp.py.

◆ volume

python.g4viscp.G4Scene.volume

Definition at line 21 of file g4viscp.py.


The documentation for this class was generated from the following file: