Geant4
9.6.p02
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
geant4_9_6_p02
examples
extended
medical
DICOM
include
DicomNestedPhantomParameterisation.hh
Go to the documentation of this file.
1
//
2
// ********************************************************************
3
// * License and Disclaimer *
4
// * *
5
// * The Geant4 software is copyright of the Copyright Holders of *
6
// * the Geant4 Collaboration. It is provided under the terms and *
7
// * conditions of the Geant4 Software License, included in the file *
8
// * LICENSE and available at http://cern.ch/geant4/license . These *
9
// * include a list of copyright holders. *
10
// * *
11
// * Neither the authors of this software system, nor their employing *
12
// * institutes,nor the agencies providing financial support for this *
13
// * work make any representation or warranty, express or implied, *
14
// * regarding this software system or assume any liability for its *
15
// * use. Please see the license in the file LICENSE and URL above *
16
// * for the full disclaimer and the limitation of liability. *
17
// * *
18
// * This code implementation is the result of the scientific and *
19
// * technical work of the GEANT4 collaboration. *
20
// * By using, copying, modifying or distributing the software (or *
21
// * any work based on the software) you agree to acknowledge its *
22
// * use in resulting scientific publications, and indicate your *
23
// * acceptance of all terms of the Geant4 Software license. *
24
// ********************************************************************
25
//
28
//
29
// $Id$
30
//
31
32
#ifndef DICOMNESTEDPARAMETERISATION_HH
33
#define DICOMNESTEDPARAMETERISATION_HH
34
35
#include <vector>
36
37
#include "
G4Types.hh
"
38
#include "
G4ThreeVector.hh
"
39
#include "
G4VNestedParameterisation.hh
"
40
41
class
G4VPhysicalVolume
;
42
class
G4VTouchable
;
43
class
G4VSolid
;
44
class
G4Material
;
45
46
// CSG Entities which may be parameterised/replicated
47
//
48
class
G4Box
;
49
class
G4Tubs
;
50
class
G4Trd
;
51
class
G4Trap
;
52
class
G4Cons
;
53
class
G4Sphere
;
54
class
G4Orb
;
55
class
G4Torus
;
56
class
G4Para
;
57
class
G4Polycone
;
58
class
G4Polyhedra
;
59
class
G4Hype
;
60
62
63
class
DicomNestedPhantomParameterisation
:
public
G4VNestedParameterisation
64
{
65
public
:
66
67
DicomNestedPhantomParameterisation
(
const
G4ThreeVector
& voxelSize,
68
std::vector<G4Material*>&
mat
);
69
virtual
~DicomNestedPhantomParameterisation
();
70
71
G4Material
*
ComputeMaterial
(
G4VPhysicalVolume
*currentVol,
72
const
G4int
repNo,
73
const
G4VTouchable
*parentTouch );
74
// Must cope with parentTouch for navigator's SetupHierarchy
75
76
G4int
GetNumberOfMaterials
()
const
;
77
G4Material
*
GetMaterial
(
G4int
idx)
const
;
78
// Needed to define materials for instances of Nested Parameterisation
79
// Current convention: each call should return the materials
80
// of all instances with the same mother/ancestor volume
81
82
unsigned
int
GetMaterialIndex
(
unsigned
int
nx,
unsigned
int
ny,
unsigned
int
nz)
const
;
83
unsigned
int
GetMaterialIndex
(
unsigned
int
copyNo)
const
;
84
//void SetMaterialIndices( unsigned int* matInd ) { fMaterialIndices = matInd; }
85
void
SetMaterialIndices
(
size_t
* matInd ) { fMaterialIndices = matInd; }
86
void
SetNoVoxel
(
unsigned
int
nx,
unsigned
int
ny,
unsigned
int
nz );
87
88
void
ComputeTransformation
(
const
G4int
no
,
89
G4VPhysicalVolume
*currentPV)
const
;
90
91
// Additional standard Parameterisation methods,
92
// which can be optionally defined, in case solid is used.
93
94
void
ComputeDimensions
(
G4Box
&,
const
G4int
,
95
const
G4VPhysicalVolume
*)
const
;
96
97
using
G4VNestedParameterisation::ComputeMaterial
;
98
99
private
:
// Dummy declarations to get rid of warnings ...
100
101
void
ComputeDimensions
(
G4Trd
&,
const
G4int
,
102
const
G4VPhysicalVolume
*)
const
{}
103
void
ComputeDimensions
(
G4Trap
&,
const
G4int
,
104
const
G4VPhysicalVolume
*)
const
{}
105
void
ComputeDimensions
(
G4Cons
&,
const
G4int
,
106
const
G4VPhysicalVolume
*)
const
{}
107
void
ComputeDimensions
(
G4Sphere
&,
const
G4int
,
108
const
G4VPhysicalVolume
*)
const
{}
109
void
ComputeDimensions
(
G4Orb
&,
const
G4int
,
110
const
G4VPhysicalVolume
*)
const
{}
111
void
ComputeDimensions
(
G4Torus
&,
const
G4int
,
112
const
G4VPhysicalVolume
*)
const
{}
113
void
ComputeDimensions
(
G4Para
&,
const
G4int
,
114
const
G4VPhysicalVolume
*)
const
{}
115
void
ComputeDimensions
(
G4Hype
&,
const
G4int
,
116
const
G4VPhysicalVolume
*)
const
{}
117
void
ComputeDimensions
(
G4Tubs
&,
const
G4int
,
118
const
G4VPhysicalVolume
*)
const
{}
119
void
ComputeDimensions
(
G4Polycone
&,
const
G4int
,
120
const
G4VPhysicalVolume
*)
const
{}
121
void
ComputeDimensions
(
G4Polyhedra
&,
const
G4int
,
122
const
G4VPhysicalVolume
*)
const
{}
123
124
private
:
125
126
G4double
fdX,fdY,fdZ;
127
G4int
fnX,fnY,fnZ;
128
std::vector<G4Material*> fMaterials;
129
size_t
* fMaterialIndices;
// Index in materials corresponding to each voxel
130
// unsigned int* fMaterialIndices; // Index in materials corresponding to each voxel
131
};
132
#endif
Generated on Sat May 25 2013 14:32:57 for Geant4 by
1.8.4