105 G4cerr <<
"Illegal application state - Trace() ignored." <<
G4endl;
111 G4cerr <<
"Figure file maker class is not specified - Trace() ignored." <<
G4endl;
117 if(storeTrajectory==0) UI->
ApplyCommand(
"/tracking/storeTrajectory 1");
132 G4cerr <<
"You might set the eye position outside of the world volume" <<
G4endl; }
135 if(storeTrajectory==0) UI->
ApplyCommand(
"/tracking/storeTrajectory 0");
193 GetNavigatorForTracking()->GetWorldVolume();
198 for (
G4int j=0; j < pVector->
size(); ++j) {
222 G4double angleX = -(viewSpanX/2. - (iColumn+dColumn)*stepAngle);
223 G4double angleY = viewSpanY/2. - (iRow+dRow)*stepAngle;
227 rayDirection =
G4ThreeVector(-std::tan(angleX)/std::cos(angleY),std::tan(angleY)/std::cos(angleX),1.0);
231 rayDirection =
G4ThreeVector(-std::tan(angleX),std::tan(angleY),1.0);
242 G4bool interceptable =
true;
250 DistanceToIn(rayPosition,rayDirection);
251 if (outsideDistance != kInfinity) {
256 rayPosition = rayPosition+(outsideDistance+0.001)*rayDirection;
259 interceptable =
false;
280 if(!succeeded)
return false;
298 if(!trajectory)
return false;
301 if(nPoint==0)
return false;
308 for(
int i=nPoint-2;i>=0;i--)
325 return G4Colour(red,green,blue,alpha);
338 if(!preVis&&!postVis)
return transparent;
355 { preCol = transparent; }
367 { postCol = transparent; }
369 if(!preVis)
return postCol;
370 if(!postVis)
return preCol;
381 if(!visible)
return sourceCol;
391 if(stepAlpha > 0.9999999){ stepAlpha = 0.9999999; }
394 G4double KtRed = std::exp((1.0-stepRed)*attenuationFuctor);
395 G4double KtGreen = std::exp((1.0-stepGreen)*attenuationFuctor);
396 G4double KtBlue = std::exp((1.0-stepBlue)*attenuationFuctor);
397 if(KtRed>1.0){KtRed=1.0;}
398 if(KtGreen>1.0){KtGreen=1.0;}
399 if(KtBlue>1.0){KtBlue=1.0;}
CLHEP::Hep3Vector G4ThreeVector
G4DLLIMPORT std::ostream G4cerr
Hep3Vector & rotateZ(double)
Hep3Vector & rotateUz(const Hep3Vector &)
G4double GetAlpha() const
G4double GetGreen() const
G4UserTrackingAction * GetUserTrackingAction()
void SetUserAction(G4UserEventAction *userAction)
G4UserSteppingAction * GetUserSteppingAction()
G4UserStackingAction * GetUserStackingAction()
G4UserEventAction * GetUserEventAction()
static G4EventManager * GetEventManager()
void ProcessOneEvent(G4Event *anEvent)
G4TrajectoryContainer * GetTrajectoryContainer() const
static G4Geantino * GeantinoDefinition()
G4bool CloseGeometry(G4bool pOptimise=true, G4bool verbose=false, G4VPhysicalVolume *vol=0)
void OpenGeometry(G4VPhysicalVolume *vol=0)
static G4GeometryManager * GetInstance()
G4VSolid * GetSolid() const
virtual G4VPhysicalVolume * LocateGlobalPointAndSetup(const G4ThreeVector &point, const G4ThreeVector *direction=0, const G4bool pRelativeSearch=true, const G4bool ignoreDirection=true)
G4ProcessManager * GetProcessManager() const
G4ProcessVector * GetProcessList() const
void UpdateCoupleTable(G4VPhysicalVolume *currentWorld)
static G4ProductionCutsTable * GetProductionCutsTable()
static G4RTMessenger * GetInstance(G4TheRayTracer *p1, G4RTSteppingAction *p2)
void Shoot(G4Event *evt, G4ThreeVector vtx, G4ThreeVector direc)
G4ThreeVector GetSurfaceNormal() const
const G4VisAttributes * GetPostStepAtt() const
G4double GetStepLength() const
const G4VisAttributes * GetPreStepAtt() const
virtual int GetPointEntries() const
G4RayTrajectoryPoint * GetPointC(G4int i) const
static G4RegionStore * GetInstance()
void UpdateMaterialList(G4VPhysicalVolume *currentWorld=0)
void Activate(G4String dName, G4bool activeFlag)
static G4SDManager * GetSDMpointerIfExist()
G4ApplicationState GetCurrentState() const
static G4StateManager * GetStateManager()
G4bool SetNewState(G4ApplicationState requestedState)
G4ThreeVector eyeDirection
G4RTTrackingAction * theRayTracerTrackingAction
G4UserTrackingAction * theUserTrackingAction
G4bool GenerateColour(G4Event *anEvent)
G4RTSteppingAction * theRayTracerSteppingAction
G4ThreeVector lightDirection
G4EventManager * theEventManager
G4UserStackingAction * theRayTracerStackingAction
G4UserEventAction * theUserEventAction
G4UserSteppingAction * theUserSteppingAction
G4Colour backgroundColour
G4double attenuationLength
G4Colour GetSurfaceColour(G4RayTrajectoryPoint *point)
G4ThreeVector targetPosition
G4UserEventAction * theRayTracerEventAction
G4VFigureFileMaker * theFigMaker
G4VRTScanner * theScanner
void CreateFigureFile(G4String fileName)
G4UserStackingAction * theUserStackingAction
G4ThreeVector eyePosition
G4Colour Attenuate(G4RayTrajectoryPoint *point, G4Colour sourceCol)
void RestoreUserActions()
G4TheRayTracer(G4VFigureFileMaker *figMaker=0, G4VRTScanner *scanner=0)
G4Colour GetMixedColour(G4Colour surfCol, G4Colour transCol, G4double weight=0.5)
void Trace(G4String fileName)
G4RTMessenger * theMessenger
G4RayShooter * theRayShooter
G4bool ValidColour(const G4VisAttributes *visAtt)
static G4TransportationManager * GetTransportationManager()
G4Navigator * GetNavigatorForTracking() const
G4int ApplyCommand(const char *aCommand)
G4int GetCurrentIntValue(const char *aCommand, G4int parameterNumber=1, G4bool reGet=true)
static G4UImanager * GetUIpointer()
G4LogicalVolume * GetLogicalVolume() const
virtual void Initialize(G4int nRow, G4int nColumn)=0
virtual void Draw(unsigned char red, unsigned char green, unsigned char blue)
virtual G4bool Coords(G4int &iRow, G4int &iColumn)=0
virtual EInside Inside(const G4ThreeVector &p) const =0
const G4Colour & GetColour() const
ForcedDrawingStyle GetForcedDrawingStyle() const
G4bool IsForceDrawingStyle() const