Open CASCADE Technology Reference Manual 8.0.0
Loading...
Searching...
No Matches
Public Member Functions
BRepAdaptor_Surface Class Reference

The Surface from BRepAdaptor allows to use a Face of the BRep topology look like a 3D surface. More...

#include <BRepAdaptor_Surface.hxx>

Inheritance diagram for BRepAdaptor_Surface:
Inheritance graph
[legend]

Public Member Functions

 BRepAdaptor_Surface ()
 Creates an undefined surface with no face loaded.
 
 BRepAdaptor_Surface (const TopoDS_Face &F, const bool R=true)
 Creates a surface to access the geometry of <F>. If <Restriction> is true the parameter range is the parameter range in the UV space of the restriction.
 
occ::handle< Adaptor3d_SurfaceShallowCopy () const override
 Shallow copy of adaptor.
 
void Initialize (const TopoDS_Face &F, const bool Restriction=true)
 Sets the surface to the geometry of <F>.
 
const TopoDS_FaceFace () const
 Returns the face.
 
double Tolerance () const
 Returns the face tolerance.
 
- Public Member Functions inherited from GeomAdaptor_TransformedSurface
 GeomAdaptor_TransformedSurface ()
 Creates an undefined surface with identity transformation.
 
 GeomAdaptor_TransformedSurface (const occ::handle< Geom_Surface > &theSurface, const gp_Trsf &theTrsf)
 Creates a surface adaptor with transformation.
 
 GeomAdaptor_TransformedSurface (const occ::handle< Geom_Surface > &theSurface, const double theUFirst, const double theULast, const double theVFirst, const double theVLast, const gp_Trsf &theTrsf, const double theTolU=0.0, const double theTolV=0.0)
 Creates a surface adaptor with transformation and parameter bounds.
 
occ::handle< Adaptor3d_SurfaceShallowCopy () const override
 Shallow copy of adaptor.
 
void Load (const occ::handle< Geom_Surface > &theSurface, const gp_Trsf &theTrsf)
 Loads the surface geometry.
 
void Load (const occ::handle< Geom_Surface > &theSurface, const double theUFirst, const double theULast, const double theVFirst, const double theVLast, const gp_Trsf &theTrsf, const double theTolU=0.0, const double theTolV=0.0)
 Loads the surface geometry with parameter bounds.
 
void SetTrsf (const gp_Trsf &theTrsf)
 Sets the transformation.
 
bool HasTrsf () const
 Returns true if non-identity transformation is applied.
 
const gp_TrsfTrsf () const
 Returns the transformation.
 
Use AdaptorSurfaceOriginal () instead to get the original surface without transformation") const GeomAdaptor_Surface & Surface() const
 Returns the underlying GeomAdaptor_Surface.
 
const GeomAdaptor_SurfaceAdaptorSurfaceOriginal () const
 Returns the underlying original GeomAdaptor_Surface without transformation applied.
 
const GeomAdaptor_SurfaceAdaptorSurfaceTransformed () const
 Returns an adaptor for the transformed surface state. Uses the original adaptor for identity transformation to preserve existing trimming.
 
const occ::handle< Geom_Surface > & GeomSurfaceOriginal () const
 Returns the underlying original Geom_Surface without transformation applied.
 
const occ::handle< Geom_Surface > & GeomSurfaceTransformed () const
 Returns the transformed Geom_Surface cached for current state.
 
const occ::handle< Geom_Surface > & GeomSurface () const
 Returns the underlying Geom_Surface.
 
double FirstUParameter () const override
 
double LastUParameter () const override
 
double FirstVParameter () const override
 
double LastVParameter () const override
 
GeomAbs_Shape UContinuity () const override
 
GeomAbs_Shape VContinuity () const override
 
int NbUIntervals (const GeomAbs_Shape theS) const override
 Returns the number of U intervals for continuity . May be one if UContinuity(me) >=
 
int NbVIntervals (const GeomAbs_Shape theS) const override
 Returns the number of V intervals for continuity . May be one if VContinuity(me) >=
 
void UIntervals (NCollection_Array1< double > &theT, const GeomAbs_Shape theS) const override
 Returns the intervals with the requested continuity in the U direction.
 
void VIntervals (NCollection_Array1< double > &theT, const GeomAbs_Shape theS) const override
 Returns the intervals with the requested continuity in the V direction.
 
occ::handle< Adaptor3d_SurfaceUTrim (const double theFirst, const double theLast, const double theTol) const override
 Returns a surface trimmed in the U direction equivalent of <me> between parameters <First> and <Last>. <Tol> is used to test for 3d points confusion. If <First> >= <Last>
 
