9 #include "G4Geantino.hh" 
   10 #include "G4ChargedGeantino.hh" 
   16   : G4VSensitiveDetector( 
name )
 
   19   , m_myTGCHitColl( hitCollectionName )
 
   36   G4Track* 
track = aStep->GetTrack();
 
   38   if (
track->GetDefinition()->GetPDGCharge() == 0.0) {
 
   39     if (
track->GetDefinition()!=G4Geantino::GeantinoDefinition()) 
return true;
 
   40     else if (
track->GetDefinition()==G4ChargedGeantino::ChargedGeantinoDefinition()) 
return true;
 
   42   const G4TouchableHistory* touchHist = 
static_cast<const G4TouchableHistory*
>(aStep->GetPreStepPoint()->GetTouchable());
 
   43   G4ThreeVector           position  = aStep->GetPreStepPoint()->GetPosition();
 
   44   const G4AffineTransform trans     = 
track->GetTouchable()->GetHistory()->GetTopTransform();
 
   53   double globalTime        = aStep->GetPreStepPoint()->GetGlobalTime();
 
   55   G4ThreeVector direcos    = aStep->GetPreStepPoint()->GetMomentumDirection();
 
   60   G4ThreeVector globVrtx = aStep->GetPreStepPoint()->GetPosition();
 
   63   double dist = globVrtx.mag();
 
   65   double tOrigin = dist * inv_lightspeed;
 
   67   G4int trackid = aStep->GetTrack()->GetTrackID();
 
   82   double globalDist = sqrt((
m_globH[0] - globVrtx[0])*(
m_globH[0] - globVrtx[0]) +
 
   85   double tof = globalDist * inv_lightspeed;
 
   90   for (
int i=touchHist->GetHistoryDepth();
i>=0;
i--) {
 
   92     std::string::size_type npos;
 
   93     std::string volName = touchHist->GetVolume(
i)->GetName();
 
   96     if ((npos = volName.find(
"station")) != std::string::npos) {
 
   99       int volCopyNo = touchHist->GetVolume(
i)->GetCopyNo();
 
  108         if (abs(volCopyNo/100) > 3) {
 
  122           stationPhi = (abs(volCopyNo%100)-1)*3+abs(volCopyNo/100);
 
  124           if (abs(volCopyNo%100) < 4) {
 
  129           } 
else if(abs(volCopyNo%100) < 7) {
 
  137           stationPhi = (abs(volCopyNo%100)-1)*6+abs(volCopyNo/100);
 
  147     } 
else if ((npos = volName.find(
"tgccomponent")) != std::string::npos) {
 
  148       int volCopyNo = abs(touchHist->GetVolume(
i)->GetCopyNo());
 
  150       if (volCopyNo > 1000) { 
 
  155     } 
else if ((npos = volName.find(
"Gas Volume Layer")) != std::string::npos) {
 
  156       int volCopyNo = touchHist->GetVolume(
i)->GetCopyNo();
 
  160           gasGap = 3-(volCopyNo-3)/4;
 
  162           gasGap = 2-(volCopyNo-3)/4;
 
  165           gasGap = (volCopyNo-3)/4+1;
 
  169     } 
else if ((npos = volName.find(
"TGCGas")) != std::string::npos) {
 
  171       int volCopyNo = touchHist->GetVolume(
i)->GetCopyNo();
 
  199                         aStep->GetTotalEnergyDeposit(),
 
  200                         aStep->GetStepLength());