40#include "G4VPhysicalVolume.hh"
42#include "G4VTouchable.hh"
43#include "G4TouchableHistory.hh"
44#include "G4SDManager.hh"
51 fCalCollection(nullptr),
53 fHitID(new G4int[500])
55 collectionName.insert(
"CalCollection");
70 (SensitiveDetectorName,collectionName[0]);
71 for (G4int j=0;j<1; j++) {
fHitID[j] = -1;};
78 G4double edep = step->GetTotalEnergyDeposit();
81 stepl = step->GetStepLength();
83 if ((edep == 0.) && (stepl == 0.) )
return false;
97 G4cout <<
" New Calorimeter Hit on F03: " << number << G4endl;
102 (*fCalCollection)[
fHitID[number]]->AddAbs(edep,stepl);
104 G4cout <<
" Energy added to F03: " << number << G4endl;
113 static G4int hcID = -1;
115 { hcID = G4SDManager::GetSDMpointer()->GetCollectionID(collectionName[0]); }
Definition of the F03CalorHit class.
G4THitsCollection< F03CalorHit > F03CalorHitsCollection
Definition of the F03CalorimeterSD class.
Definition of the F03DetectorConstruction class.
F03CalorHitsCollection * fCalCollection
G4bool ProcessHits(G4Step *, G4TouchableHistory *) override
void Initialize(G4HCofThisEvent *) override
F03DetectorConstruction * fDetector
F03CalorimeterSD(G4String, F03DetectorConstruction *)
~F03CalorimeterSD() override
void EndOfEvent(G4HCofThisEvent *) override
const G4VPhysicalVolume * GetAbsorber()