35#include "G4VPhysicalVolume.hh"
36#include "G4LogicalVolume.hh"
38#include "G4ParticleDefinition.hh"
39#include "G4SDManager.hh"
48 fNumberOfCells(nCells),
52 collectionName.insert(HCname=colName);
68 (SensitiveDetectorName,collectionName[0]);
79 G4double edep = aStep->GetTotalEnergyDeposit();
80 if(edep<=0.)
return false;
84 G4int copyID = hist->GetReplicaNumber();
93 calHit->
SetPos(aTrans.NetTranslation());
94 calHit->
SetRot(aTrans.NetRotation());
98 { G4cout <<
" New Calorimeter Hit on CellID " << copyID << G4endl; }
102 (*fCalCollection)[
fCellID[copyID]]->AddEdep( edep );
104 { G4cout <<
" Energy added to CellID " << copyID << G4endl; }
115 {
fHCID = G4SDManager::GetSDMpointer()->GetCollectionID(collectionName[0]); }
Definition of the Par01CalorimeterHit class.
G4THitsCollection< Par01CalorimeterHit > Par01CalorimeterHitsCollection
Definition of the Par01CalorimeterSD class.
void SetEdep(G4double de)
void SetRot(G4RotationMatrix rmat)
void SetPos(G4ThreeVector xyz)
Par01CalorimeterHitsCollection * fCalCollection
virtual void Initialize(G4HCofThisEvent *HCE)
virtual void EndOfEvent(G4HCofThisEvent *HCE)
Par01CalorimeterSD(G4String name, G4int nCells, G4String colName)
virtual G4bool ProcessHits(G4Step *aStep, G4TouchableHistory *ROhist)