48 for (
size_t iLV = 0; iLV < pLVStore->size(); iLV++ ) {
51 if (logVolName == requestedName) found =
true;
52 if (requestedName ==
"all" || logVolName == requestedName) {
53 SetLVVisAtts(pLV, setFunction, 0, requestedDepth);
56 if (requestedName !=
"all" && !found) {
58 G4cerr <<
"ERROR: Logical volume \"" << requestedName
59 <<
"\" not found in logical volume store." <<
G4endl;
63 if (fpVisManager->GetCurrentViewer()) {
75 fVisAttsMap.insert(std::make_pair(pLV,oldVisAtts));
78 *newVisAtts = *oldVisAtts;
80 setFunction(newVisAtts);
85 <<
"\": setting vis attributes:";
87 G4cout <<
"\nwas: " << *oldVisAtts;
89 G4cout <<
"\n(no old attributes)";
91 G4cout <<
"\nnow: " << *newVisAtts
94 if (requestedDepth < 0 || depth < requestedDepth) {
96 for (
G4int i = 0; i < nDaughters; ++i) {
98 setFunction, ++depth, requestedDepth);
112 (
"Optionally propagates down hierarchy to given depth.");
114 parameter =
new G4UIparameter (
"logical-volume-name",
's', omitable =
true);
117 parameter =
new G4UIparameter(
"depth",
'd', omitable =
true);
120 (
"Depth of propagation (-1 means unlimited depth).");
125 (
"Red component or a string, e.g., \"blue\", in which case succeeding colour components are ignored.");
127 parameter =
new G4UIparameter(
"green",
'd', omitable =
true);
133 parameter =
new G4UIparameter(
"opacity",
'd', omitable =
true);
152 G4int requestedDepth;
154 std::istringstream iss(newValue);
155 iss >> name >> requestedDepth >> redOrString >> green >> blue >> opacity;
157 ConvertToColour(colour, redOrString, green, blue, opacity);
159 Set(name, setColour, requestedDepth);
171 (
"Optionally propagates down hierarchy to given depth.");
173 parameter =
new G4UIparameter (
"logical-volume-name",
's', omitable =
true);
176 parameter =
new G4UIparameter(
"depth",
'd', omitable =
true);
179 (
"Depth of propagation (-1 means unlimited depth).");
181 parameter =
new G4UIparameter(
"daughtersInvisible",
'b', omitable =
true);
201 G4int requestedDepth;
203 std::istringstream iss(newValue);
204 iss >> name >> requestedDepth >> daughtersInvisibleString;
205 G4bool daughtersInvisible =
208 if (requestedDepth !=0) {
211 G4cout <<
"Recursive application suppressed for this attribute."
217 setDaughtersInvisible(daughtersInvisible);
218 Set(name, setDaughtersInvisible, requestedDepth);
220 G4VViewer* pViewer = fpVisManager->GetCurrentViewer();
226 "Culling must be on - \"/vis/viewer/set/culling global true\" - to see effect."
240 (
"Forces auxiliary (soft) edges of logical volume(s) to be visible,"
241 "\nregardless of the view parameters.");
244 (
"Optionally propagates down hierarchy to given depth.");
246 parameter =
new G4UIparameter (
"logical-volume-name",
's', omitable =
true);
249 parameter =
new G4UIparameter(
"depth",
'd', omitable =
true);
252 (
"Depth of propagation (-1 means unlimited depth).");
254 parameter =
new G4UIparameter(
"forceAuxEdgeVisible",
'b', omitable =
true);
274 G4int requestedDepth;
276 std::istringstream iss(newValue);
277 iss >> name >> requestedDepth >> forceAuxEdgeVisibleString;
278 G4bool forceAuxEdgeVisible =
282 setForceAuxEdgeVisible(forceAuxEdgeVisible);
283 Set(name, setForceAuxEdgeVisible, requestedDepth);
293 (
"Forces number of line segments per circle, the precision with which a"
294 "\ncurved line or surface is represented by a polygon or polyhedron,"
295 "\nregardless of the view parameters.");
298 (
"Optionally propagates down hierarchy to given depth.");
300 parameter =
new G4UIparameter (
"logical-volume-name",
's', omitable =
true);
303 parameter =
new G4UIparameter(
"depth",
'd', omitable =
true);
306 (
"Depth of propagation (-1 means unlimited depth).");
308 parameter =
new G4UIparameter(
"lineSegmentsPerCircle",
'd', omitable =
true);
310 (
"<= 0 means not forced, i.e., under control of viewer.");
330 G4int requestedDepth;
331 G4int lineSegmentsPerCircle;
332 std::istringstream iss(newValue);
333 iss >> name >> requestedDepth >> lineSegmentsPerCircle;
336 Set(name, setForceLineSegmentsPerCircle, requestedDepth);
346 (
"Forces logical volume(s) always to be drawn solid (surface drawing),"
347 "\nregardless of the view parameters.");
350 (
"Optionally propagates down hierarchy to given depth.");
352 parameter =
new G4UIparameter (
"logical-volume-name",
's', omitable =
true);
355 parameter =
new G4UIparameter(
"depth",
'd', omitable =
true);
358 (
"Depth of propagation (-1 means unlimited depth).");
360 parameter =
new G4UIparameter(
"forceSolid",
'b', omitable =
true);
380 G4int requestedDepth;
382 std::istringstream iss(newValue);
383 iss >> name >> requestedDepth >> forceSolidString;
387 Set(name, setForceSolid, requestedDepth);
397 (
"Forces logical volume(s) always to be drawn as wireframe,"
398 "\nregardless of the view parameters.");
401 (
"Optionally propagates down hierarchy to given depth.");
403 parameter =
new G4UIparameter (
"logical-volume-name",
's', omitable =
true);
406 parameter =
new G4UIparameter(
"depth",
'd', omitable =
true);
409 (
"Depth of propagation (-1 means unlimited depth).");
411 parameter =
new G4UIparameter(
"forceWireframe",
'b', omitable =
true);
431 G4int requestedDepth;
433 std::istringstream iss(newValue);
434 iss >> name >> requestedDepth >> forceWireframeString;
438 setForceWireframe(forceWireframe);
439 Set(name, setForceWireframe, requestedDepth);
451 (
"Optionally propagates down hierarchy to given depth.");
453 parameter =
new G4UIparameter (
"logical-volume-name",
's', omitable =
true);
456 parameter =
new G4UIparameter(
"depth",
'd', omitable =
true);
459 (
"Depth of propagation (-1 means unlimited depth).");
461 parameter =
new G4UIparameter(
"lineStyle",
's', omitable =
true);
482 G4int requestedDepth;
483 std::istringstream iss(newValue);
484 iss >> name >> requestedDepth >> lineStyleString;
491 Set(name, setLineStyle, requestedDepth);
503 (
"Optionally propagates down hierarchy to given depth.");
505 parameter =
new G4UIparameter (
"logical-volume-name",
's', omitable =
true);
508 parameter =
new G4UIparameter(
"depth",
'd', omitable =
true);
511 (
"Depth of propagation (-1 means unlimited depth).");
513 parameter =
new G4UIparameter(
"lineWidth",
'd', omitable =
true);
533 G4int requestedDepth;
535 std::istringstream iss(newValue);
536 iss >> name >> requestedDepth >> lineWidth;
539 Set(name, setLineWidth, requestedDepth);
551 (
"Optionally propagates down hierarchy to given depth.");
553 parameter =
new G4UIparameter (
"logical-volume-name",
's', omitable =
true);
556 parameter =
new G4UIparameter(
"depth",
'd', omitable =
true);
559 (
"Depth of propagation (-1 means unlimited depth).");
561 parameter =
new G4UIparameter(
"visibility",
'b', omitable =
true);
580 G4int requestedDepth;
582 std::istringstream iss(newValue);
583 iss >> name >> requestedDepth >> visibilityString;
587 Set(name, setVisibility, requestedDepth);
589 G4VViewer* pViewer = fpVisManager->GetCurrentViewer();
596 "Culling must be on - \"/vis/viewer/set/culling global true\" and"
597 "\n \"/vis/viewer/set/culling invisible true\" - to see effect."
609 SetLVVisAtts(pLV, setVisibility, 0, requestedDepth);
611 G4VViewer* pViewer = fpVisManager->GetCurrentViewer();
619 "Culling must be on - \"/vis/viewer/set/culling global true\" and"
620 "\n \"/vis/viewer/set/culling invisible true\" - to see effect."
void SetGuidance(const char *aGuidance)
G4VisCommandGeometrySetColour()
virtual ~G4VisCommandGeometrySetColour()
G4LogicalVolume * GetLogicalVolume() const
G4String GetCurrentValue(G4UIcommand *command)
G4VisCommandGeometrySetForceLineSegmentsPerCircle()
void SetNewValue(G4UIcommand *command, G4String newValue)
G4int ApplyCommand(const char *aCommand)
G4String GetCurrentValue(G4UIcommand *command)
G4int GetNoDaughters() const
static G4bool ConvertToBool(const char *st)
virtual ~G4VisCommandGeometrySetForceAuxEdgeVisible()
const G4ViewParameters & GetViewParameters() const
void SetNewValueOnLV(G4LogicalVolume *pLV, G4int, G4bool)
void SetNewValue(G4UIcommand *command, G4String newValue)
void SetGuidance(const char *theGuidance)
void SetNewValue(G4UIcommand *command, G4String newValue)
static G4UImanager * GetUIpointer()
void SetNewValue(G4UIcommand *command, G4String newValue)
G4String GetCurrentValue(G4UIcommand *command)
G4VisCommandGeometrySetForceAuxEdgeVisible()
void SetParameter(G4UIparameter *const newParameter)
void SetDefaultValue(const char *theDefaultValue)
virtual ~G4VisCommandGeometrySetForceSolid()
virtual ~G4VisCommandGeometrySetDaughtersInvisible()
G4String GetCurrentValue(G4UIcommand *command)
G4VisCommandGeometrySetLineStyle()
void SetNewValue(G4UIcommand *command, G4String newValue)
virtual ~G4VisCommandGeometrySetLineStyle()
const G4VisAttributes * GetVisAttributes() const
G4bool IsCullingInvisible() const
G4VisCommandGeometrySetLineWidth()
void SetVisAttributes(const G4VisAttributes *pVA)
virtual ~G4VisCommandGeometrySetForceLineSegmentsPerCircle()
G4String GetCurrentValue(G4UIcommand *command)
G4GLOB_DLL std::ostream G4cerr
virtual ~G4VisCommandGeometrySetVisibility()
G4String GetCurrentValue(G4UIcommand *command)
void SetNewValue(G4UIcommand *command, G4String newValue)
virtual ~G4VisCommandGeometrySetForceWireframe()
G4VisCommandGeometrySetForceWireframe()
void Set(G4String logVolName, const G4VVisCommandGeometrySetFunction &, G4int requestedDepth)
G4String GetCurrentValue(G4UIcommand *command)
G4VisCommandGeometrySetVisibility()
void SetNewValue(G4UIcommand *command, G4String newValue)
void SetLVVisAtts(G4LogicalVolume *, const G4VVisCommandGeometrySetFunction &, G4int depth, G4int requestedDepth)
G4GLOB_DLL std::ostream G4cout
virtual ~G4VisCommandGeometrySetLineWidth()
G4String GetCurrentValue(G4UIcommand *command)
void SetNewValue(G4UIcommand *command, G4String newValue)
void Set(G4int Elements, T *To, T Value)
G4VisCommandGeometrySetForceSolid()
void SetParameterCandidates(const char *theString)
G4String GetCurrentValue(G4UIcommand *command)
static G4LogicalVolumeStore * GetInstance()
G4VisCommandGeometrySetDaughtersInvisible()
G4VPhysicalVolume * GetDaughter(const G4int i) const
const G4String & GetName() const
void SetNewValue(G4UIcommand *command, G4String newValue)