|
||||
File indexing completed on 2025-01-18 09:58:21
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 // class G4GeomTestVolume 0027 // 0028 // Class description: 0029 // 0030 // Checks for inconsistencies in the geometric boundaries of a physical 0031 // volume and the boundaries of all its immediate daughters. 0032 0033 // Author: G.Cosmo, CERN 0034 // -------------------------------------------------------------------- 0035 #ifndef G4GeomTestVolume_hh 0036 #define G4GeomTestVolume_hh 0037 0038 #include "G4ThreeVector.hh" 0039 0040 class G4VPhysicalVolume; 0041 class G4GeomTestLogger; 0042 0043 class G4GeomTestVolume 0044 { 0045 public: // with description 0046 0047 G4GeomTestVolume( G4VPhysicalVolume *theTarget, 0048 G4double theTolerance = 0.0, // mm 0049 G4int numberOfPoints = 10000, 0050 G4bool theVerbosity = true); 0051 ~G4GeomTestVolume(); 0052 // Constructor and destructor 0053 0054 G4double GetTolerance() const; 0055 void SetTolerance(G4double tolerance); 0056 // Get/Set error tolerance (default set to 0*mm) 0057 G4int GetResolution() const; 0058 void SetResolution(G4int points); 0059 // Get/Set number of points to check (default set to 10000) 0060 G4bool GetVerbosity() const; 0061 void SetVerbosity(G4bool verbosity); 0062 // Get/Set verbosity mode (default set to true) 0063 G4int GetErrorsThreshold() const; 0064 void SetErrorsThreshold(G4int max); 0065 // Get/Set maximum number of errors to report (default set to 1) 0066 0067 void TestOverlapInTree() const; 0068 // Check overlaps in the volume tree without 0069 // dublication in identical logical volumes 0070 0071 void TestRecursiveOverlap( G4int sLevel=0, G4int depth=-1 ); 0072 // Activate overlaps check, propagating recursively to the daughters, 0073 // with possibility of specifying the initial level in the volume tree 0074 // and the depth (default is the whole tree). 0075 // Be careful: depending on the complexity of the geometry, this 0076 // could require long computational time 0077 0078 private: 0079 0080 G4VPhysicalVolume *target; // Target volume 0081 G4double tolerance; // Error tolerance 0082 G4int resolution; // Number of points to test 0083 G4int maxErr = 1; // Maximum number of errors to report 0084 G4bool verbosity; // Verbosity level for overlaps check 0085 }; 0086 0087 #endif
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |