- Timestamp:
- Sep 30, 2010, 2:47:17 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/examples/extended/field/field02/src/F02EventAction.cc
r1230 r1337 25 25 // 26 26 // 27 // $Id: F02EventAction.cc,v 1. 6 2006/06/29 17:18:02 gunterExp $28 // GEANT4 tag $Name: geant4-09-0 3-cand-01 $27 // $Id: F02EventAction.cc,v 1.7 2010/06/06 04:55:59 perl Exp $ 28 // GEANT4 tag $Name: geant4-09-04-beta-01 $ 29 29 // 30 30 // … … 45 45 #include "G4VHitsCollection.hh" 46 46 #include "G4SDManager.hh" 47 #include "G4TrajectoryContainer.hh"48 #include "G4Trajectory.hh"49 #include "G4VVisManager.hh"50 47 #include "G4ios.hh" 51 48 #include "G4UnitsTable.hh" … … 91 88 void F02EventAction::EndOfEventAction(const G4Event* evt) 92 89 { 93 G4VVisManager* pVVisManager = G4VVisManager::GetConcreteInstance();94 95 if(pVVisManager)96 {97 G4TrajectoryContainer* trajectoryContainer = evt->GetTrajectoryContainer();98 G4int n_trajectories = 0;99 if (trajectoryContainer) n_trajectories = trajectoryContainer->entries();100 for(G4int i=0; i<n_trajectories; i++)101 { G4Trajectory* trj = (G4Trajectory *)((*(evt->GetTrajectoryContainer()))[i]);102 if (drawFlag == "all") trj->DrawTrajectory(50);103 else if ((drawFlag == "charged")&&(trj->GetCharge() != 0.))104 trj->DrawTrajectory(50);105 }106 }107 108 90 if(verboselevel>0) 109 91 G4cout << "<<< Event " << evt->GetEventID() << " ended." << G4endl;
Note: See TracChangeset
for help on using the changeset viewer.