BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
|
Factory for GMAD geometry description. More...
#include <BDSGeometryFactoryGMAD.hh>
Public Member Functions | |
virtual BDSGeometryExternal * | Build (G4String componentName, G4String fileName, std::map< G4String, G4Colour *> *colourMapping=nullptr, G4double suggestedLength=0, G4double suggestedOuterDiameter=0) |
![]() | |
virtual std::vector< G4VisAttributes * > | ApplyColourMapping (std::vector< G4LogicalVolume *> &lvs, std::map< G4String, G4Colour *> *mapping) |
virtual void | ApplyUserLimits (const std::vector< G4LogicalVolume *> &lvsIn, G4UserLimits *userLimits) |
Attach a set of user limits to every logical volume supplied. | |
Static Public Member Functions | |
static BDSGeometryFactoryGMAD * | Instance () |
Singleton accessor. | |
Private Member Functions | |
BDSGeometryFactoryGMAD () | |
Private default constructor as singleton. | |
void | Error () |
Simple there was an error print out. | |
G4String | GetWord (std::ifstream &infputf) const |
Read a single word from the ifstream. | |
void | GetParameter (std::ifstream &inputf, G4double &x, G4String name, G4String lastToken) const |
Get a numerical parameter from the ifstream. | |
void | GetParameter (std::ifstream &inputf, G4String &lval, G4String name, G4String lastToken) const |
Get a string parameter from the ifstream. | |
void | Finish (G4String name, G4VSolid *solid, G4String materialName, G4LogicalVolume *mother, G4double phi=0, G4double theta=0, G4double psi=0, G4double x0=0, G4double y0=0, G4double z0=0) |
Construct logical volume, rotation and placement. | |
Static Private Attributes | |
static BDSGeometryFactoryGMAD * | instance = nullptr |
Singleton instance. | |
Additional Inherited Members | |
![]() | |
virtual void | CleanUp () |
void | ExpandExtent (const BDSExtent &extent) |
Expand the acuumulated extents using a (possibly asymmetric) extent instance. | |
void | ExpandExtent (G4double xO, G4double rx, G4double y0, G4double ry, G4double z0, G4double rz) |
void | ExpandExtent (G4double x0, G4double xLow, G4double xHigh, G4double y0, G4double yLow, G4double yHigh, G4double z0, G4double zLow, G4double zHigh) |
Expand the extent but asymmetrically. | |
BDSExtent | Extent () const |
![]() | |
const G4bool | checkOverlaps |
Cache of whether to check overlaps or not. | |
G4double | xmin |
Extent in one dimension. | |
G4double | xmax |
Extent in one dimension. | |
G4double | ymin |
Extent in one dimension. | |
G4double | ymax |
Extent in one dimension. | |
G4double | zmin |
Extent in one dimension. | |
G4double | zmax |
Extent in one dimension. | |
std::vector< G4RotationMatrix * > | rotations |
Transient vector for construction. | |
std::vector< G4VPhysicalVolume * > | pvs |
Transient vector for construction. | |
std::vector< G4LogicalVolume * > | lvs |
Transient vector for construction. | |
std::vector< G4VSolid * > | solids |
Transient vector for construction. | |
std::vector< G4VisAttributes * > | vises |
Transient vector for construction. | |
Factory for GMAD geometry description.
Originally part of BDSIM. Adapated for recent refactoring.
Definition at line 41 of file BDSGeometryFactoryGMAD.hh.
|
virtual |
Main interface overrides base class method to construct a file with optional colour mapping.
Implements BDSGeometryFactoryBase.
Definition at line 60 of file BDSGeometryFactoryGMAD.cc.
References BDSGeometryFactoryBase::ApplyColourMapping(), BDSGeometryFactoryBase::ApplyUserLimits(), BDSGeometryFactoryBase::CleanUp(), Error(), BDSGeometryFactoryBase::ExpandExtent(), Finish(), BDSMaterials::GetMaterial(), GetParameter(), GetWord(), BDSMaterials::Instance(), BDSGlobalConstants::Instance(), BDSGeometryFactoryBase::lvs, BDSGeometryFactoryBase::pvs, BDSGeometryComponent::RegisterLogicalVolume(), BDSGeometryComponent::RegisterPhysicalVolume(), BDSGeometryComponent::RegisterRotationMatrix(), BDSGeometryComponent::RegisterSolid(), BDSGeometryComponent::RegisterVisAttributes(), BDSGeometryFactoryBase::rotations, BDSGeometryFactoryBase::solids, BDSGeometryFactoryBase::vises, BDSGeometryFactoryBase::xmax, and BDSGeometryFactoryBase::xmin.