75{
76
77
78
79
80
81 G4double edep = aStep->GetTotalEnergyDeposit();
82 if(verboseLevel>1) G4cout << "Next step edep(MeV) = " << edep/MeV << G4endl;
83 if(edep==0.) return false;
84
85 const G4VTouchable* touchable = aStep->GetPreStepPoint()->GetTouchable();
86 G4int copyIDinZ = touchable->GetReplicaNumber(0);
87 G4int copyIDinPhi = touchable->GetReplicaNumber(1);
88
89 if(
fCellID[copyIDinZ][copyIDinPhi]==-1)
90 {
93 (touchable->GetVolume()->GetLogicalVolume(),copyIDinZ,copyIDinPhi);
96 aTrans.Invert();
97 calHit->
SetPos(aTrans.NetTranslation());
98 calHit->
SetRot(aTrans.NetRotation());
100 fCellID[copyIDinZ][copyIDinPhi] = icell - 1;
101 if(verboseLevel>0)
102 { G4cout << " New Calorimeter Hit on fCellID "
103 << copyIDinZ << " " << copyIDinPhi << G4endl; }
104 }
105 else
106 {
107 (*fCalCollection)[
fCellID[copyIDinZ][copyIDinPhi]]->AddEdep(edep);
108 if(verboseLevel>0)
109 { G4cout << " Energy added to fCellID "
110 << copyIDinZ << " " << copyIDinPhi << G4endl; }
111 }
112
113 return true;
114}
void SetEdep(G4double de)
void SetRot(G4RotationMatrix rmat)
void SetPos(G4ThreeVector xyz)