46 (
"Produces a representation of the geometry hierarchy. Further"
47 "\nguidance is given on running the command. Or look at the guidance"
48 "\nfor \"/vis/ASCIITree/verbose\".");
51 parameter =
new G4UIparameter(
"physical-volume-name",
's', omitable =
true);
52 parameter -> SetDefaultValue(
"world");
54 parameter =
new G4UIparameter(
"system",
's', omitable =
true);
55 parameter -> SetDefaultValue(
"ATree");
66 std::istringstream is(newValue);
79 if (!system.contains(
"Tree")) {
91 if (keepVerbose >= 2 ||
118 (
"Draw view from this angle, etc.");
120 parameter =
new G4UIparameter(
"theta-degrees",
'd', omitable =
true);
121 parameter -> SetDefaultValue(0.);
123 parameter =
new G4UIparameter(
"phi-degrees",
'd', omitable =
true);
124 parameter -> SetDefaultValue(0.);
126 parameter =
new G4UIparameter(
"pan-right",
'd', omitable =
true);
127 parameter -> SetDefaultValue(0.);
129 parameter =
new G4UIparameter(
"pan-up",
'd', omitable =
true);
130 parameter -> SetDefaultValue(0.);
132 parameter =
new G4UIparameter(
"pan-unit",
's', omitable =
true);
133 parameter -> SetDefaultValue(
"cm");
135 parameter =
new G4UIparameter(
"zoom-factor",
'd', omitable =
true);
136 parameter -> SetDefaultValue(1.);
138 parameter =
new G4UIparameter(
"dolly",
'd', omitable =
true);
139 parameter -> SetDefaultValue(0.);
141 parameter =
new G4UIparameter(
"dolly-unit",
's', omitable =
true);
142 parameter -> SetDefaultValue(
"cm");
155 if (!currentViewer) {
158 "WARNING: G4VisCommandsDrawView::SetNewValue: no current viewer."
172 std::istringstream is(newValue);
173 is >> thetaDeg >> phiDeg >> panRight >> panUp >> panUnit
174 >> zoomFactor >> dolly >> dollyUnit;
179 if (keepVerbose >= 2 ||
188 G4String(
"/vis/viewer/set/viewpointThetaPhi " + thetaDeg +
" " + phiDeg +
" deg"));
190 G4String(
"/vis/viewer/panTo " + panRight +
" " + panUp +
" " + panUnit));
192 G4String(
"/vis/viewer/zoomTo " + zoomFactor));
197 G4String(
"/vis/viewer/dollyTo " + dolly +
" " + dollyUnit));
207 (
"Draws logical volume with Boolean components, voxels and readout geometry.");
209 (
"Synonymous with \"/vis/specify\".");
211 (
"Creates a scene consisting of this logical volume and asks the"
212 "\n current viewer to draw it to the specified depth of descent"
213 "\n showing boolean components (if any), voxels (if any),"
214 "\n readout geometry (if any), local axes and overlaps (if any),"
215 "\n under control of the appropriate flag.");
217 (
"Note: voxels are not constructed until start of run - /run/beamOn."
218 "\n (For voxels without a run, \"/run/beamOn 0\".)");
221 parameter =
new G4UIparameter(
"logical-volume-name",
's', omitable =
false);
223 parameter =
new G4UIparameter(
"depth-of-descent",
'i', omitable =
true);
226 parameter =
new G4UIparameter(
"booleans-flag",
'b', omitable =
true);
229 parameter =
new G4UIparameter(
"voxels-flag",
'b', omitable =
true);
232 parameter =
new G4UIparameter(
"readout-flag",
'b', omitable =
true);
235 parameter =
new G4UIparameter(
"axes-flag",
'b', omitable =
true);
237 parameter -> SetGuidance (
"Set \"false\" to suppress axes.");
239 parameter =
new G4UIparameter(
"check-overlap-flag",
'b', omitable =
true);
241 parameter -> SetGuidance (
"Set \"false\" to suppress overlap check.");
262 static G4bool warned =
false;
265 "NOTE: For systems which are not \"auto-refresh\" you will need to"
266 "\n issue \"/vis/viewer/refresh\" or \"/vis/viewer/flush\"."
278 (
"Creates a scene containing this physical volume and asks the"
279 "\ncurrent viewer to draw it. The scene becomes current.");
281 (
"If physical-volume-name is \"world\" (the default), the main geometry"
282 "\ntree (material world) is drawn. If \"worlds\", all worlds - material"
283 "\nworld and parallel worlds, if any - are drawn. Otherwise a search of"
284 "\nall worlds is made, taking the first matching occurence only. To see"
285 "\na representation of the geometry hierarchy of the worlds, try"
286 "\n\"/vis/drawTree worlds\" or one of the driver/browser combinations"
287 "\nthat have the required functionality, e.g., HepRepFile/HepRApp.");
308 static G4bool warned =
false;
311 "NOTE: For systems which are not \"auto-refresh\" you will need to"
312 "\n issue \"/vis/viewer/refresh\" or \"/vis/viewer/flush\"."
324 (
"Creates a scene handler ready for drawing.");
326 (
"The scene handler becomes current (the name is auto-generated).");
328 parameter =
new G4UIparameter(
"graphics-system-name",
's', omitable =
false);
330 parameter =
new G4UIparameter(
"window-size-hint",
's', omitable =
true);
332 (
"integer (pixels) for square window placed by window manager or"
333 " X-Windows-type geometry string, e.g. 600x600-100+100");
343 G4String systemName, windowSizeHint;
344 std::istringstream is(newValue);
345 is >> systemName >> windowSizeHint;
349 if (keepVerbose >= 2 ||
358 std::set<G4String> candidates;
359 for (
const auto gs:
fpVisManager -> GetAvailableGraphicsSystems()) {
361 for (
const auto& nickname: gs->GetNicknames()) {
362 if (!nickname.contains(
"FALLBACK")) {
363 candidates.insert(nickname);
367 G4cerr <<
"Candidates are:";
368 for (
const auto& candidate: candidates) {
369 G4cerr <<
' ' << candidate;
382 (
"Draws logical volume with Boolean components, voxels and readout geometry.");
384 (
"Synonymous with \"/vis/drawLogicalVolume\".");
386 (
"Creates a scene consisting of this logical volume and asks the"
387 "\n current viewer to draw it to the specified depth of descent"
388 "\n showing boolean components (if any), voxels (if any),"
389 "\n readout geometry (if any), local axes and overlaps (if any),"
390 "\n under control of the appropriate flag.");
392 (
"Note: voxels are not constructed until start of run - /run/beamOn."
393 "\n (For voxels without a run, \"/run/beamOn 0\".)");
396 parameter =
new G4UIparameter(
"logical-volume-name",
's', omitable =
false);
398 parameter =
new G4UIparameter(
"depth-of-descent",
'i', omitable =
true);
401 parameter =
new G4UIparameter(
"booleans-flag",
'b', omitable =
true);
404 parameter =
new G4UIparameter(
"voxels-flag",
'b', omitable =
true);
407 parameter =
new G4UIparameter(
"readout-flag",
'b', omitable =
true);
410 parameter =
new G4UIparameter(
"axes-flag",
'b', omitable =
true);
412 parameter -> SetGuidance (
"Set \"false\" to suppress axes.");
414 parameter =
new G4UIparameter(
"check-overlap-flag",
'b', omitable =
true);
416 parameter -> SetGuidance (
"Set \"false\" to suppress overlap check.");
437 static G4bool warned =
false;
440 "NOTE: For systems which are not \"auto-refresh\" you will need to"
441 "\n issue \"/vis/viewer/refresh\" or \"/vis/viewer/flush\"."
void SetNewValue(G4UIcommand *command, G4String newValue)
void SetGuidance(const char *aGuidance)
system("rm -rf microbeam.root")
G4int ApplyCommand(const char *aCommand)
void SetViewParameters(const G4ViewParameters &vp)
virtual ~G4VisCommandDrawLogicalVolume()
const G4ViewParameters & GetViewParameters() const
void SetDefaultValue(const char *defVal)
void SetNewValue(G4UIcommand *command, G4String newValue)
void SetGuidance(const char *theGuidance)
void SetVerboseLevel(G4int val)
G4Scene * GetCurrentScene() const
static G4UImanager * GetUIpointer()
void SetNewValue(G4UIcommand *command, G4String newValue)
void SetParameter(G4UIparameter *const newParameter)
void SetDefaultValue(const char *theDefaultValue)
virtual ~G4VisCommandSpecify()
void SetCurrentViewer(G4VViewer *)
G4VViewer * GetCurrentViewer() const
static Verbosity GetVerbosity()
G4UIcmdWithAString * fpCommand
const G4String & GetName() const
void SetNewValue(G4UIcommand *command, G4String newValue)
G4GLOB_DLL std::ostream G4cerr
G4bool IsAutoRefresh() const
void SetCurrentGraphicsSystem(G4VGraphicsSystem *)
virtual ~G4VisCommandOpen()
void SetCurrentSceneHandler(G4VSceneHandler *)
virtual ~G4VisCommandDrawTree()
void SetNewValue(G4UIcommand *command, G4String newValue)
void SetCurrentScene(G4Scene *)
virtual ~G4VisCommandDrawView()
G4int GetVerboseLevel() const
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
void SetNewValue(G4UIcommand *command, G4String newValue)
G4GLOB_DLL std::ostream G4cout
virtual ~G4VisCommandDrawVolume()
G4VisCommandDrawLogicalVolume()
G4VSceneHandler * GetCurrentSceneHandler() const
static G4VisManager * fpVisManager
void SetAutoRefresh(G4bool)
G4VGraphicsSystem * GetCurrentGraphicsSystem() const