File indexing completed on 2025-01-18 10:03:03
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016 #ifndef _Bnd_Sphere_HeaderFile
0017 #define _Bnd_Sphere_HeaderFile
0018
0019 #include <Standard.hxx>
0020 #include <Standard_DefineAlloc.hxx>
0021 #include <Standard_Handle.hxx>
0022
0023 #include <gp_XYZ.hxx>
0024 #include <Standard_Real.hxx>
0025 #include <Standard_Boolean.hxx>
0026
0027
0028
0029
0030 class Bnd_Sphere
0031 {
0032 public:
0033
0034 DEFINE_STANDARD_ALLOC
0035
0036
0037
0038 Standard_EXPORT Bnd_Sphere();
0039
0040
0041 Standard_EXPORT Bnd_Sphere(const gp_XYZ& theCntr, const Standard_Real theRad, const Standard_Integer theU, const Standard_Integer theV);
0042
0043
0044 Standard_Integer U() const;
0045
0046
0047 Standard_Integer V() const;
0048
0049
0050
0051 Standard_Boolean IsValid() const;
0052
0053 void SetValid (const Standard_Boolean isValid);
0054
0055
0056 const gp_XYZ& Center() const;
0057
0058
0059 Standard_Real Radius() const;
0060
0061
0062
0063
0064 Standard_EXPORT void Distances (const gp_XYZ& theXYZ, Standard_Real& theMin, Standard_Real& theMax) const;
0065
0066
0067
0068
0069 Standard_EXPORT void SquareDistances (const gp_XYZ& theXYZ, Standard_Real& theMin, Standard_Real& theMax) const;
0070
0071
0072
0073 Standard_EXPORT Standard_Boolean Project (const gp_XYZ& theNode, gp_XYZ& theProjNode, Standard_Real& theDist, Standard_Boolean& theInside) const;
0074
0075 Standard_EXPORT Standard_Real Distance (const gp_XYZ& theNode) const;
0076
0077 Standard_EXPORT Standard_Real SquareDistance (const gp_XYZ& theNode) const;
0078
0079 Standard_EXPORT void Add (const Bnd_Sphere& theOther);
0080
0081 Standard_EXPORT Standard_Boolean IsOut (const Bnd_Sphere& theOther) const;
0082
0083 Standard_EXPORT Standard_Boolean IsOut (const gp_XYZ& thePnt, Standard_Real& theMaxDist) const;
0084
0085 Standard_EXPORT Standard_Real SquareExtent() const;
0086
0087
0088
0089
0090 protected:
0091
0092
0093
0094
0095
0096 private:
0097
0098
0099
0100 gp_XYZ myCenter;
0101 Standard_Real myRadius;
0102 Standard_Boolean myIsValid;
0103 Standard_Integer myU;
0104 Standard_Integer myV;
0105
0106
0107 };
0108
0109
0110 #include <Bnd_Sphere.lxx>
0111
0112
0113
0114
0115
0116 #endif