Geant4 9.6.0
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 170 of file G4VisAttributes.cc.

170 {
171
172 os << "G4VisAttributes: ";
173 if (&a){
174 if (!a.fVisible) os << "in";
175 os << "visible, daughters ";
176 if (a.fDaughtersInvisible) os << "in";
177 os << "visible, colour: " << a.fColour;
178 os << "\n linestyle: ";
179 switch (a.fLineStyle) {
181 os << "solid"; break;
183 os << "dashed"; break;
184 case G4VisAttributes::dotted: os << "dotted"; break;
185 default: os << "unrecognised"; break;
186 }
187 os << ", line width: " << a.fLineWidth;
188 os << "\n drawing style: ";
189 if (a.fForceDrawingStyle) {
190 os << "forced to: ";
191 switch (a.fForcedStyle) {
193 os << "wireframe"; break;
195 os << "solid"; break;
196 default: os << "unrecognised"; break;
197 }
198 }
199 else {
200 os << "not forced";
201 }
202 os << ", auxiliary edge visibility: ";
203 if (!a.fForceAuxEdgeVisible) {
204 os << "not ";
205 }
206 os << "forced";
207 os << "\n line segments per circle: ";
208 if (a.fForcedLineSegmentsPerCircle > 0) {
209 os << "forced to " << a.fForcedLineSegmentsPerCircle;
210 } else {
211 os << "not forced.";
212 }
213 os << "\n time range: (" << a.fStartTime << ',' << a.fEndTime << ')';
214 os << "\n G4AttValue pointer is ";
215 if (a.fAttValues) {
216 os << "non-";
217 }
218 os << "zero";
219 os << ", G4AttDef pointer is ";
220 if (a.fAttDefs) {
221 os << "non-";
222 }
223 os << "zero";
224 }
225 else os << " zero G4VisAttributes pointer";
226 return os;
227}