|
Geant4 11.4.0
Toolkit for the simulation of the passage of particles through matter
|
An instance of G4MultiUnion constitutes a grouping of several solids. The constituent solids are stored with their respective location in a node instance. An instance of G4MultiUnion is subsequently composed of one or several nodes. More...
#include <G4MultiUnion.hh>
Friends | |
| class | G4Voxelizer |
Additional Inherited Members | |
| Protected Member Functions inherited from G4VSolid | |
| void | CalculateClippedPolygonExtent (G4ThreeVectorList &pPolygon, const G4VoxelLimits &pVoxelLimit, const EAxis pAxis, G4double &pMin, G4double &pMax) const |
| void | ClipCrossSection (G4ThreeVectorList *pVertices, const G4int pSectionIndex, const G4VoxelLimits &pVoxelLimit, const EAxis pAxis, G4double &pMin, G4double &pMax) const |
| void | ClipBetweenSections (G4ThreeVectorList *pVertices, const G4int pSectionIndex, const G4VoxelLimits &pVoxelLimit, const EAxis pAxis, G4double &pMin, G4double &pMax) const |
| void | ClipPolygon (G4ThreeVectorList &pPolygon, const G4VoxelLimits &pVoxelLimit, const EAxis pAxis) const |
| Protected Attributes inherited from G4VSolid | |
| G4double | kCarTolerance |
An instance of G4MultiUnion constitutes a grouping of several solids. The constituent solids are stored with their respective location in a node instance. An instance of G4MultiUnion is subsequently composed of one or several nodes.
Definition at line 61 of file G4MultiUnion.hh.
| G4MultiUnion::G4MultiUnion | ( | ) |
Empty default constructor.
Definition at line 57 of file G4MultiUnion.cc.
Referenced by Clone(), G4MultiUnion(), operator=(), and ~G4MultiUnion().
| G4MultiUnion::G4MultiUnion | ( | const G4String & | name | ) |
Constructor assigning a name and initialising components.
Definition at line 63 of file G4MultiUnion.cc.
|
overridedefault |
Default destructor.
| G4MultiUnion::G4MultiUnion | ( | __void__ & | a | ) |
Fake default constructor for usage restricted to direct object persistency for clients requiring preallocation of memory for persistifiable objects.
Definition at line 103 of file G4MultiUnion.cc.
| G4MultiUnion::G4MultiUnion | ( | const G4MultiUnion & | rhs | ) |
Copy constructor and assignment operator.
Definition at line 94 of file G4MultiUnion.cc.
| void G4MultiUnion::AddNode | ( | G4VSolid & | solid, |
| const G4Transform3D & | trans ) |
Methods to build the multiple union by adding nodes (by pointer or ref).
| [in] | solid | The solid to be added to the structure. |
| [in] | trans | The 3D transformation relative to the structure. |
Definition at line 73 of file G4MultiUnion.cc.
Referenced by G4tgbVolume::FindOrConstructG4Solid(), and G4GDMLReadSolids::MultiUnionNodeRead().
| void G4MultiUnion::AddNode | ( | G4VSolid * | solid, |
| const G4Transform3D & | trans ) |
Definition at line 80 of file G4MultiUnion.cc.
|
overridevirtual |
Computes the bounding limits of the solid.
| [out] | aMin | The minimum bounding limit point. |
| [out] | aMax | The maximum bounding limit point. |
Reimplemented from G4VSolid.
Definition at line 583 of file G4MultiUnion.cc.
Referenced by CalculateExtent().
|
overridevirtual |
Calculates the minimum and maximum extent of a solid, when under the specified transform, and within the specified limits.
| [in] | pAxis | The axis along which compute the extent. |
| [in] | pVoxelLimit | The limiting space dictated by voxels. |
| [in] | pTransform | The internal transformation applied to the solid. |
| [out] | pMin | The minimum extent value. |
| [out] | pMax | The maximum extent value. |
Implements G4VSolid.
Definition at line 593 of file G4MultiUnion.cc.
|
overridevirtual |
Returns a new allocated clone of the multi-union structure.
Reimplemented from G4VSolid.
Definition at line 87 of file G4MultiUnion.cc.
|
overridevirtual |
Creates a Polyhedron used for Visualisation. It is the caller's responsibility to delete it. A null pointer means "not created".
Reimplemented from G4VSolid.
Definition at line 969 of file G4MultiUnion.cc.
Referenced by GetPolyhedron().
|
overridevirtual |
Methods for creating graphical representations (i.e. for visualisation).
Implements G4VSolid.
Definition at line 963 of file G4MultiUnion.cc.
|
overridevirtual |
Calculates the distance to the nearest surface of a shape from an outside point. The distance can be an underestimate.
| [in] | p | The point at offset p. |
Implements G4VSolid.
Definition at line 723 of file G4MultiUnion.cc.
|
overridevirtual |
Returns the distance along the normalised vector "aDirection" to the shape, from the point at offset "aPoint". If there is no intersection, return kInfinity. The first intersection resulting from leaving a surface/volume is discarded. Hence, it is tolerant of points on the surface of the shape.
Implements G4VSolid.
Definition at line 187 of file G4MultiUnion.cc.
| G4double G4MultiUnion::DistanceToInNoVoxels | ( | const G4ThreeVector & | aPoint, |
| const G4ThreeVector & | aDirection ) const |
Methods to compute the distance to enter/exit a volume, given point and direction, in presence of voxels-based optimisation structure or not.
Definition at line 128 of file G4MultiUnion.cc.
|
overridevirtual |
Calculates the distance to the nearest surface of a shape from an inside point 'p'. The distance can be an underestimate.
| [in] | p | The point at offset p. |
Implements G4VSolid.
Definition at line 686 of file G4MultiUnion.cc.
|
overridevirtual |
Computes distance from a point presumably inside the solid to the solid surface. Ignores first surface along each axis systematically (for points inside or outside. Early returns zero in case the second surface is behind the starting point. The normal vector to the crossed surface is always filled. In the case the considered point is located inside the G4MultiUnion structure, it acts as follows:
| [in] | aPoint | The reference point in space. |
| [in] | aDirection | The normalised direction. |
| [in] | calcNorm | Flag unused. |
| [out] | validNorm | Unused. |
| [out] | aNormalVector | The exiting outwards normal vector (undefined Magnitude). |
Implements G4VSolid.
Definition at line 272 of file G4MultiUnion.cc.
| G4double G4MultiUnion::DistanceToOutNoVoxels | ( | const G4ThreeVector & | aPoint, |
| const G4ThreeVector & | aDirection, | ||
| G4ThreeVector * | aNormalVector ) const |
Definition at line 221 of file G4MultiUnion.cc.
| G4double G4MultiUnion::DistanceToOutVoxels | ( | const G4ThreeVector & | aPoint, |
| const G4ThreeVector & | aDirection, | ||
| G4ThreeVector * | aNormalVector ) const |
Definition at line 282 of file G4MultiUnion.cc.
Referenced by DistanceToOut().
Determines the bounding box for the considered instance of G4MultiUnion.
| [in] | aAxis | The axis along which computing the extent. |
| [out] | aMin | The minimum bounding limit point. |
| [out] | aMax | The maximum bounding limit point. |
Definition at line 523 of file G4MultiUnion.cc.
Referenced by BoundingLimits().
|
overridevirtual |
Returns an estimate of the structure capacity or surface area.
Reimplemented from G4VSolid.
Definition at line 938 of file G4MultiUnion.cc.
|
inlineoverridevirtual |
Returns the type ID, "G4MultiUnion" of the solid.
Implements G4VSolid.
Definition at line 231 of file G4MultiUnion.hh.
|
inline |
|
overridevirtual |
Returns the number of solids part of the structure.
Reimplemented from G4VSolid.
Definition at line 780 of file G4MultiUnion.cc.
|
overridevirtual |
Returns a point (G4ThreeVector) randomly and uniformly generated on the surface of a solid.
Reimplemented from G4VSolid.
Definition at line 921 of file G4MultiUnion.cc.
|
overridevirtual |
Smart access function - creates on request and stores for future access. A null pointer means "not available".
Reimplemented from G4VSolid.
Definition at line 1004 of file G4MultiUnion.cc.
|
overridevirtual |
Returns an estimation of the solid surface area in internal units. This method may be overloaded by derived classes to compute the exact geometrical quantity for solids where this is possible, or anyway to cache the computed value. Note: the computed value is NOT cached.
Reimplemented from G4VSolid.
Definition at line 950 of file G4MultiUnion.cc.
|
inline |
Accessors to retrieve a transformation or a solid, given an index and the total number of solids in the structure.
Referenced by CreatePolyhedron(), G4tgbGeometryDumper::DumpMultiUnionVolume(), Extent(), and G4GDMLWriteSolids::MultiUnionWrite().
|
inline |
Returns the xoxelised optimisation structure.
|
overridevirtual |
Returns if the given point "aPoint" is inside or not the solid.
Implements G4VSolid.
Definition at line 490 of file G4MultiUnion.cc.
Referenced by GetPointOnSurface().
|
overridevirtual |
Returns false if any of the solids part of the structure is not faceted.
Reimplemented from G4VSolid.
Definition at line 791 of file G4MultiUnion.cc.
| G4MultiUnion & G4MultiUnion::operator= | ( | const G4MultiUnion & | rhs | ) |
Definition at line 110 of file G4MultiUnion.cc.
|
inline |
|
overridevirtual |
Streams the object contents to an output stream.
Implements G4VSolid.
Definition at line 895 of file G4MultiUnion.cc.
|
overridevirtual |
Returns the outwards pointing unit normal of the shape for the surface closest to the point at offset "aPoint".
Implements G4VSolid.
Definition at line 609 of file G4MultiUnion.cc.
| void G4MultiUnion::Voxelize | ( | ) |
Finalises and prepares for use, creating the optimisation structure for all solids in the structure. It must be called once before navigation use.
Definition at line 801 of file G4MultiUnion.cc.
Referenced by G4tgbVolume::FindOrConstructG4Solid(), and G4GDMLReadSolids::MultiUnionRead().
|
friend |
Definition at line 63 of file G4MultiUnion.hh.
Referenced by G4Voxelizer, and GetVoxels().