47 std::vector<G4Material*>&
mat,
51 fdX(voxelSize.
x()), fdY(voxelSize.
y()), fdZ(voxelSize.
z()),
52 fnX(fnX_), fnY(fnY_), fnZ(fnZ_),
97 G4String colourFile =
"DICOM_HEAD/ColourMap.dat";
99 G4String colourFile =
"ColourMap.dat";
102 std::ifstream
fin(colourFile.c_str());
105 G4double cred, cgreen, cblue, copacity;
107 for(
G4int ii = 0; ii < nMate; ii++ ){
108 fin >> mateName >> cred >> cgreen >> cblue >> copacity;
109 G4Colour colour( cred, cgreen, cblue, copacity );
118 SetNoVoxel(
unsigned int nx,
unsigned int ny,
unsigned int nz )
149 std::string::size_type iuu = mateName.find(
"__");
150 if( iuu != std::string::npos ) {
151 mateName = mateName.substr( 0, iuu );
156 SetVisAttributes(
fColours.find(mateName)->second);
159 SetVisAttributes(
fColours.begin()->second);
void SetXHalfLength(G4double dx)
CLHEP::Hep3Vector G4ThreeVector
G4LogicalVolume * GetLogicalVolume() const
std::map< G4String, G4VisAttributes * > fColours
Definition of the DicomNestedPhantomParameterisation class.
std::vector< G4Material * > fMaterials
void SetZHalfLength(G4double dz)
void SetTranslation(const G4ThreeVector &v)
static G4VVisManager * GetConcreteInstance()
G4int GetNumberOfMaterials() const
G4Material * GetMaterial(G4int idx) const
size_t * fMaterialIndices
void ComputeTransformation(const G4int no, G4VPhysicalVolume *currentPV) const
void SetYHalfLength(G4double dy)
void SetVisibility(G4bool=true)
DicomNestedPhantomParameterisation(const G4ThreeVector &voxelSize, std::vector< G4Material * > &mat, G4int fnZ_=0, G4int fnY_=0, G4int fnX_=0)
virtual G4int GetReplicaNumber(G4int depth=0) const
void ComputeDimensions(G4Box &, const G4int, const G4VPhysicalVolume *) const
G4Material * ComputeMaterial(G4VPhysicalVolume *currentVol, const G4int repNo, const G4VTouchable *parentTouch)
~DicomNestedPhantomParameterisation()
unsigned int GetMaterialIndex(unsigned int nx, unsigned int ny, unsigned int nz) const
void SetNoVoxel(unsigned int nx, unsigned int ny, unsigned int nz)