73 #ifndef UTessellatedSolid_hh
74 #define UTessellatedSolid_hh 1
139 virtual std::ostream&
StreamInfo(std::ostream& os)
const;
218 const std::vector<int>&
max,
219 bool status,
UBits& checked);
225 const std::pair<int, double>& r);
virtual double SurfaceArea()
double GetMaxZExtent() const
virtual UGeometryType GetEntityType() const
double GetMinYExtent() const
static const double dirTolerance
virtual UVector3 GetPointOnSurface() const
UTessellatedSolid & operator=(const UTessellatedSolid &s)
virtual ~UTessellatedSolid()
double GetMinXExtent() const
virtual bool Normal(const UVector3 &p, UVector3 &aNormal) const
virtual std::ostream & StreamInfo(std::ostream &os) const
std::vector< UVector3 > fRandir
double GetMaxYExtent() const
bool OutsideOfExtent(const UVector3 &p, double tolerance=0) const
std::set< VUFacet * > fExtremeFacets
void PrecalculateInsides()
double MinDistanceFacet(const UVector3 &p, bool simple, VUFacet *&facet) const
virtual double SafetyFromOutside(const UVector3 &p, bool aAccurate=false) const
void SetMaxVoxels(int max)
bool AddFacet(VUFacet *aFacet)
virtual VUSolid * Clone() const
static const G4double tolerance
bool operator()(const UVertexInfo &l, const UVertexInfo &r) const
int GetNumberOfFacets() const
void DistanceToOutCandidates(const std::vector< int > &candidates, const UVector3 &aPoint, const UVector3 &direction, double &minDist, UVector3 &minNormal, int &minCandidate) const
virtual double DistanceToIn(const UVector3 &p, const UVector3 &v, double aPstep=UUtils::kInfinity) const
double GetMaxXExtent() const
std::vector< VUFacet * > fFacets
static const double kInfinity
static bool CompareSortedVoxel(const std::pair< int, double > &l, const std::pair< int, double > &r)
VUSolid::EnumInside InsideNoVoxels(const UVector3 &p) const
double DistanceToOutNoVoxels(const UVector3 &p, const UVector3 &v, UVector3 &aNormalVector, bool &aConvex, double aPstep=UUtils::kInfinity) const
double DistanceToInNoVoxels(const UVector3 &p, const UVector3 &v, double aPstep=UUtils::kInfinity) const
virtual void GetParametersList(int, double *) const
int AllocatedMemoryWithoutVoxels()
void Initialize()
TODO: make a benchmark for automatic selection of number of voxels. random voxels will be selected...
double DistanceToInCandidates(const std::vector< int > &candidates, const UVector3 &aPoint, const UVector3 &aDirection) const
double DistanceToInCore(const UVector3 &p, const UVector3 &v, double aPstep=UUtils::kInfinity) const
virtual VUSolid::EnumInside Inside(const UVector3 &p) const
virtual double Capacity()
void Extent(UVector3 &aMin, UVector3 &aMax) const
virtual void ComputeBBox(UBBox *, bool)
UGeometryType fGeometryType
double GetMinZExtent() const
void DisplayAllocatedMemory()
std::vector< UVector3 > fVertexList
virtual double SafetyFromInside(const UVector3 &p, bool aAccurate=false) const
void SetMaxVoxels(int max)
T max(const T t1, const T t2)
brief Return the largest of the two arguments
VUSolid::EnumInside InsideVoxels(const UVector3 &aPoint) const
std::set< UVertexInfo, UVertexComparator > fFacetList
double DistanceToOutCore(const UVector3 &p, const UVector3 &v, UVector3 &aNormalVector, bool &aConvex, double aPstep=UUtils::kInfinity) const
bool GetSolidClosed() const
void CopyObjects(const UTessellatedSolid &s)
std::string UGeometryType
void SetSolidClosed(const bool t)
UTessellatedSolid & operator+=(const UTessellatedSolid &right)
virtual double GetSurfaceArea()
virtual double DistanceToOut(const UVector3 &p, const UVector3 &v, UVector3 &aNormalVector, bool &aConvex, double aPstep=UUtils::kInfinity) const
VUFacet * GetFacet(int i) const
int SetAllUsingStack(const std::vector< int > &voxel, const std::vector< int > &max, bool status, UBits &checked)