5 #include <Geant4/G4Colour.hh>
6 #include <Geant4/G4LogicalVolume.hh>
7 #include <Geant4/G4VisAttributes.hh>
35 G4LogicalVolume *logvol =
it.first;
36 if (logvol->GetVisAttributes())
40 G4VisAttributes *visatt =
new G4VisAttributes();
41 visatt->SetVisibility(
true);
42 visatt->SetForceSolid(
true);
44 if (
it.second ==
"Absorber")
46 visatt->SetColour(G4Colour::Gray());
48 else if (
it.second ==
"FdrcaloEnvelope")
50 visatt->SetVisibility(
false);
52 else if (
it.second ==
"TestScint")
54 visatt->SetColour(G4Colour::White());
56 else if (
it.second ==
"TestAbsorb")
58 visatt->SetColour(G4Colour::Gray());
60 else if (
it.second ==
"Scintillator")
62 visatt->SetColour(G4Colour::White());
63 visatt->SetVisibility(
false);
65 else if (
it.second ==
"Cherenkov")
67 visatt->SetColour(G4Colour::Yellow());
68 visatt->SetVisibility(
false);
70 else if (
it.second ==
"SingleTowerAbsorber")
72 visatt->SetColour(G4Colour::Gray());
74 else if (
it.second ==
"SingleTowerScintillator")
76 visatt->SetColour(G4Colour::Cyan());
77 visatt->SetVisibility(
false);
79 else if (
it.second ==
"SingleTowerCherenkovAbsorber")
81 visatt->SetColour(G4Colour::Gray());
83 else if (
it.second ==
"SingleTowerCherenkov")
85 visatt->SetColour(G4Colour::Cyan());
86 visatt->SetVisibility(
false);
90 cout <<
"unknown logical volume " <<
it.second << endl;
93 logvol->SetVisAttributes(visatt);