occ::handle< Adaptor3d_SurfaceVTrim (const double theFirst, const double theLast, const double theTol) const override
 Returns a surface trimmed in the V direction between parameters <First> and <Last>. <Tol> is used to test for 3d points confusion. If <First> >= <Last>
 
bool IsUClosed () const override
 
bool IsVClosed () const override
 
bool IsUPeriodic () const override
 
double UPeriod () const override
 
bool IsVPeriodic () const override
 
double VPeriod () const override
 
double ToleranceU () const
 Returns tolerance in U direction.
 
double ToleranceV () const
 Returns tolerance in V direction.
 
gp_Pnt EvalD0 (const double theU, const double theV) const final
 Point evaluation. Applies transformation after evaluation.
 
Geom_Surface::ResD1 EvalD1 (const double theU, const double theV) const final
 D1 evaluation. Applies transformation after evaluation.
 
Geom_Surface::ResD2 EvalD2 (const double theU, const double theV) const final
 D2 evaluation. Applies transformation after evaluation.
 
Geom_Surface::ResD3 EvalD3 (const double theU, const double theV) const final
 D3 evaluation. Applies transformation after evaluation.
 
gp_Vec EvalDN (const double theU, const double theV, const int theNu, const int theNv) const final
 DN evaluation. Applies transformation after evaluation.
 
double UResolution (const double theR3d) const override
 Returns the parametric U resolution corresponding to the real space resolution <R3d>.
 
double VResolution (const double theR3d) const override
 Returns the parametric V resolution corresponding to the real space resolution <R3d>.
 
GeomAbs_SurfaceType GetType () const override
 Returns the type of the surface: Plane, Cylinder, Cone, Sphere, Torus, BezierSurface, BSplineSurface, SurfaceOfRevolution, SurfaceOfExtrusion, OtherSurface.
 
gp_Pln Plane () const override
 
gp_Cylinder Cylinder () const override
 
gp_Cone Cone () const override
 
gp_Sphere Sphere () const override
 
gp_Torus Torus () const override
 
int UDegree () const override
 
int NbUPoles () const override
 
int VDegree () const override
 
int NbVPoles () const override
 
int NbUKnots () const override
 
int NbVKnots () const override
 
bool IsURational () const override
 
bool IsVRational () const override
 
occ::handle< Geom_BezierSurfaceBezier () const override
 
occ::handle< Geom_BSplineSurfaceBSpline () const override
 
gp_Ax1 AxeOfRevolution () const override
 
gp_Dir Direction () const override
 
occ::handle< Adaptor3d_CurveBasisCurve () const override
 
occ::handle< Adaptor3d_SurfaceBasisSurface () const override
 
double OffsetValue () const override
 
- Public Member Functions inherited from Adaptor3d_Surface
gp_Pnt Value (const double theU, const double theV) const
 Computes the point of parameters U,V on the surface. Tip: use GeomLib::NormEstim() to calculate surface normal at specified (U, V) point.
 
void D0 (const double theU, const double theV, gp_Pnt &theP) const
 Computes the point of parameters U,V on the surface.
 
void D1 (const double theU, const double theV, gp_Pnt &theP, gp_Vec &theD1U, gp_Vec &theD1V) const
 Computes the point and the first derivatives on the surface. Raised if the continuity of the current intervals is not C1.
 
void D2 (const double theU, const double theV, gp_Pnt &theP, gp_Vec &theD1U, gp_Vec &theD1V, gp_Vec &theD2U, gp_Vec &theD2V, gp_Vec &theD2UV) const
 Computes the point, the first and second derivatives on the surface. Raised if the continuity of the current intervals is not C2.
 
void D3 (const double theU, const double theV, gp_Pnt &theP, gp_Vec &theD1U, gp_Vec &theD1V, gp_Vec &theD2U, gp_Vec &theD2V, gp_Vec &theD2UV, gp_Vec &theD3U, gp_Vec &theD3V, gp_Vec &theD3UUV, gp_Vec &theD3UVV) const
 Computes the point, the first, second and third derivatives on the surface. Raised if the continuity of the current intervals is not C3.
 
gp_Vec DN (const double theU, const double theV, const int theNu, const int theNv) const
 Computes the derivative of order Nu in the direction U and Nv in the direction V at the point P(U, V). Raised if the current U interval is not not CNu and the current V interval is not CNv. Raised if Nu + Nv < 1 or Nu < 0 or Nv < 0.
 
 ~Adaptor3d_Surface () override
 
- Public Member Functions inherited from Standard_Transient
 Standard_Transient ()
 Empty constructor.
 
 Standard_Transient (const Standard_Transient &)
 Copy constructor – does nothing.
 
