Import Geant4 3.0.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-08 15:55:53 +02:00
parent e7d7193284
commit cfcb558cfe
3050 changed files with 91703 additions and 48310 deletions
+43 -22
View File
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: G4VSolid.cc,v 1.4 2000/04/11 16:18:15 johna Exp $
// GEANT4 tag $Name: geant4-02-00 $
// $Id: G4VSolid.cc,v 1.6 2000/11/16 14:29:23 grichine Exp $
// GEANT4 tag $Name: geant4-03-00 $
//
// class G4VSolid
//
@@ -16,6 +16,8 @@
// History:
// 10.07.95 P.Kent Added == operator, solid Store entry
// 30.06.95 P.Kent
// 15.11.00 D.Williams, V.Grichine change in CalculateClippedPolygonExtent:
// else if(component>pMax) ---> if
#include "G4VSolid.hh"
#include "G4SolidStore.hh"
@@ -59,34 +61,43 @@ void G4VSolid::ComputeDimensions(G4VPVParameterisation* p,
G4Exception("G4VSolid::ComputeDimensions called illegally: not overloaded by derived class");
}
///////////////////////////////////////////////////////////////////////////////
//
// Calculate the maximum and minimum extents of the convex polygon pPolygon
// along the axis pAxis, within the limits pVoxelLimit
//
void G4VSolid::CalculateClippedPolygonExtent(G4ThreeVectorList& pPolygon,
const G4VoxelLimits& pVoxelLimit,
const EAxis pAxis,
G4double& pMin, G4double& pMax) const
{
G4int noLeft,i;
G4double component;
ClipPolygon(pPolygon,pVoxelLimit);
noLeft=pPolygon.entries();
if (noLeft)
{
for (i=0;i<noLeft;i++)
{
component=pPolygon(i).operator()(pAxis);
if (component<pMin)
{
pMin=component;
}
else if (component>pMax)
{
pMax=component;
}
}
}
G4int noLeft,i;
G4double component;
ClipPolygon(pPolygon,pVoxelLimit);
noLeft = pPolygon.entries();
if (noLeft)
{
for (i=0;i<noLeft;i++)
{
component = pPolygon(i).operator()(pAxis);
if (component < pMin)
{
pMin = component;
}
// else
if (component > pMax)
{
pMax = component;
}
}
}
}
///////////////////////////////////////////////////////////////////////////
//
// Calculate the maximum and minimum extents of the polygon described
// by the vertices: pSectionIndex->pSectionIndex+1->
// pSectionIndex+2->pSectionIndex+3->pSectionIndex
@@ -337,3 +348,13 @@ G4VisExtent G4VSolid::GetExtent () const {
extent.SetZmax (vmax);
return extent;
}
G4Polyhedron* G4VSolid::CreatePolyhedron () const
{
return 0;
}
G4NURBS* G4VSolid::CreateNURBS () const
{
return 0;
}