File indexing completed on 2025-10-26 08:45:03
0001 
0002 
0003 
0004 
0005 
0006 
0007 
0008 
0009 
0010 
0011 
0012 
0013 
0014 
0015 
0016 
0017 
0018 
0019 
0020 
0021 
0022 
0023 
0024 
0025 
0026 
0027 
0028 
0029 
0030 
0031 
0032 
0033 
0034 #ifndef G4SUBTRACTIONSOLID_HH
0035 #define G4SUBTRACTIONSOLID_HH
0036 
0037 #include "G4BooleanSolid.hh"
0038 #include "G4VSolid.hh"
0039 
0040 #include "G4RotationMatrix.hh"
0041 #include "G4ThreeVector.hh"
0042 #include "G4Transform3D.hh"
0043 #include "G4AffineTransform.hh"
0044 
0045 
0046 class G4SubtractionSolid : public G4BooleanSolid
0047 {
0048   public:
0049 
0050     G4SubtractionSolid(  const G4String& pName,
0051                                G4VSolid* pSolidA ,
0052                                G4VSolid* pSolidB   ) ;
0053 
0054     G4SubtractionSolid(  const G4String& pName,
0055                                G4VSolid* pSolidA ,
0056                                G4VSolid* pSolidB ,
0057                                G4RotationMatrix* rotMatrix,
0058                          const G4ThreeVector& transVector   ) ;
0059 
0060     G4SubtractionSolid(  const G4String& pName,
0061                                G4VSolid* pSolidA ,
0062                                G4VSolid* pSolidB ,
0063                          const G4Transform3D& transform   ) ;
0064 
0065     ~G4SubtractionSolid() override ;
0066 
0067     G4GeometryType  GetEntityType() const override ;
0068 
0069     G4VSolid* Clone() const override;
0070 
0071     G4SubtractionSolid(__void__&);
0072       
0073       
0074       
0075 
0076     G4SubtractionSolid(const G4SubtractionSolid& rhs);
0077     G4SubtractionSolid& operator=(const G4SubtractionSolid& rhs);
0078       
0079 
0080     void BoundingLimits(G4ThreeVector& pMin, G4ThreeVector& pMax) const override;
0081 
0082     G4bool CalculateExtent( const EAxis pAxis,
0083                             const G4VoxelLimits& pVoxelLimit,
0084                             const G4AffineTransform& pTransform,
0085                                   G4double& pMin, G4double& pMax) const override ;
0086        
0087     EInside Inside( const G4ThreeVector& p ) const override ;
0088 
0089     G4ThreeVector SurfaceNormal( const G4ThreeVector& p ) const override ;
0090 
0091     G4double DistanceToIn( const G4ThreeVector& p,
0092                            const G4ThreeVector& v  ) const override ;
0093 
0094     G4double DistanceToIn( const G4ThreeVector& p) const override ;
0095 
0096     G4double DistanceToOut( const G4ThreeVector& p,
0097                             const G4ThreeVector& v,
0098                             const G4bool calcNorm = false,
0099                                   G4bool* validNorm = nullptr,
0100                                   G4ThreeVector* n = nullptr ) const override ;
0101 
0102     G4double DistanceToOut( const G4ThreeVector& p ) const override ;
0103 
0104 
0105     void ComputeDimensions(       G4VPVParameterisation* p,
0106                             const G4int n,
0107                             const G4VPhysicalVolume* pRep ) override ;
0108                                    
0109     void DescribeYourselfTo ( G4VGraphicsScene& scene ) const override ;
0110     G4Polyhedron* CreatePolyhedron () const override ;
0111 
0112     G4double GetCubicVolume() final;
0113 };
0114 
0115 #endif