59 theDefaultTracer = p1;
66 fileCmd->
SetGuidance(
"Define the name of output JPEG file.");
72 columnCmd->
SetGuidance(
"Define the number of horizontal pixels.");
77 rowCmd->
SetGuidance(
"Define the number of virtical pixels.");
82 targetCmd->
SetGuidance(
"Define the center position of the target.");
89 eyePosCmd->
SetGuidance(
"Eye direction is calsurated from (target - eyePosition).");
95 lightCmd->
SetGuidance(
"Define the direction of illumination light.");
96 lightCmd->
SetGuidance(
"The vector needs not to be a unit vector, but it must not be a zero vector.");
99 lightCmd->
SetRange(
"Px != 0 || Py != 0 || Pz != 0");
102 spanXCmd->
SetGuidance(
"Define the angle per 100 pixels.");
109 headCmd->
SetGuidance(
"Define the head direction.");
113 headCmd->
SetRange(
"headAngle>=0. && headAngle<360.");
116 attCmd->
SetGuidance(
"Define the attenuation length for transparent material.");
117 attCmd->
SetGuidance(
"Note that this value is independent to the attenuation length for the optical photon processes.");
124 distCmd->
SetGuidance(
"Distortion effect of the fish eye lens.");
129 transCmd->
SetGuidance(
"Ignore transparency even if the alpha of G4Colour < 1.");
134 bkgColCmd->
SetGuidance(
"Command has been deprecated. Use /vis/viewer/set/background instead.");
159 if(command==columnCmd)
161 else if(command==rowCmd)
163 else if(command==targetCmd)
165 else if(command==eyePosCmd)
167 else if(command==lightCmd)
169 else if(command==spanXCmd)
171 else if(command==headCmd)
173 else if(command==attCmd)
175 else if(command==distCmd)
177 else if(command==transCmd)
179 else if(command==bkgColCmd)
186 G4VisManager* pVisManager = G4VisManager::GetInstance();
188 theTracer = theDefaultTracer;
197 "G4RTMessenger::SetNewValue: Current viewer is not of type RayTracer."
198 "\n Use \"/vis/viewer/select\" or \"/vis/open\"."
203 if (theTracer == theDefaultTracer) {
205 "G4RTMessenger::SetNewValue: No valid current viewer. Using default RayTracer."
209 if(command==columnCmd)
211 else if(command==rowCmd)
213 else if(command==targetCmd)
215 else if(command==eyePosCmd)
217 else if(command==lightCmd)
219 else if(command==spanXCmd)
221 else if(command==headCmd)
223 else if(command==attCmd)
225 else if(command==distCmd)
227 else if(command==bkgColCmd)
229 G4cout <<
"WARNING: /vis/rayTracer/backgroundColour has been deprecated."
230 "\n Use \"/vis/viewer/set/background\" instead."
233 else if(command==transCmd)
235 else if(command==fileCmd)
236 { theTracer->
Trace(newValue); }
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
void SetLightDirection(const G4ThreeVector &val)
void SetHeadAngle(G4double val)
static G4bool GetIgnoreTransparency()
void SetDefaultValue(G4double defVal)
G4ThreeVector GetLightDirection() const
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
CLHEP::Hep3Vector G4ThreeVector
static G4int GetNewIntValue(const char *paramString)
void SetDefaultUnit(const char *defUnit)
void SetParameterName(const char *theNameX, const char *theNameY, const char *theNameZ, G4bool omittable, G4bool currentAsDefault=false)
static G4ThreeVector GetNew3VectorValue(const char *paramString)
G4TheRayTracer * GetTracer()
static G4RTMessenger * GetInstance(G4TheRayTracer *p1)
static G4String ConvertToString(G4bool boolVal)
void SetNColumn(G4int val)
static G4double GetNewDoubleValue(const char *paramString)
void SetParameterName(const char *theNameX, const char *theNameY, const char *theNameZ, G4bool omittable, G4bool currentAsDefault=false)
G4ThreeVector GetTargetPosition() const
static G4bool GetNewBoolValue(const char *paramString)
void SetDefaultValue(G4bool defVal)
virtual void SetNewValue(G4UIcommand *command, G4String newValue)
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
virtual void Trace(const G4String &fileName)
virtual G4String GetCurrentValue(G4UIcommand *command)
G4GLOB_DLL std::ostream G4cout
static G4ThreeVector GetNew3VectorValue(const char *paramString)
void SetRange(const char *rs)
void SetGuidance(const char *aGuidance)
void SetViewSpan(G4double val)
void AvailableForStates(G4ApplicationState s1)
G4double GetAttenuationLength() const
void SetDefaultValue(G4ThreeVector defVal)
G4Colour GetBackgroundColour() const
G4ThreeVector GetEyePosition() const
void SetDefaultValue(const char *defVal)
static void SetIgnoreTransparency(G4bool val)
void SetDefaultUnit(const char *defUnit)
G4VViewer * GetCurrentViewer() const
G4double GetHeadAngle() const
void SetDistortion(G4bool val)
void SetDefaultValue(G4ThreeVector defVal)
void SetEyePosition(const G4ThreeVector &val)
G4double GetViewSpan() const
G4bool GetDistortion() const
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
void SetAttenuationLength(G4double val)
void SetTargetPosition(const G4ThreeVector &val)