#include <SteppingAction.hh>
Public Member Functions | |
SteppingAction (DetectorConstruction *, RunAction *) | |
~SteppingAction () | |
void | UserSteppingAction (const G4Step *) |
Private Attributes | |
DetectorConstruction * | m_detector |
RunAction * | m_runAction |
Definition at line 16 of file SteppingAction.hh.
SteppingAction::SteppingAction | ( | DetectorConstruction * | det, | |
RunAction * | run | |||
) |
SteppingAction::~SteppingAction | ( | ) |
void SteppingAction::UserSteppingAction | ( | const G4Step * | step | ) |
Definition at line 25 of file SteppingAction.cc.
00026 { 00027 // in which volume is the step ? 00028 G4VPhysicalVolume* volume 00029 = step->GetPreStepPoint()->GetTouchableHandle()->GetVolume(); 00030 00031 // energy deposit in this step 00032 G4double edep = step->GetTotalEnergyDeposit(); 00033 00034 // is astronaute ? 00035 if (volume == m_detector->GetAstronaut()) { 00036 G4cout << "--> edep in astronaut : " << edep/keV << " keV" << G4endl; 00037 m_runAction->AddEdep(edep); 00038 } 00039 }
DetectorConstruction* SteppingAction::m_detector [private] |
RunAction* SteppingAction::m_runAction [private] |