82 if (fRadius < newRadius) fRadius = newRadius;
84 else if (join.
mag () + newRadius <= fRadius) {
89 G4Point3D oldExtremity1 = fCentre - fRadius * unitJoin;
90 G4Point3D newExtremity1 = newCentre - newRadius * unitJoin;
91 G4Point3D oldExtremity2 = fCentre + fRadius * unitJoin;
92 G4Point3D newExtremity2 = newCentre + newRadius * unitJoin;
94 if (oldExtremity1 * unitJoin < newExtremity1 * unitJoin) {
95 extremity1 = oldExtremity1;
98 extremity1 = newExtremity1;
101 if (oldExtremity2 * unitJoin > newExtremity2 * unitJoin) {
102 extremity2 = oldExtremity2;
105 extremity2 = newExtremity2;
107 fCentre = 0.5 * (extremity2 + extremity1);
108 fRadius = 0.5 * (extremity2 - extremity1).mag ();
virtual ~G4BoundingSphereScene()
virtual G4VisExtent GetExtent() const
BasicVector3D< T > unit() const
const G4Point3D & GetExtentCentre() const
void ProcessVolume(const G4VSolid &solid)
void AccrueBoundingSphere(const G4Point3D ¢re, G4double radius)
void CurtailDescent() const
void ResetBoundingSphere()
G4VisExtent GetBoundingSphereExtent()
G4BoundingSphereScene(G4VModel *pModel=0)
G4double GetExtentRadius() const
const G4Transform3D * fpCurrentObjectTransformation
HepGeom::Point3D< G4double > G4Point3D