Geant4 11.2.2
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4VisAttributes.cc File Reference
#include "G4VisAttributes.hh"
#include "G4AttValue.hh"
#include "G4AttDef.hh"

Go to the source code of this file.

Functions

std::ostream & operator<< (std::ostream &os, const G4VisAttributes &a)
 

Function Documentation

◆ operator<<()

std::ostream & operator<< ( std::ostream & os,
const G4VisAttributes & a )

Definition at line 212 of file G4VisAttributes.cc.

213{
214 os << std::defaultfloat;
215 os << "G4VisAttributes: ";
216 if (!a.fVisible) os << "in";
217 os << "visible, daughters ";
218 if (a.fDaughtersInvisible) os << "in";
219 os << "visible, colour: " << a.fColour;
220 os << "\n linestyle: ";
221 switch (a.fLineStyle) {
223 os << "solid"; break;
225 os << "dashed"; break;
226 case G4VisAttributes::dotted: os << "dotted"; break;
227 default: os << "unrecognised"; break;
228 }
229 os << ", line width: " << a.fLineWidth;
230 os << ", min line segments per circle: " << a.GetMinLineSegmentsPerCircle();
231 os << "\n drawing style: ";
232 if (a.fForceDrawingStyle) {
233 os << "forced to ";
234 switch (a.fForcedStyle) {
236 os << "wireframe"; break;
238 os << "solid"; break;
239 default: os << "unrecognised"; break;
240 }
241 }
242 else {
243 os << "not forced";
244 }
245 os << ", auxiliary edge visibility: ";
246 if (a.fForceAuxEdgeVisible) {
247 os << "forced to ";
248 if (!a.fForcedAuxEdgeVisible) {
249 os << "not ";
250 }
251 os << "visible";
252 } else {
253 os << "not forced";
254 }
255 os << "\n line segments per circle: ";
256 if (a.fForcedLineSegmentsPerCircle > 0) {
257 os << "forced to " << a.fForcedLineSegmentsPerCircle;
258 } else {
259 os << "not forced.";
260 }
261 os << "\n time range: (" << a.fStartTime << ',' << a.fEndTime << ')';
262 os << "\n G4AttValue pointer is ";
263 if (a.fAttValues != nullptr) {
264 os << "non-";
265 }
266 os << "zero";
267 os << ", G4AttDef pointer is ";
268 if (a.fAttDefs != nullptr) {
269 os << "non-";
270 }
271 os << "zero";
272 return os;
273}
static G4int GetMinLineSegmentsPerCircle()