76 G4int iRow = evId / nColumn;
77 G4int iColumn = evId % nColumn;
82 { rayDirection =
G4ThreeVector(-std::tan(angleX)/std::cos(angleY),std::tan(angleY)/std::cos(angleX),1.0); }
84 { rayDirection =
G4ThreeVector(-std::tan(angleX),std::tan(angleY),1.0); }
85 G4double cp = std::cos(eyeDirection.phi());
87 G4double ct = std::cos(eyeDirection.theta());
89 G4double gam = std::atan2(ct*cp*up.x()+ct*sp*up.y()-st*up.z(), -sp*up.x()+cp*up.y());
91 rayDirection.
rotateZ(headAngle);
97 G4double outsideDistance = pWorld->GetLogicalVolume()->GetSolid()->
98 DistanceToIn(rayPosition,rayDirection);
99 if(outsideDistance != kInfinity)
100 { rayPosition = rayPosition + (outsideDistance+0.001)*rayDirection; }
113 G4double mass = particle_definition->GetPDGMass();
119 particle_polarization.y(),
120 particle_polarization.z());
129 particle_definition = particleTable->
FindParticle(
"geantino");
130 if(!particle_definition)
133 msg =
" G4RayTracer uses geantino to trace the ray, but your physics list does not\n";
134 msg +=
"define G4Geantino. Please add G4Geantino in your physics list.";
144 stepAngle = viewSpan/100.;
145 viewSpanX = stepAngle*nColumn;
146 viewSpanY = stepAngle*nRow;
150 GetNavigatorForTracking()->GetWorldVolume();
151 whereisit = pWorld->GetLogicalVolume()->GetSolid()->Inside(eyePosition);
G4ParticleDefinition * FindParticle(G4int PDGEncoding)
static G4ParticleTable * GetParticleTable()
void SetPolarization(const G4ThreeVector &pol)
void SetKineticEnergy(G4double eKin)
void SetMomentumDirection(const G4ThreeVector &p)
void SetMass(G4double mas)