30 #include "DetectorConstruction.hh"
48 fBoxMaterialName(boxMaterialName),
49 fWorldMaterialName(worldMaterialName),
50 fBoxDimensions(boxHx*2, boxHy*2, boxHz*2),
51 fWorldSizeFactor(worldSizeFactor),
134 auto newMaterial = nistManager->FindOrBuildMaterial(materialName);
135 if ( ! newMaterial ) {
136 G4cerr <<
"Material " << materialName <<
" not found." <<
G4endl;
137 G4cerr <<
"The box material was not changed." <<
G4endl;
141 if ( fBoxVolume ) fBoxVolume->SetMaterial(newMaterial);
142 G4cout <<
"Material of box changed to " << materialName <<
G4endl;
151 auto newMaterial = nistManager->FindOrBuildMaterial(materialName);
152 if ( ! newMaterial ) {
153 G4cerr <<
"Material " << materialName <<
" not found." <<
G4endl;
154 G4cerr <<
"The box material was not changed." <<
G4endl;
158 if ( fWorldVolume ) fWorldVolume->SetMaterial(newMaterial);
159 G4cout <<
"Material of box changed to " << materialName <<
G4endl;
179 fWorldSizeFactor = factor;
192 auto& setBoxMaterialCmd
195 "Set box material name.");
200 auto& setWorldMaterialCmd
203 "Set world material name.");
208 auto& setBoxDimensionsCmd
211 "Set box dimensions (in half lentgh).");
216 auto& setWorldSizeFactorCmd
219 "Set the multiplication factor from box dimensions to world dimensions.");
221 setWorldSizeFactorCmd.
SetRange(
"WorldSizeFactor >= 1");