Standard_Transientoperator= (const Standard_Transient &)
 Assignment operator, needed to avoid copying reference counter.
 
virtual ~Standard_Transient ()=default
 Destructor must be virtual.
 
virtual const opencascade::handle< Standard_Type > & DynamicType () const
 Returns a type descriptor about this object.
 
bool IsInstance (const opencascade::handle< Standard_Type > &theType) const
 Returns a true value if this is an instance of Type.
 
bool IsInstance (const char *const theTypeName) const
 Returns a true value if this is an instance of TypeName.
 
bool IsKind (const opencascade::handle< Standard_Type > &theType) const
 Returns true if this is an instance of Type or an instance of any class that inherits from Type. Note that multiple inheritance is not supported by OCCT RTTI mechanism.
 
bool IsKind (const char *const theTypeName) const
 Returns true if this is an instance of TypeName or an instance of any class that inherits from TypeName. Note that multiple inheritance is not supported by OCCT RTTI mechanism.
 
Standard_TransientThis () const
 Returns non-const pointer to this object (like const_cast). For protection against creating handle to objects allocated in stack or call from constructor, it will raise exception Standard_ProgramError if reference counter is zero.
 
int GetRefCount () const noexcept
 Get the reference counter of this object.
 
void IncrementRefCounter () noexcept
 Increments the reference counter of this object. Uses relaxed memory ordering since incrementing only requires atomicity, not synchronization with other memory operations.
 
int DecrementRefCounter () noexcept
 Decrements the reference counter of this object; returns the decremented value. Uses release ordering for the decrement to ensure all writes to the object are visible before the count reaches zero. An acquire fence is added only when the count reaches zero, ensuring proper synchronization before deletion. This is more efficient than using acq_rel for every decrement.
 
virtual void Delete () const
 Memory deallocator for transient classes.
 

Additional Inherited Members

- Public Types inherited from Standard_Transient
typedef void base_type
 Returns a type descriptor about this object.
 
- Static Public Member Functions inherited from Standard_Transient
static constexpr const charget_type_name ()
 Returns a type descriptor about this object.
 
static const opencascade::handle< Standard_Type > & get_type_descriptor ()
 Returns type descriptor of Standard_Transient class.
 
- Protected Member Functions inherited from GeomAdaptor_TransformedSurface
void invalidateTransformedCache ()
 Invalidates transformed cache for subsequent lazy rebuild.
 
void ensureTransformedCache () const
 Ensures transformed cache is built on demand. Non-thread-safe: mutable cache is initialized in const context without synchronization.
 
void initTransformedCache () const
 Rebuilds transformed geometry for current surface and transformation. Non-thread-safe: invoked by ensureTransformedCache() for lazy initialization.
 
const GeomAdaptor_SurfacetransformedAdaptor () const
 Returns an adaptor for the transformed surface state. Uses the original adaptor for identity transformation to preserve existing trimming.
 
- Protected Attributes inherited from GeomAdaptor_TransformedSurface
GeomAdaptor_Surface mySurf
 
gp_Trsf myTrsf
 
std::optional< GeomAdaptor_SurfacemyTransformedAdaptor
 

Detailed Description

The Surface from BRepAdaptor allows to use a Face of the BRep topology look like a 3D surface.

It has the methods of the class Surface from Adaptor3d.

It is created or initialized with a Face. It takes into account the local coordinates system.

The u,v parameter range is the minmax value for the restriction, unless the flag restriction is set to false.

Constructor & Destructor Documentation

◆ BRepAdaptor_Surface() [1/2]

BRepAdaptor_Surface::BRepAdaptor_Surface ( )

Creates an undefined surface with no face loaded.

◆ BRepAdaptor_Surface() [2/2]

BRepAdaptor_Surface::BRepAdaptor_Surface ( const TopoDS_Face & F,
const bool R = true )

Creates a surface to access the geometry of <F>. If <Restriction> is true the parameter range is the parameter range in the UV space of the restriction.

Member Function Documentation

◆ Face()

const TopoDS_Face & BRepAdaptor_Surface::Face ( ) const

Returns the face.

◆ Initialize()

void BRepAdaptor_Surface::Initialize ( const TopoDS_Face & F,
const bool Restriction = true )

Sets the surface to the geometry of <F>.

◆ ShallowCopy()

occ::handle< Adaptor3d_Surface > BRepAdaptor_Surface::ShallowCopy ( ) const
overridevirtual

Shallow copy of adaptor.

Reimplemented from Adaptor3d_Surface.

◆ Tolerance()

double BRepAdaptor_Surface::Tolerance ( ) const

Returns the face tolerance.


The documentation for this class was generated from the following file: