12 #include <Geant4/G4Step.hh>
13 #include <Geant4/G4StepPoint.hh>
14 #include <Geant4/G4SystemOfUnits.hh>
15 #include <Geant4/G4ThreeVector.hh>
16 #include <Geant4/G4TouchableHandle.hh>
17 #include <Geant4/G4Track.hh>
18 #include <Geant4/G4Types.hh>
19 #include <Geant4/G4VTouchable.hh>
20 #include <Geant4/G4VUserTrackInformation.hh>
26 class G4VPhysicalVolume;
39 G4VPhysicalVolume*
volume = aStep->GetPreStepPoint()->GetTouchableHandle()->GetVolume();
48 if ((aStep->GetTotalEnergyDeposit() /
GeV) == 0.)
54 G4StepPoint* prePoint = aStep->GetPreStepPoint();
56 G4Track* aTrack = aStep->GetTrack();
58 G4double x_center, y_center, z_center;
60 unsigned int hit_index =
detector_->
computeIndex(layer_id, prePoint->GetPosition().x(), prePoint->GetPosition().y(), prePoint->GetPosition().z(), x_center, y_center, z_center);
65 mhit->
set_x(0, x_center);
66 mhit->
set_y(0, y_center);
67 mhit->
set_z(0, z_center);
68 mhit->
set_edep((aStep->GetTotalEnergyDeposit() /
GeV) + it->second->get_edep());
72 if (G4VUserTrackInformation*
p = aTrack->GetUserInformation())
81 std::cout <<
"WARNING: Unknown UserTrackInformation stored in track" << std::endl;
88 aTrack->SetUserInformation(pv);
94 if (G4VUserTrackInformation*
p = aTrack->GetUserInformation())
105 if (G4VUserTrackInformation*
p = aTrack->GetUserInformation())
118 hits_ = findNode::getClass<PHG4HitContainer>(topNode,
"G4HIT_FCAL");
123 std::cout <<
"PHG4FCalSteppingAction::SetTopNode - unable to find G4HIT_FCAL" << std::endl;