35#ifndef G4VTWISTEDFACETED_HH
36#define G4VTWISTEDFACETED_HH
87 const G4bool calcnorm =
false,
88 G4bool* validnorm =
nullptr,
107 virtual std::ostream &
StreamInfo(std::ostream& os)
const;
156 void CreateSurfaces();
204 p.
set(kInfinity,kInfinity,kInfinity); inside =
kOutside;
207 LastState(
const LastState& r) : p(r.p), inside(r.inside){}
208 LastState& operator=(
const LastState& r)
210 if (
this == &r) {
return *
this; }
211 p = r.p; inside = r.inside;
224 p.
set(kInfinity,kInfinity,kInfinity);
225 vec.set(kInfinity,kInfinity,kInfinity);
232 LastVector(
const LastVector& r) : p(r.p), vec(r.vec)
235 surface[0] = r.surface[0];
237 LastVector&
operator=(
const LastVector& r)
239 if (&r ==
this) {
return *
this; }
240 p = r.p; vec = r.vec;
242 surface[0] = r.surface[0];
256 p.
set(kInfinity,kInfinity,kInfinity);
260 LastValue(
const LastValue& r) : p(r.p), value(r.value){}
263 if (
this == &r) {
return *
this; }
264 p = r.p; value = r.value;
272 class LastValueWithDoubleVector
275 LastValueWithDoubleVector()
277 p.
set(kInfinity,kInfinity,kInfinity);
278 vec.set(kInfinity,kInfinity,kInfinity);
281 ~LastValueWithDoubleVector(){}
282 LastValueWithDoubleVector(
const LastValueWithDoubleVector& r)
283 : p(r.p), vec(r.vec), value(r.value){}
284 LastValueWithDoubleVector&
operator=(
const LastValueWithDoubleVector& r)
286 if (
this == &r) {
return *
this; }
287 p = r.p; vec = r.vec; value = r.value;
296 LastState fLastInside;
297 LastVector fLastNormal;
298 LastValue fLastDistanceToIn;
299 LastValue fLastDistanceToOut;
300 LastValueWithDoubleVector fLastDistanceToInWithV;
301 LastValueWithDoubleVector fLastDistanceToOutWithV;
309 return ( fDx4 + fDx2 + ( fDx4 - fDx2 ) * ( 2 * phi ) / fPhiTwist ) ;
315 return ( fDx3 + fDx1 + ( fDx3 - fDx1 ) * ( 2 * phi ) / fPhiTwist ) ;
321 return ( fDy2 + fDy1 + ( fDy2 - fDy1 ) * ( 2 * phi ) / fPhiTwist ) ;
void set(double x, double y, double z)
G4double GetValueD(G4double phi) const
virtual G4double GetCubicVolume()
virtual void BoundingLimits(G4ThreeVector &pMin, G4ThreeVector &pMax) const
G4double GetValueA(G4double phi) const
virtual G4double DistanceToIn(const G4ThreeVector &p, const G4ThreeVector &v) const
virtual G4ThreeVector SurfaceNormal(const G4ThreeVector &p) const
G4double GetTheta() const
G4VTwistedFaceted & operator=(const G4VTwistedFaceted &rhs)
G4Polyhedron * fpPolyhedron
virtual G4Polyhedron * GetPolyhedron() const
G4ThreeVector GetPointOnSurface() const
virtual G4GeometryType GetEntityType() const
G4double GetTwistAngle() const
G4bool fRebuildPolyhedron
G4ThreeVector GetPointInSolid(G4double z) const
virtual G4bool CalculateExtent(const EAxis pAxis, const G4VoxelLimits &pVoxelLimit, const G4AffineTransform &pTransform, G4double &pMin, G4double &pMax) const
G4double GetAlpha() const
virtual G4double DistanceToOut(const G4ThreeVector &p, const G4ThreeVector &v, const G4bool calcnorm=false, G4bool *validnorm=nullptr, G4ThreeVector *n=nullptr) const
virtual EInside Inside(const G4ThreeVector &p) const
virtual std::ostream & StreamInfo(std::ostream &os) const
virtual ~G4VTwistedFaceted()
virtual void ComputeDimensions(G4VPVParameterisation *, const G4int, const G4VPhysicalVolume *)
virtual G4VisExtent GetExtent() const
virtual G4Polyhedron * CreatePolyhedron() const
virtual void DescribeYourselfTo(G4VGraphicsScene &scene) const
G4double GetValueB(G4double phi) const
G4double Xcoef(G4double u, G4double phi, G4double ftg) const
virtual G4double GetSurfaceArea()
yystype & operator=(const yystype &right)