Import Geant4 0.1.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-08 15:09:25 +02:00
parent b97f8d0df7
commit aaa409b6ee
2922 changed files with 55107 additions and 81674 deletions
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4BoundingSphereScene.hh,v 2.2 1998/08/22 16:34:57 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4BoundingSphereScene.hh,v 1.4 1999/05/10 14:04:20 johna Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 7th June 1997
@@ -25,21 +25,25 @@
#include "G4Sphere.hh"
#include "G4Para.hh"
#include "G4Torus.hh"
#include "G4Polycone.hh"
#include "G4Polyhedra.hh"
class G4BoundingSphereScene: public G4VGraphicsScene {
public:
G4BoundingSphereScene ();
~G4BoundingSphereScene ();
virtual void AddThis (const G4Box& s) {Accrue (s);}
virtual void AddThis (const G4Cons& s) {Accrue (s);}
virtual void AddThis (const G4Tubs& s) {Accrue (s);}
virtual void AddThis (const G4Trd& s) {Accrue (s);}
virtual void AddThis (const G4Trap& s) {Accrue (s);}
virtual void AddThis (const G4Sphere& s) {Accrue (s);}
virtual void AddThis (const G4Para& s) {Accrue (s);}
virtual void AddThis (const G4Torus& s) {Accrue (s);}
virtual void AddThis (const G4VSolid& s) {Accrue (s);}
void AddThis (const G4Box& s) {Accrue (s);}
void AddThis (const G4Cons& s) {Accrue (s);}
void AddThis (const G4Tubs& s) {Accrue (s);}
void AddThis (const G4Trd& s) {Accrue (s);}
void AddThis (const G4Trap& s) {Accrue (s);}
void AddThis (const G4Sphere& s) {Accrue (s);}
void AddThis (const G4Para& s) {Accrue (s);}
void AddThis (const G4Torus& s) {Accrue (s);}
void AddThis (const G4Polycone& s) {Accrue (s);}
void AddThis (const G4Polyhedra& s) {Accrue (s);}
void AddThis (const G4VSolid& s) {Accrue (s);}
void PreAddThis (const G4Transform3D& objectTransformation,
const G4VisAttributes&) {
fpObjectTransformation = &objectTransformation;
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4FlavoredParallelWorldModel.hh,v 2.3 1998/08/22 16:34:58 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4FlavoredParallelWorldModel.hh,v 1.3 1999/04/16 09:05:39 mora Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
// P. Mora de Freitas et M.Verderi - 19 June 1998.
// Model for flavored parallel world volumes.
@@ -16,14 +16,14 @@
#include "G4PhysicalVolumeModel.hh"
class G4FlavoredParallelWorld;
class G4VFlavoredParallelWorld;
class G4FlavoredParallelWorldModel : public G4PhysicalVolumeModel {
public:
G4FlavoredParallelWorldModel
(G4FlavoredParallelWorld* FPW,
(G4VFlavoredParallelWorld* FPW,
G4int soughtDepth = G4PhysicalVolumeModel::UNLIMITED,
const G4Transform3D& modelTransformation = G4Transform3D::Identity,
const G4ModelingParameters* mp = 0);
@@ -32,7 +32,7 @@ public:
private:
G4FlavoredParallelWorld* theFlavoredParallelWorld;
G4VFlavoredParallelWorld* theFlavoredParallelWorld;
};
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4HitsModel.hh,v 1.2 1998/08/31 15:41:59 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4HitsModel.hh,v 1.2 1999/01/11 00:48:43 allison Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 26th August 1998.
@@ -5,10 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4HitsModel.icc,v 2.1 1998/08/31 15:42:00 allison Exp $
// GEANT4 tag $Name: geant4-00 $
inline G4HitsModel::~G4HitsModel () {}
// $Id: G4HitsModel.icc,v 1.3 1999/05/10 14:04:22 johna Exp $
// GEANT4 tag $Name: geant4-00-01 $
inline G4String G4HitsModel::GetCurrentTag () const {
return fGlobalTag;
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4ModelingParameters.hh,v 2.2 1998/11/25 16:24:28 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4ModelingParameters.hh,v 1.3 1999/05/25 09:14:23 johna Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 31st December 1997.
@@ -25,8 +25,6 @@ class G4VisAttributes;
class G4ModelingParameters {
friend ostream& operator << (ostream& os, const G4ModelingParameters&);
friend G4bool operator != (const G4ModelingParameters&,
const G4ModelingParameters&);
public:
@@ -48,7 +46,23 @@ public:
G4bool isDensityCulling,
G4double visibleDensity,
G4bool isCullingCovered,
G4int noOfSides);
G4int noOfSides
);
// noOfSides is suggested no. of sides per circle in case a
// polygonal representation is produced.
G4ModelingParameters (const G4VisAttributes* pDefaultVisAttributes,
RepStyle repStyle,
G4bool isCulling,
G4bool isCullingInvisible,
G4bool isDensityCulling,
G4double visibleDensity,
G4bool isCullingCovered,
G4int noOfSides,
G4bool isViewGeom,
G4bool isViewHits,
G4bool isViewDigis
);
// noOfSides is suggested no. of sides per circle in case a
// polygonal representation is produced.
@@ -56,6 +70,8 @@ public:
// Note: uses default assignment operator and copy constructor.
G4bool operator != (const G4ModelingParameters&) const;
// Get and Is functions...
const G4VisAttributes* GetDefaultVisAttributes () const;
RepStyle GetRepStyle () const;
@@ -65,6 +81,9 @@ public:
G4double GetVisibleDensity () const;
G4bool IsCullingCovered () const;
G4int GetNoOfSides () const;
G4bool IsViewGeom () const;
G4bool IsViewHits () const;
G4bool IsViewDigis () const;
// Set functions...
void SetDefaultVisAttributes (const G4VisAttributes* pDefaultVisAttributes);
@@ -75,6 +94,12 @@ public:
void SetVisibleDensity (G4double);
void SetCullingCovered (G4bool);
void SetNoOfSides (G4int);
void SetViewGeom ();
void UnsetViewGeom ();
void SetViewHits ();
void UnsetViewHits ();
void SetViewDigis ();
void UnsetViewDigis ();
// Other functions...
void PrintDifferences (const G4ModelingParameters& that) const;
@@ -90,6 +115,9 @@ private:
G4double fVisibleDensity; // ...density lower than this not drawn.
G4bool fCullCovered; // Cull daughters covered by opaque mothers.
G4int fNoOfSides; // ...if polygon approximates circle.
G4bool fViewGeom; // View geometry objects.
G4bool fViewHits; // View hits, if any.
G4bool fViewDigis; // View digis, if any.
};
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4ModelingParameters.icc,v 2.1 1998/11/25 16:24:30 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4ModelingParameters.icc,v 1.2 1999/01/10 13:25:49 allison Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 31st December 1997.
@@ -46,6 +46,18 @@ inline G4int G4ModelingParameters::GetNoOfSides () const {
return fNoOfSides;
}
inline G4bool G4ModelingParameters::IsViewGeom () const {
return fViewGeom;
}
inline G4bool G4ModelingParameters::IsViewHits () const {
return fViewHits;
}
inline G4bool G4ModelingParameters::IsViewDigis () const {
return fViewDigis;
}
inline void G4ModelingParameters::SetDefaultVisAttributes
(const G4VisAttributes* pDefaultVisAttributes) {
fpDefaultVisAttributes = pDefaultVisAttributes;
@@ -71,3 +83,27 @@ inline void G4ModelingParameters::SetDensityCulling (G4bool value) {
inline void G4ModelingParameters::SetCullingCovered (G4bool value) {
fCullCovered = value;
}
inline void G4ModelingParameters::SetViewGeom () {
fViewGeom = true;
}
inline void G4ModelingParameters::UnsetViewGeom () {
fViewGeom = false;
}
inline void G4ModelingParameters::SetViewHits () {
fViewHits = true;
}
inline void G4ModelingParameters::UnsetViewHits () {
fViewHits = false;
}
inline void G4ModelingParameters::SetViewDigis () {
fViewDigis = true;
}
inline void G4ModelingParameters::UnsetViewDigis () {
fViewDigis = false;
}
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4NullModel.hh,v 2.1 1998/08/31 15:42:01 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4NullModel.hh,v 1.3 1999/05/10 14:04:23 johna Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 4th April 1998.
@@ -24,12 +24,12 @@ public:
G4NullModel (const G4ModelingParameters* = 0);
~G4NullModel ();
virtual ~G4NullModel ();
virtual void DescribeYourselfTo (G4VGraphicsScene&);
void DescribeYourselfTo (G4VGraphicsScene&);
// An exception is thrown if this is called!!!!!!!!!!!!!!!!!!!!
virtual G4bool Validate ();
G4bool Validate ();
// Validate, but allow internal changes (hence non-const function).
/////////////////////////////////////////////////
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4PhysicalVolumeModel.hh,v 2.3 1998/08/31 15:42:02 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4PhysicalVolumeModel.hh,v 1.3 1999/05/10 14:04:24 johna Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 31st December 1997.
@@ -39,9 +39,9 @@ public:
const G4Transform3D& modelTransformation = G4Transform3D::Identity,
const G4ModelingParameters* = 0);
~G4PhysicalVolumeModel ();
virtual ~G4PhysicalVolumeModel ();
virtual void DescribeYourselfTo (G4VGraphicsScene&);
void DescribeYourselfTo (G4VGraphicsScene&);
// The main task of a model is to describe itself to the scene. It
// can also provide special information through pointers to working
// space in the scene. These pointers must be set up (if required
@@ -52,13 +52,13 @@ public:
// here. To see how this works, look at the implementation of this
// function and G4VScene::Establish/DecommissionSpecials.
virtual G4String GetCurrentTag () const;
G4String GetCurrentTag () const;
// A tag which depends on the current state of the model.
virtual G4String GetCurrentDescription () const;
G4String GetCurrentDescription () const;
// A description which depends on the current state of the model.
virtual G4bool Validate ();
G4bool Validate ();
// Validate, but allow internal changes (hence non-const function).
//////////////////////////////////////////////////////////
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4PhysicalVolumeModel.icc,v 2.0 1998/07/02 16:50:29 gunter Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4PhysicalVolumeModel.icc,v 1.2 1999/01/11 00:48:45 allison Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 31st December 1997.
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4PhysicalVolumeSearchScene.hh,v 2.2 1998/08/22 16:34:59 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4PhysicalVolumeSearchScene.hh,v 1.4 1999/05/10 14:04:25 johna Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 10th August 1998.
@@ -25,6 +25,8 @@
#include "G4Sphere.hh"
#include "G4Para.hh"
#include "G4Torus.hh"
#include "G4Polycone.hh"
#include "G4Polyhedra.hh"
#include "G4VPhysicalVolume.hh"
#include "G4LogicalVolume.hh"
@@ -33,7 +35,7 @@ class G4PhysicalVolumeSearchScene: public G4VGraphicsScene {
public:
G4PhysicalVolumeSearchScene
(const G4String& requiredPhysicalVolumeName, G4int requiredCopyNo);
~G4PhysicalVolumeSearchScene ();
virtual ~G4PhysicalVolumeSearchScene ();
void AddThis (const G4Box& s) {FindVolume (s);}
void AddThis (const G4Cons & s) {FindVolume (s);}
void AddThis (const G4Tubs& s) {FindVolume (s);}
@@ -42,6 +44,8 @@ public:
void AddThis (const G4Sphere& s) {FindVolume (s);}
void AddThis (const G4Para& s) {FindVolume (s);}
void AddThis (const G4Torus& s) {FindVolume (s);}
void AddThis (const G4Polycone& s) {FindVolume (s);}
void AddThis (const G4Polyhedra& s) {FindVolume (s);}
void AddThis (const G4VSolid& s) {FindVolume (s);}
void PreAddThis (const G4Transform3D& objectTransformation,
const G4VisAttributes&);
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4PhysicalVolumeSearchScene.icc,v 2.1 1998/08/22 16:35:00 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4PhysicalVolumeSearchScene.icc,v 1.2 1999/01/11 00:48:46 allison Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 10th August 1998.
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4TrajectoriesModel.hh,v 1.2 1998/08/31 15:42:03 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4TrajectoriesModel.hh,v 1.2 1999/01/11 00:48:47 allison Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 26th August 1998.
@@ -5,10 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4TrajectoriesModel.icc,v 2.1 1998/08/31 15:42:04 allison Exp $
// GEANT4 tag $Name: geant4-00 $
inline G4TrajectoriesModel::~G4TrajectoriesModel () {}
// $Id: G4TrajectoriesModel.icc,v 1.3 1999/05/10 14:04:27 johna Exp $
// GEANT4 tag $Name: geant4-00-01 $
inline G4String G4TrajectoriesModel::GetCurrentTag () const {
return fGlobalTag;
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4VModel.hh,v 2.3 1998/08/31 15:42:05 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4VModel.hh,v 1.2 1999/01/11 00:48:49 allison Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 31st December 1997.
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4VModel.icc,v 2.3 1998/08/31 15:42:06 allison Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: G4VModel.icc,v 1.2 1999/01/11 00:48:50 allison Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
// John Allison 31st December 1997.