|
|
|||
Warning, file /geant4/examples/extended/geometry/transforms/include/DetectorConstruction.hh was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001 // 0002 // ******************************************************************** 0003 // * License and Disclaimer * 0004 // * * 0005 // * The Geant4 software is copyright of the Copyright Holders of * 0006 // * the Geant4 Collaboration. It is provided under the terms and * 0007 // * conditions of the Geant4 Software License, included in the file * 0008 // * LICENSE and available at http://cern.ch/geant4/license . These * 0009 // * include a list of copyright holders. * 0010 // * * 0011 // * Neither the authors of this software system, nor their employing * 0012 // * institutes,nor the agencies providing financial support for this * 0013 // * work make any representation or warranty, express or implied, * 0014 // * regarding this software system or assume any liability for its * 0015 // * use. Please see the license in the file LICENSE and URL above * 0016 // * for the full disclaimer and the limitation of liability. * 0017 // * * 0018 // * This code implementation is the result of the scientific and * 0019 // * technical work of the GEANT4 collaboration. * 0020 // * By using, copying, modifying or distributing the software (or * 0021 // * any work based on the software) you agree to acknowledge its * 0022 // * use in resulting scientific publications, and indicate your * 0023 // * acceptance of all terms of the Geant4 Software license. * 0024 // ******************************************************************** 0025 // 0026 /// \file DetectorConstruction.hh 0027 /// \brief Definition of the DetectorConstruction class 0028 0029 #ifndef DetectorConstruction_h 0030 #define DetectorConstruction_h 1 0031 0032 #include "G4VUserDetectorConstruction.hh" 0033 #include "globals.hh" 0034 0035 class DetectorMessenger; 0036 class G4LogicalVolume; 0037 class G4VPhysicalVolume; 0038 0039 /// Detector construction class to demonstrate various ways of placement 0040 /// 0041 /// The geometry setup consists of two trapezoid volumes which are placed 0042 /// in a world so that their axial symmetry axis is in given theta and phi 0043 /// polar angles. The various ways of placement are implemented in the 0044 /// DetectorConstruction class in the following private functions: 0045 /// - PlaceWithDirectMatrix() 0046 /// - PlaceWithInverseMatrix() 0047 /// - PlaceWithAxialRotations() 0048 /// - PlaceWithEulerAngles() 0049 /// - PlaceWithReflections() 0050 /// 0051 /// which are then called from the Construct() function. 0052 /// All method defines exactly same geometry except for the placement 0053 /// with reflection where trapezoids are placed with their symmetry axis 0054 /// in parallel with z-axis in order to make easier to check reflection 0055 /// visually. 0056 0057 class DetectorConstruction : public G4VUserDetectorConstruction 0058 { 0059 public: 0060 enum EMethod 0061 { 0062 kWithDirectMatrix, 0063 kWithInverseMatrix, 0064 kWithAxialRotations, 0065 kWithEulerAngles, 0066 kWithReflections 0067 }; 0068 0069 public: 0070 DetectorConstruction(); 0071 ~DetectorConstruction() override; 0072 0073 public: 0074 // methods from base class 0075 G4VPhysicalVolume* Construct() override; 0076 0077 // set methods 0078 void SetMethod(EMethod method); 0079 0080 private: 0081 // methods 0082 void PlaceWithDirectMatrix(); 0083 void PlaceWithInverseMatrix(); 0084 void PlaceWithAxialRotations(); 0085 void PlaceWithEulerAngles(); 0086 void PlaceWithReflections(); 0087 0088 // data members 0089 DetectorMessenger* fMessenger = nullptr; 0090 EMethod fMethod = kWithDirectMatrix; 0091 G4LogicalVolume* fWorldVolume = nullptr; 0092 G4LogicalVolume* fTrdVolume = nullptr; 0093 }; 0094 0095 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 0096 0097 #endif
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|