#include <VisualizationAction.h>
Definition at line 37 of file VisualizationAction.h.
larg4::VisualizationAction::VisualizationAction |
( |
| ) |
|
Definition at line 30 of file VisualizationAction.cxx.
32 art::ServiceHandle<sim::LArG4Parameters const> lgp;
util::quantities::gigaelectronvolt GeV
G4bool m_drawNeutrals
Whether or not to draw neutral tracks (default is no).
G4double m_energyCutoff
Don't draw particles with energies less than this cut.
larg4::VisualizationAction::~VisualizationAction |
( |
| ) |
|
|
virtual |
void larg4::VisualizationAction::BeginOfEventAction |
( |
const G4Event * |
| ) |
|
|
virtual |
void larg4::VisualizationAction::BeginOfRunAction |
( |
const G4Run * |
| ) |
|
|
virtual |
Definition at line 42 of file VisualizationAction.cxx.
45 if(G4VVisManager::GetConcreteInstance()){
46 G4cout <<
"Geant4 visualisation is ON" << G4endl;
47 G4UImanager* UI = G4UImanager::GetUIpointer();
48 UI->ApplyCommand(
"/tracking/storeTrajectory 1");
49 UI->ApplyCommand(
"/vis/scene/notifyhandlers");
void larg4::VisualizationAction::EndOfEventAction |
( |
const G4Event * |
a_event | ) |
|
|
virtual |
Definition at line 63 of file VisualizationAction.cxx.
65 G4VVisManager* pVVisManager = G4VVisManager::GetConcreteInstance();
69 G4TrajectoryContainer* trajectoryContainer = a_event->GetTrajectoryContainer();
70 G4int n_trajectories = 0;
71 if (trajectoryContainer)
72 n_trajectories = trajectoryContainer->entries();
74 for (G4int i=0; i < n_trajectories; i++)
76 G4VTrajectory* trajectory = (*trajectoryContainer)[i];
81 G4bool drawThisTrack =
false;
87 G4double charge = trajectory->GetCharge();
90 drawThisTrack =
false;
94 trajectory->DrawTrajectory();
G4bool m_drawNeutrals
Whether or not to draw neutral tracks (default is no).
G4double m_energyCutoff
Don't draw particles with energies less than this cut.
void larg4::VisualizationAction::EndOfRunAction |
( |
const G4Run * |
| ) |
|
|
virtual |
Definition at line 53 of file VisualizationAction.cxx.
56 if (G4VVisManager::GetConcreteInstance())
57 G4UImanager::GetUIpointer()->ApplyCommand(
"/vis/viewer/update");
G4double larg4::VisualizationAction::GetTrackEnergyCutoff |
( |
| ) |
const |
|
inline |
Acessors, if we need them:
Definition at line 49 of file VisualizationAction.h.
G4double m_energyCutoff
Don't draw particles with energies less than this cut.
void larg4::VisualizationAction::SetTrackEnergyCutoff |
( |
const G4double |
e | ) |
|
|
inline |
Definition at line 50 of file VisualizationAction.h.
G4double m_energyCutoff
Don't draw particles with energies less than this cut.
G4bool larg4::VisualizationAction::m_drawNeutrals |
|
private |
G4double larg4::VisualizationAction::m_energyCutoff |
|
private |
The documentation for this class was generated from the following files: