Geant4  v4-10.4-release
 모두 클래스 네임스페이스들 파일들 함수 변수 타입정의 열거형 타입 열거형 멤버 Friends 매크로 그룹들 페이지들
G4ScaledSolid.hh
이 파일의 문서화 페이지로 가기
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 //
26 //
27 // $Id:$
28 //
29 //
30 // class G4ScaledSolid
31 //
32 // Class description:
33 //
34 // A scaled solid is a solid that has been scaled in dimensions
35 // in X, Y or Z, from its original description.
36 
37 // History:
38 //
39 // 27.10.15 G.Cosmo: created
40 //
41 // --------------------------------------------------------------------
42 #ifndef G4ScaledSolid_HH
43 #define G4ScaledSolid_HH
44 
45 #include "G4VSolid.hh"
46 #include "G4ThreeVector.hh"
47 #include "G4Transform3D.hh"
48 #include "G4AffineTransform.hh"
49 
50 class G4ScaleTransform;
51 
52 class G4ScaledSolid : public G4VSolid
53 {
54  public: // with description
55 
56  G4ScaledSolid( const G4String& pName,
57  G4VSolid* pSolid ,
58  const G4Scale3D& pScale );
59 
60  virtual ~G4ScaledSolid();
61 
62  EInside Inside( const G4ThreeVector& p ) const;
63 
64  void BoundingLimits(G4ThreeVector& pMin, G4ThreeVector& pMax) const;
65 
66  G4bool CalculateExtent(const EAxis pAxis,
67  const G4VoxelLimits& pVoxelLimit,
68  const G4AffineTransform& pTransform,
69  G4double& pMin, G4double& pMax) const;
70 
71  G4ThreeVector SurfaceNormal( const G4ThreeVector& p ) const;
72 
74  const G4ThreeVector& v ) const;
75 
76  G4double DistanceToIn( const G4ThreeVector& p) const;
77 
79  const G4ThreeVector& v,
80  const G4bool calcNorm=false,
81  G4bool *validNorm=0,
82  G4ThreeVector *n=0 ) const;
83 
84  G4double DistanceToOut( const G4ThreeVector& p ) const;
85 
87  const G4int n,
88  const G4VPhysicalVolume* pRep );
89 
90  void CleanTransformations();
91 
93 
95  void SetScaleTransform(const G4Scale3D& scale);
96 
97  G4VSolid* GetUnscaledSolid() const;
98 
100  G4VSolid* Clone() const;
101 
102  std::ostream& StreamInfo(std::ostream& os) const;
103 
104  public: // without description
105 
106  G4ScaledSolid(__void__&);
107  // Fake default constructor for usage restricted to direct object
108  // persistency for clients requiring preallocation of memory for
109  // persistifiable objects.
110 
111  G4ScaledSolid(const G4ScaledSolid& rhs);
113  // Copy constructor and assignment operator.
114 
115  void DescribeYourselfTo ( G4VGraphicsScene& scene ) const;
116  G4Polyhedron* CreatePolyhedron () const;
117  G4Polyhedron* GetPolyhedron () const;
118  // For creating graphical representations (i.e. for visualisation).
119 
120  private:
121 
126 } ;
127 
128 #endif
G4bool fRebuildPolyhedron
EInside Inside(const G4ThreeVector &p) const
const char * p
Definition: xmltok.h:285
G4Scale3D GetScaleTransform() const
void BoundingLimits(G4ThreeVector &pMin, G4ThreeVector &pMax) const
G4ThreeVector GetPointOnSurface() const
G4VSolid * Clone() const
void SetScaleTransform(const G4Scale3D &scale)
G4bool CalculateExtent(const EAxis pAxis, const G4VoxelLimits &pVoxelLimit, const G4AffineTransform &pTransform, G4double &pMin, G4double &pMax) const
std::ostream & StreamInfo(std::ostream &os) const
double G4double
Definition: G4Types.hh:76
bool G4bool
Definition: G4Types.hh:79
Double_t scale
G4ScaleTransform * fScale
G4double DistanceToOut(const G4ThreeVector &p, const G4ThreeVector &v, const G4bool calcNorm=false, G4bool *validNorm=0, G4ThreeVector *n=0) const
G4VSolid * fPtrSolid
G4GeometryType GetEntityType() const
G4ScaledSolid(const G4String &pName, G4VSolid *pSolid, const G4Scale3D &pScale)
int G4int
Definition: G4Types.hh:78
EInside
Definition: geomdefs.hh:58
virtual ~G4ScaledSolid()
EAxis
Definition: geomdefs.hh:54
G4Polyhedron * fpPolyhedron
G4VSolid * GetUnscaledSolid() const
G4double DistanceToIn(const G4ThreeVector &p, const G4ThreeVector &v) const
G4ScaledSolid & operator=(const G4ScaledSolid &rhs)
Char_t n[5]
void ComputeDimensions(G4VPVParameterisation *p, const G4int n, const G4VPhysicalVolume *pRep)
G4Polyhedron * CreatePolyhedron() const
G4Polyhedron * GetPolyhedron() const
void CleanTransformations()
G4ThreeVector SurfaceNormal(const G4ThreeVector &p) const
void DescribeYourselfTo(G4VGraphicsScene &scene) const