Open CASCADE Technology  6.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Static Public Member Functions
Geom_BezierSurface Class Reference

Describes a rational or non-rational Bezier surface.
More...

#include <Geom_BezierSurface.hxx>

Inheritance diagram for Geom_BezierSurface:
Inheritance graph
[legend]

Public Member Functions

 Geom_BezierSurface (const TColgp_Array2OfPnt &SurfacePoles)
 Creates a non-rational Bezier surface with a set of poles.
Control points representation :
SPoles(Uorigin,Vorigin) ...................SPoles(Uorigin,Vend)
. .
. .
SPoles(Uend, Vorigin) .....................SPoles(Uend, Vend)
For the double array the row indice corresponds to the parametric
U direction and the columns indice corresponds to the parametric
V direction.
The weights are defaulted to all being 1.
Raised if the number of poles of the surface is lower than 2
or greater than MaxDegree + 1 in one of the two directions
U or V.
More...
 
 Geom_BezierSurface (const TColgp_Array2OfPnt &SurfacePoles, const TColStd_Array2OfReal &PoleWeights)
 —Purpose
Creates a rational Bezier surface with a set of poles and a
set of weights.
For the double array the row indice corresponds to the parametric
U direction and the columns indice corresponds to the parametric
V direction.
If all the weights are identical the surface is considered as
non-rational (the tolerance criterion is Resolution from package
gp).
Raised if SurfacePoles and PoleWeights have not the same
Rowlength or have not the same ColLength.
Raised if PoleWeights (i, j) <= Resolution from gp;
Raised if the number of poles of the surface is lower than 2
or greater than MaxDegree + 1 in one of the two directions U or V.
More...
 
void ExchangeUV ()
 
 Exchanges the direction U and V on a Bezier surface <br>

As a consequence:
More...

 
void Increase (const Standard_Integer UDeg, const Standard_Integer VDeg)
 
Increases the degree of this Bezier surface in the two parametric directions. <br>

Raised if UDegree < UDegree <me> or VDegree < VDegree <me>
Raised if the degree of the surface is greater than MaxDegree
in one of the two directions U or V.
More...

 
void InsertPoleColAfter (const Standard_Integer VIndex, const TColgp_Array1OfPnt &CPoles)
 Inserts a column of poles. If the surface is rational the weights
values associated with CPoles are equal defaulted to 1.
Raised if Vindex < 1 or VIndex > NbVPoles.
raises if VDegree is greater than MaxDegree.
raises if the Length of CPoles is not equal to NbUPoles
More...
 
void InsertPoleColAfter (const Standard_Integer VIndex, const TColgp_Array1OfPnt &CPoles, const TColStd_Array1OfReal &CPoleWeights)
 Inserts a column of poles and weights.
If the surface was non-rational it can become rational.
Raised if Vindex < 1 or VIndex > NbVPoles.
//! Raised if
. VDegree is greater than MaxDegree.
. the Length of CPoles is not equal to NbUPoles
. a weight value is lower or equal to Resolution from
package gp
More...
 
void InsertPoleColBefore (const Standard_Integer VIndex, const TColgp_Array1OfPnt &CPoles)
 Inserts a column of poles. If the surface is rational the weights
values associated with CPoles are equal defaulted to 1.
Raised if Vindex < 1 or VIndex > NbVPoles.
Raised if VDegree is greater than MaxDegree.
Raised if the Length of CPoles is not equal to NbUPoles
More...
 
void InsertPoleColBefore (const Standard_Integer VIndex, const TColgp_Array1OfPnt &CPoles, const TColStd_Array1OfReal &CPoleWeights)
 Inserts a column of poles and weights.
If the surface was non-rational it can become rational.
Raised if Vindex < 1 or VIndex > NbVPoles.
//! Raised if :
. VDegree is greater than MaxDegree.
. the Length of CPoles is not equal to NbUPoles
. a weight value is lower or equal to Resolution from
package gp
More...
 
void InsertPoleRowAfter (const Standard_Integer UIndex, const TColgp_Array1OfPnt &CPoles)
 Inserts a row of poles. If the surface is rational the weights
values associated with CPoles are equal defaulted to 1.
Raised if Uindex < 1 or UIndex > NbUPoles.
Raised if UDegree is greater than MaxDegree.
Raised if the Length of CPoles is not equal to NbVPoles
More...
 
void InsertPoleRowAfter (const Standard_Integer UIndex, const TColgp_Array1OfPnt &CPoles, const TColStd_Array1OfReal &CPoleWeights)
 Inserts a row of poles and weights.
If the surface was non-rational it can become rational.
Raised if Uindex < 1 or UIndex > NbUPoles.
//! Raised if :
. UDegree is greater than MaxDegree.
. the Length of CPoles is not equal to NbVPoles
. a weight value is lower or equal to Resolution from
package gp
More...
 
void InsertPoleRowBefore (const Standard_Integer UIndex, const TColgp_Array1OfPnt &CPoles)
 Inserts a row of poles. If the surface is rational the weights
values associated with CPoles are equal defaulted to 1.
Raised if Uindex < 1 or UIndex > NbUPoles.
Raised if UDegree is greater than MaxDegree.
Raised if the Length of CPoles is not equal to NbVPoles
More...
 
void InsertPoleRowBefore (const Standard_Integer UIndex, const TColgp_Array1OfPnt &CPoles, const TColStd_Array1OfReal &CPoleWeights)
 Inserts a row of poles and weights.
If the surface was non-rational it can become rational.
Raised if Uindex < 1 or UIndex > NbUPoles.
//! Raised if :
. UDegree is greater than MaxDegree.
. the Length of CPoles is not equal to NbVPoles
. a weight value is lower or equal to Resolution from
pacakage gp
More...
 
void RemovePoleCol (const Standard_Integer VIndex)
 
Removes a column of poles. <br>

If the surface was rational it can become non-rational.
Raised if NbVPoles <= 2 after removing, a Bezier surface
must have at least two columns of poles.
//! Raised if Vindex < 1 or VIndex > NbVPoles
More...

 
void RemovePoleRow (const Standard_Integer UIndex)
 
Removes a row of poles. <br>

If the surface was rational it can become non-rational.
Raised if NbUPoles <= 2 after removing, a Bezier surface
must have at least two rows of poles.
//! Raised if Uindex < 1 or UIndex > NbUPoles
More...

 
void Segment (const Standard_Real U1, const Standard_Real U2, const Standard_Real V1, const Standard_Real V2)
 
 Modifies this Bezier surface by segmenting it <br>

between U1 and U2 in the u parametric direction,
and between V1 and V2 in the v parametric
direction. U1, U2, V1, and V2 can be outside the
bounds of this surface.
More...

 
void SetPole (const Standard_Integer UIndex, const Standard_Integer VIndex, const gp_Pnt &P)
 
Modifies a pole value. <br>

If the surface is rational the weight of range (UIndex, VIndex)
is not modified.
Raised if UIndex < 1 or UIndex > NbUPoles or VIndex < 1
or VIndex > NbVPoles.
More...

 
void SetPole (const Standard_Integer UIndex, const Standard_Integer VIndex, const gp_Pnt &P, const Standard_Real Weight)
 Substitutes the pole and the weight of range UIndex, VIndex.
If the surface <me> is not rational it can become rational.
if the surface was rational it can become non-rational.
raises if UIndex < 1 or UIndex > NbUPoles or VIndex < 1
or VIndex > NbVPoles.
//! Raised if Weight <= Resolution from package gp.
More...
 
void SetPoleCol (const Standard_Integer VIndex, const TColgp_Array1OfPnt &CPoles)
 
 Modifies a column of poles. <br>

The length of CPoles can be lower but not greater than NbUPoles
so you can modify just a part of the column.
//! Raised if VIndex < 1 or VIndex > NbVPoles
Raised if CPoles.Lower() < 1 or CPoles.Upper() > NbUPoles
More...

 
void SetPoleCol (const Standard_Integer VIndex, const TColgp_Array1OfPnt &CPoles, const TColStd_Array1OfReal &CPoleWeights)
 
 Modifies a column of poles. <br>

If the surface was rational it can become non-rational
If the surface was non-rational it can become rational.
The length of CPoles can be lower but not greater than NbUPoles
so you can modify just a part of the column.
//! Raised if VIndex < 1 or VIndex > NbVPoles
Raised if CPoles.Lower() < 1 or CPoles.Upper() > NbUPoles
Raised if CPoleWeights and CPoles have not the same bounds.
Raised if one of the weight value CPoleWeights (i) is lower
or equal to Resolution from package gp.
More...

 
void SetPoleRow (const Standard_Integer UIndex, const TColgp_Array1OfPnt &CPoles)
 
 Modifies a row of poles. <br>

The length of CPoles can be lower but not greater than NbVPoles
so you can modify just a part of the row.
//! Raised if UIndex < 1 or UIndex > NbUPoles
Raised if CPoles.Lower() < 1 or CPoles.Upper() > NbVPoles
More...

 
void SetPoleRow (const Standard_Integer UIndex, const TColgp_Array1OfPnt &CPoles, const TColStd_Array1OfReal &CPoleWeights)
 
 Modifies a row of poles and weights. <br>

If the surface was rational it can become non-rational.
If the surface was non-rational it can become rational.
The length of CPoles can be lower but not greater than NbVPoles
so you can modify just a part of the row.
//! Raised if UIndex < 1 or UIndex > NbUPoles
Raised if CPoles.Lower() < 1 or CPoles.Upper() > NbVPoles
Raised if CPoleWeights and CPoles have not the same bounds.
Raised if one of the weight value CPoleWeights (i) is lower
or equal to Resolution from gp.
More...

 
void SetWeight (const Standard_Integer UIndex, const Standard_Integer VIndex, const Standard_Real Weight)
 Modifies the weight of the pole of range UIndex, VIndex.
If the surface was non-rational it can become rational.
If the surface was rational it can become non-rational.
Raised if UIndex < 1 or UIndex > NbUPoles or VIndex < 1 or
VIndex > NbVPoles.
//! Raised if Weight <= Resolution from package gp.
More...
 
void SetWeightCol (const Standard_Integer VIndex, const TColStd_Array1OfReal &CPoleWeights)
 
 Modifies a column of weights. <br>

If the surface was rational it can become non-rational.
If the surface was non-rational it can become rational.
The length of CPoleWeights can be lower but not greater than
NbUPoles.
//! Raised if VIndex < 1 or VIndex > NbVPoles
Raised if CPoleWeights.Lower() < 1 or CPoleWeights.Upper() >
NbUPoles
Raised if one of the weight value CPoleWeights (i) is lower
or equal to Resolution from package gp.
More...

 
void SetWeightRow (const Standard_Integer UIndex, const TColStd_Array1OfReal &CPoleWeights)
 
 Modifies a row of weights. <br>

If the surface was rational it can become non-rational.
If the surface was non-rational it can become rational.
The length of CPoleWeights can be lower but not greater than
NbVPoles.
//! Raised if UIndex < 1 or UIndex > NbUPoles
Raised if CPoleWeights.Lower() < 1 or CPoleWeights.Upper() >
NbVPoles
Raised if one of the weight value CPoleWeights (i) is lower
or equal to Resolution from package gp.
More...

 
void UReverse ()
 
 Changes the orientation of this Bezier surface in the <br>

u parametric direction. The bounds of the
surface are not changed, but the given parametric
direction is reversed. Hence, the orientation of the surface is reversed.
More...

 
Standard_Real UReversedParameter (const Standard_Real U) const
 
 Computes the u (or v) parameter on the modified <br>

surface, produced by reversing its u (or v) parametric
direction, for any point of u parameter U (or of v
parameter V) on this Bezier surface.
In the case of a Bezier surface, these functions return respectively:
More...

 
void VReverse ()
 
 Changes the orientation of this Bezier surface in the <br>

v parametric direction. The bounds of the
surface are not changed, but the given parametric
direction is reversed. Hence, the orientation of the
surface is reversed.
More...

 
Standard_Real VReversedParameter (const Standard_Real V) const
 
 Computes the u (or v) parameter on the modified <br>

surface, produced by reversing its u (or v) parametric
direction, for any point of u parameter U (or of v
parameter V) on this Bezier surface.
In the case of a Bezier surface, these functions return respectively:
More...

 
void Bounds (Standard_Real &U1, Standard_Real &U2, Standard_Real &V1, Standard_Real &V2) const
 
 Returns the parametric bounds U1, U2, V1 and V2 of <br>

this Bezier surface.
In the case of a Bezier surface, this function returns
U1 = 0, V1 = 0, U2 = 1, V2 = 1.
More...

 
GeomAbs_Shape Continuity () const
 Returns the continuity of the surface CN : the order of
continuity is infinite.
More...
 
void D0 (const Standard_Real U, const Standard_Real V, gp_Pnt &P) const
 
Computes the point of parameter U,V on the surface. <br>

Raised only for an "OffsetSurface" if it is not possible to
compute the current point.
More...

 
void D1 (const Standard_Real U, const Standard_Real V, gp_Pnt &P, gp_Vec &D1U, gp_Vec &D1V) const
 Computes the point P and the first derivatives in the
directions U and V at this point.
//! Raised if the continuity of the surface is not C1.
More...
 
void D2 (const Standard_Real U, const Standard_Real V, gp_Pnt &P, gp_Vec &D1U, gp_Vec &D1V, gp_Vec &D2U, gp_Vec &D2V, gp_Vec &D2UV) const
 Computes the point P, the first and the second derivatives in
the directions U and V at this point.
//! Raised if the continuity of the surface is not C2.
More...
 
void D3 (const Standard_Real U, const Standard_Real V, gp_Pnt &P, gp_Vec &D1U, gp_Vec &D1V, gp_Vec &D2U, gp_Vec &D2V, gp_Vec &D2UV, gp_Vec &D3U, gp_Vec &D3V, gp_Vec &D3UUV, gp_Vec &D3UVV) const
 Computes P, the point of parameters (U, V) of this Bezier surface, and
More...
 
gp_Vec DN (const Standard_Real U, const Standard_Real V, const Standard_Integer Nu, const Standard_Integer Nv) const
 
 Computes the derivative of order Nu in the u <br>

parametric direction, and Nv in the v parametric
direction, at the point of parameters (U, V) of this Bezier surface.
Note: The parameters U and V can be outside the bounds of the surface.
Exceptions
Standard_RangeError if:
More...

 
Standard_Integer NbUPoles () const
 Returns the number of poles in the U direction.
More...
 
Standard_Integer NbVPoles () const
 Returns the number of poles in the V direction.
More...
 
gp_Pnt Pole (const Standard_Integer UIndex, const Standard_Integer VIndex) const
 
Returns the pole of range UIndex, VIndex <br>//! Raised if UIndex < 1 or UIndex > NbUPoles, or <br>

VIndex < 1 or VIndex > NbVPoles.
More...

 
void Poles (TColgp_Array2OfPnt &P) const
 
Returns the poles of the Bezier surface. <br>

Raised if the length of P in the U an V direction is not equal to
NbUPoles and NbVPoles.
More...

 
Standard_Integer UDegree () const
 Returns the degree of the surface in the U direction it is
NbUPoles - 1
More...
 
Handle_Geom_Curve UIso (const Standard_Real U) const
 Computes the U isoparametric curve. For a Bezier surface the
UIso curve is a Bezier curve.
More...
 
Standard_Integer VDegree () const
 Returns the degree of the surface in the V direction it is
NbVPoles - 1
More...
 
Handle_Geom_Curve VIso (const Standard_Real V) const
 Computes the V isoparametric curve. For a Bezier surface the
VIso curve is a Bezier curve.
More...
 
Standard_Real Weight (const Standard_Integer UIndex, const Standard_Integer VIndex) const
 
Returns the weight of range UIndex, VIndex <br>

Raised if UIndex < 1 or UIndex > NbUPoles, or
VIndex < 1 or VIndex > NbVPoles.
More...

 
void Weights (TColStd_Array2OfReal &W) const
 
Returns the weights of the Bezier surface. <br>

Raised if the length of W in the U an V direction is not
equal to NbUPoles and NbVPoles.
More...

 
Standard_Boolean IsUClosed () const
 Returns True if the first control points row and the
last control points row are identical. The tolerance
criterion is Resolution from package gp.
More...
 
Standard_Boolean IsVClosed () const
 Returns True if the first control points column
and the last control points column are identical.
The tolerance criterion is Resolution from package gp.
More...
 
Standard_Boolean IsCNu (const Standard_Integer N) const
 Returns True, a Bezier surface is always CN
More...
 
Standard_Boolean IsCNv (const Standard_Integer N) const
 Returns True, a BezierSurface is always CN
More...
 
Standard_Boolean IsUPeriodic () const
 Returns False.
More...
 
Standard_Boolean IsVPeriodic () const
 Returns False.
More...
 
Standard_Boolean IsURational () const
 
Returns False if the weights are identical in the U direction, <br>

The tolerance criterion is Resolution from package gp.
Example :
|1.0, 1.0, 1.0|
if Weights = |0.5, 0.5, 0.5| returns False
|2.0, 2.0, 2.0|
More...

 
Standard_Boolean IsVRational () const
 
Returns False if the weights are identical in the V direction, <br>

The tolerance criterion is Resolution from package gp.
Example :
|1.0, 2.0, 0.5|
if Weights = |1.0, 2.0, 0.5| returns False
|1.0, 2.0, 0.5|
More...

 
void Transform (const gp_Trsf &T)
 Applies the transformation T to this Bezier surface.
More...
 
void Resolution (const Standard_Real Tolerance3D, Standard_Real &UTolerance, Standard_Real &VTolerance)
 
 Computes two tolerance values for this Bezier <br>

surface, based on the given tolerance in 3D space
Tolerance3D. The tolerances computed are:
More...

 
Handle_Geom_Geometry Copy () const
 Creates a new object which is a copy of this Bezier surface.
More...
 
- Public Member Functions inherited from Geom_Surface
Handle_Geom_Surface UReversed () const
 Reverses the U direction of parametrization of <me>.
The bounds of the surface are not modified.
A copy of <me> is returned.
More...
 
Handle_Geom_Surface VReversed () const
 Reverses the V direction of parametrization of <me>.
The bounds of the surface are not modified.
A copy of <me> is returned.
More...
 
virtual void TransformParameters (Standard_Real &U, Standard_Real &V, const gp_Trsf &T) const
 
 Computes the  parameters on the  transformed  surface for <br>
     the transform of the point of parameters U,V on <me>. <br>


me->Transformed(T)->Value(U',V')

is the same point as

me->Value(U,V).Transformed(T)

Where U',V' are the new values of U,V after calling

me->TranformParameters(U,V,T)

This methods does not change <U> and <V>

It can be redefined. For example on the Plane,
Cylinder, Cone, Revolved and Extruded surfaces.
More...

 
virtual gp_GTrsf2d ParametricTransformation (const gp_Trsf &T) const
 
 Returns a 2d transformation  used to find the  new <br>
     parameters of a point on the transformed surface. <br>


me->Transformed(T)->Value(U',V')

is the same point as

me->Value(U,V).Transformed(T)

Where U',V' are obtained by transforming U,V with
th 2d transformation returned by

me->ParametricTransformation(T)

This methods returns an identity transformation

It can be redefined. For example on the Plane,
Cylinder, Cone, Revolved and Extruded surfaces.

More...

 
virtual Standard_Real UPeriod () const
 
 Returns the period of this surface in the u <br>

parametric direction.
//! raises if the surface is not uperiodic.
More...

 
virtual Standard_Real VPeriod () const
 Returns the period of this surface in the v parametric direction.
//! raises if the surface is not vperiodic.
More...
 
gp_Pnt Value (const Standard_Real U, const Standard_Real V) const
 
Computes the point of parameter U on the surface. <br>


It is implemented with D0
Raised only for an "OffsetSurface" if it is not possible to
compute the current point.
More...

 
- Public Member Functions inherited from Geom_Geometry
void Mirror (const gp_Pnt &P)
 Performs the symmetrical transformation of a Geometry
with respect to the point P which is the center of the
symmetry.
More...
 
void Mirror (const gp_Ax1 &A1)
 Performs the symmetrical transformation of a Geometry
with respect to an axis placement which is the axis of the
symmetry.
More...
 
void Mirror (const gp_Ax2 &A2)
 Performs the symmetrical transformation of a Geometry
with respect to a plane. The axis placement A2 locates
the plane of the symmetry : (Location, XDirection, YDirection).
More...
 
void Rotate (const gp_Ax1 &A1, const Standard_Real Ang)
 Rotates a Geometry. A1 is the axis of the rotation.
Ang is the angular value of the rotation in radians.
More...
 
void Scale (const gp_Pnt &P, const Standard_Real S)
 Scales a Geometry. S is the scaling value.
More...
 
void Translate (const gp_Vec &V)
 Translates a Geometry. V is the vector of the tanslation.
More...
 
void Translate (const gp_Pnt &P1, const gp_Pnt &P2)
 Translates a Geometry from the point P1 to the point P2.
More...
 
Handle_Geom_Geometry Mirrored (const gp_Pnt &P) const
 
Handle_Geom_Geometry Mirrored (const gp_Ax1 &A1) const
 
Handle_Geom_Geometry Mirrored (const gp_Ax2 &A2) const
 
Handle_Geom_Geometry Rotated (const gp_Ax1 &A1, const Standard_Real Ang) const
 
Handle_Geom_Geometry Scaled (const gp_Pnt &P, const Standard_Real S) const
 
Handle_Geom_Geometry Transformed (const gp_Trsf &T) const
 
Handle_Geom_Geometry Translated (const gp_Vec &V) const
 
Handle_Geom_Geometry Translated (const gp_Pnt &P1, const gp_Pnt &P2) const
 
- Public Member Functions inherited from MMgt_TShared
virtual void Delete () const
 Memory deallocator for transient classes. More...
 
- Public Member Functions inherited from Standard_Transient
 Standard_Transient ()
 Empty constructor. More...
 
 Standard_Transient (const Standard_Transient &)
 Copy constructor – does nothing. More...
 
Standard_Transientoperator= (const Standard_Transient &)
 Assignment operator, needed to avoid copying reference counter. More...
 
virtual ~Standard_Transient ()
 Destructor must be virtual. More...
 
virtual void ShallowDump (Standard_OStream &) const
 
virtual const
Handle_Standard_Type & 
DynamicType () const
 Returns a type information object about this object. More...
 
Standard_Boolean IsInstance (const Handle_Standard_Type &theType) const
 Returns a true value if this is an instance of Type. More...
 
Standard_Boolean IsInstance (const Standard_CString theTypeName) const
 Returns a true value if this is an instance of TypeName. More...
 
Standard_Boolean IsKind (const 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. More...
 
Standard_Boolean IsKind (const Standard_CString 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. More...
 
virtual Handle_Standard_Transient This () const
 Returns a Handle which references this object. Must never be called to objects created in stack. More...
 
Standard_Integer GetRefCount () const
 Get the reference counter of this object. More...
 

Static Public Member Functions

static Standard_Integer MaxDegree ()
 Returns the value of the maximum polynomial degree of a
Bezier surface. This value is 25.
More...
 

Detailed Description

Describes a rational or non-rational Bezier surface.

Constructor & Destructor Documentation

Geom_BezierSurface::Geom_BezierSurface ( const TColgp_Array2OfPnt SurfacePoles)

Creates a non-rational Bezier surface with a set of poles.
Control points representation :
SPoles(Uorigin,Vorigin) ...................SPoles(Uorigin,Vend)
. .
. .
SPoles(Uend, Vorigin) .....................SPoles(Uend, Vend)
For the double array the row indice corresponds to the parametric
U direction and the columns indice corresponds to the parametric
V direction.
The weights are defaulted to all being 1.
Raised if the number of poles of the surface is lower than 2
or greater than MaxDegree + 1 in one of the two directions
U or V.

Geom_BezierSurface::Geom_BezierSurface ( const TColgp_Array2OfPnt SurfacePoles,
const TColStd_Array2OfReal PoleWeights 
)

—Purpose
Creates a rational Bezier surface with a set of poles and a
set of weights.
For the double array the row indice corresponds to the parametric
U direction and the columns indice corresponds to the parametric
V direction.
If all the weights are identical the surface is considered as
non-rational (the tolerance criterion is Resolution from package
gp).
Raised if SurfacePoles and PoleWeights have not the same
Rowlength or have not the same ColLength.
Raised if PoleWeights (i, j) <= Resolution from gp;
Raised if the number of poles of the surface is lower than 2
or greater than MaxDegree + 1 in one of the two directions U or V.

Member Function Documentation

void Geom_BezierSurface::Bounds ( Standard_Real U1,
Standard_Real U2,
Standard_Real V1,
Standard_Real V2 
) const
virtual

 Returns the parametric bounds U1, U2, V1 and V2 of <br>

this Bezier surface.
In the case of a Bezier surface, this function returns
U1 = 0, V1 = 0, U2 = 1, V2 = 1.

Implements Geom_Surface.

GeomAbs_Shape Geom_BezierSurface::Continuity ( ) const
virtual

Returns the continuity of the surface CN : the order of
continuity is infinite.

Implements Geom_Surface.

Handle_Geom_Geometry Geom_BezierSurface::Copy ( ) const
virtual

Creates a new object which is a copy of this Bezier surface.

Implements Geom_Geometry.

void Geom_BezierSurface::D0 ( const Standard_Real  U,
const Standard_Real  V,
gp_Pnt P 
) const
virtual

Computes the point of parameter U,V on the surface. <br>

Raised only for an "OffsetSurface" if it is not possible to
compute the current point.

Implements Geom_Surface.

void Geom_BezierSurface::D1 ( const Standard_Real  U,
const Standard_Real  V,
gp_Pnt P,
gp_Vec D1U,
gp_Vec D1V 
) const
virtual

Computes the point P and the first derivatives in the
directions U and V at this point.
//! Raised if the continuity of the surface is not C1.

Implements Geom_Surface.

void Geom_BezierSurface::D2 ( const Standard_Real  U,
const Standard_Real  V,
gp_Pnt P,
gp_Vec D1U,
gp_Vec D1V,
gp_Vec D2U,
gp_Vec D2V,
gp_Vec D2UV 
) const
virtual

Computes the point P, the first and the second derivatives in
the directions U and V at this point.
//! Raised if the continuity of the surface is not C2.

Implements Geom_Surface.

void Geom_BezierSurface::D3 ( const Standard_Real  U,
const Standard_Real  V,
gp_Pnt P,
gp_Vec D1U,
gp_Vec D1V,
gp_Vec D2U,
gp_Vec D2V,
gp_Vec D2UV,
gp_Vec D3U,
gp_Vec D3V,
gp_Vec D3UUV,
gp_Vec D3UVV 
) const
virtual

Computes P, the point of parameters (U, V) of this Bezier surface, and

  • one or more of the following sets of vectors:
  • D1U and D1V, the first derivative vectors at this point,
    • D2U, D2V and D2UV, the second derivative
      vectors at this point,
    • D3U, D3V, D3UUV and D3UVV, the third
      derivative vectors at this point.
      Note: The parameters U and V can be outside the bounds of the surface.

Implements Geom_Surface.

gp_Vec Geom_BezierSurface::DN ( const Standard_Real  U,
const Standard_Real  V,
const Standard_Integer  Nu,
const Standard_Integer  Nv 
) const
virtual

 Computes the derivative of order Nu in the u <br>

parametric direction, and Nv in the v parametric
direction, at the point of parameters (U, V) of this Bezier surface.
Note: The parameters U and V can be outside the bounds of the surface.
Exceptions
Standard_RangeError if:

  • Nu + Nv is less than 1, or Nu or Nv is negative.

Implements Geom_Surface.

void Geom_BezierSurface::ExchangeUV ( )

 Exchanges the direction U and V on a Bezier surface <br>

As a consequence:

  • the poles and weights tables are transposed,
  • degrees, rational characteristics and so on are
    exchanged between the two parametric directions, and
  • the orientation of the surface is reversed.
void Geom_BezierSurface::Increase ( const Standard_Integer  UDeg,
const Standard_Integer  VDeg 
)

Increases the degree of this Bezier surface in the two parametric directions. <br>

Raised if UDegree < UDegree <me> or VDegree < VDegree <me>
Raised if the degree of the surface is greater than MaxDegree
in one of the two directions U or V.

void Geom_BezierSurface::InsertPoleColAfter ( const Standard_Integer  VIndex,
const TColgp_Array1OfPnt CPoles 
)

Inserts a column of poles. If the surface is rational the weights
values associated with CPoles are equal defaulted to 1.
Raised if Vindex < 1 or VIndex > NbVPoles.
raises if VDegree is greater than MaxDegree.
raises if the Length of CPoles is not equal to NbUPoles

void Geom_BezierSurface::InsertPoleColAfter ( const Standard_Integer  VIndex,
const TColgp_Array1OfPnt CPoles,
const TColStd_Array1OfReal CPoleWeights 
)

Inserts a column of poles and weights.
If the surface was non-rational it can become rational.
Raised if Vindex < 1 or VIndex > NbVPoles.
//! Raised if
. VDegree is greater than MaxDegree.
. the Length of CPoles is not equal to NbUPoles
. a weight value is lower or equal to Resolution from
package gp

void Geom_BezierSurface::InsertPoleColBefore ( const Standard_Integer  VIndex,
const TColgp_Array1OfPnt CPoles 
)

Inserts a column of poles. If the surface is rational the weights
values associated with CPoles are equal defaulted to 1.
Raised if Vindex < 1 or VIndex > NbVPoles.
Raised if VDegree is greater than MaxDegree.
Raised if the Length of CPoles is not equal to NbUPoles

void Geom_BezierSurface::InsertPoleColBefore ( const Standard_Integer  VIndex,
const TColgp_Array1OfPnt CPoles,
const TColStd_Array1OfReal CPoleWeights 
)

Inserts a column of poles and weights.
If the surface was non-rational it can become rational.
Raised if Vindex < 1 or VIndex > NbVPoles.
//! Raised if :
. VDegree is greater than MaxDegree.
. the Length of CPoles is not equal to NbUPoles
. a weight value is lower or equal to Resolution from
package gp

void Geom_BezierSurface::InsertPoleRowAfter ( const Standard_Integer  UIndex,
const TColgp_Array1OfPnt CPoles 
)

Inserts a row of poles. If the surface is rational the weights
values associated with CPoles are equal defaulted to 1.
Raised if Uindex < 1 or UIndex > NbUPoles.
Raised if UDegree is greater than MaxDegree.
Raised if the Length of CPoles is not equal to NbVPoles

void Geom_BezierSurface::InsertPoleRowAfter ( const Standard_Integer  UIndex,
const TColgp_Array1OfPnt CPoles,
const TColStd_Array1OfReal CPoleWeights 
)

Inserts a row of poles and weights.
If the surface was non-rational it can become rational.
Raised if Uindex < 1 or UIndex > NbUPoles.
//! Raised if :
. UDegree is greater than MaxDegree.
. the Length of CPoles is not equal to NbVPoles
. a weight value is lower or equal to Resolution from
package gp

void Geom_BezierSurface::InsertPoleRowBefore ( const Standard_Integer  UIndex,
const TColgp_Array1OfPnt CPoles 
)

Inserts a row of poles. If the surface is rational the weights
values associated with CPoles are equal defaulted to 1.
Raised if Uindex < 1 or UIndex > NbUPoles.
Raised if UDegree is greater than MaxDegree.
Raised if the Length of CPoles is not equal to NbVPoles

void Geom_BezierSurface::InsertPoleRowBefore ( const Standard_Integer  UIndex,
const TColgp_Array1OfPnt CPoles,
const TColStd_Array1OfReal CPoleWeights 
)

Inserts a row of poles and weights.
If the surface was non-rational it can become rational.
Raised if Uindex < 1 or UIndex > NbUPoles.
//! Raised if :
. UDegree is greater than MaxDegree.
. the Length of CPoles is not equal to NbVPoles
. a weight value is lower or equal to Resolution from
pacakage gp

Standard_Boolean Geom_BezierSurface::IsCNu ( const Standard_Integer  N) const
virtual

Returns True, a Bezier surface is always CN

Implements Geom_Surface.

Standard_Boolean Geom_BezierSurface::IsCNv ( const Standard_Integer  N) const
virtual

Returns True, a BezierSurface is always CN

Implements Geom_Surface.

Standard_Boolean Geom_BezierSurface::IsUClosed ( ) const
virtual

Returns True if the first control points row and the
last control points row are identical. The tolerance
criterion is Resolution from package gp.

Implements Geom_Surface.

Standard_Boolean Geom_BezierSurface::IsUPeriodic ( ) const
virtual

Returns False.

Implements Geom_Surface.

Standard_Boolean Geom_BezierSurface::IsURational ( ) const

Returns False if the weights are identical in the U direction, <br>

The tolerance criterion is Resolution from package gp.
Example :
|1.0, 1.0, 1.0|
if Weights = |0.5, 0.5, 0.5| returns False
|2.0, 2.0, 2.0|

Standard_Boolean Geom_BezierSurface::IsVClosed ( ) const
virtual

Returns True if the first control points column
and the last control points column are identical.
The tolerance criterion is Resolution from package gp.

Implements Geom_Surface.

Standard_Boolean Geom_BezierSurface::IsVPeriodic ( ) const
virtual

Returns False.

Implements Geom_Surface.

Standard_Boolean Geom_BezierSurface::IsVRational ( ) const

Returns False if the weights are identical in the V direction, <br>

The tolerance criterion is Resolution from package gp.
Example :
|1.0, 2.0, 0.5|
if Weights = |1.0, 2.0, 0.5| returns False
|1.0, 2.0, 0.5|

static Standard_Integer Geom_BezierSurface::MaxDegree ( )
static

Returns the value of the maximum polynomial degree of a
Bezier surface. This value is 25.

Standard_Integer Geom_BezierSurface::NbUPoles ( ) const

Returns the number of poles in the U direction.

Standard_Integer Geom_BezierSurface::NbVPoles ( ) const

Returns the number of poles in the V direction.

gp_Pnt Geom_BezierSurface::Pole ( const Standard_Integer  UIndex,
const Standard_Integer  VIndex 
) const

Returns the pole of range UIndex, VIndex <br>//! Raised if UIndex < 1 or UIndex > NbUPoles, or <br>

VIndex < 1 or VIndex > NbVPoles.

void Geom_BezierSurface::Poles ( TColgp_Array2OfPnt P) const

Returns the poles of the Bezier surface. <br>

Raised if the length of P in the U an V direction is not equal to
NbUPoles and NbVPoles.

void Geom_BezierSurface::RemovePoleCol ( const Standard_Integer  VIndex)

Removes a column of poles. <br>

If the surface was rational it can become non-rational.
Raised if NbVPoles <= 2 after removing, a Bezier surface
must have at least two columns of poles.
//! Raised if Vindex < 1 or VIndex > NbVPoles

void Geom_BezierSurface::RemovePoleRow ( const Standard_Integer  UIndex)

Removes a row of poles. <br>

If the surface was rational it can become non-rational.
Raised if NbUPoles <= 2 after removing, a Bezier surface
must have at least two rows of poles.
//! Raised if Uindex < 1 or UIndex > NbUPoles

void Geom_BezierSurface::Resolution ( const Standard_Real  Tolerance3D,
Standard_Real UTolerance,
Standard_Real VTolerance 
)

 Computes two tolerance values for this Bezier <br>

surface, based on the given tolerance in 3D space
Tolerance3D. The tolerances computed are:

  • UTolerance in the u parametric direction, and
  • VTolerance in the v parametric direction.
    If f(u,v) is the equation of this Bezier surface,
    UTolerance and VTolerance guarantee that:
    | u1 - u0 | < UTolerance and
    | v1 - v0 | < VTolerance
    ====> |f (u1,v1) - f (u0,v0)| < Tolerance3D
void Geom_BezierSurface::Segment ( const Standard_Real  U1,
const Standard_Real  U2,
const Standard_Real  V1,
const Standard_Real  V2 
)

 Modifies this Bezier surface by segmenting it <br>

between U1 and U2 in the u parametric direction,
and between V1 and V2 in the v parametric
direction. U1, U2, V1, and V2 can be outside the
bounds of this surface.

  • U1 and U2 isoparametric Bezier curves,
    segmented between V1 and V2, become the two
    bounds of the surface in the v parametric
    direction (0. and 1. u isoparametric curves).
  • V1 and V2 isoparametric Bezier curves,
    segmented between U1 and U2, become the two
    bounds of the surface in the u parametric
    direction (0. and 1. v isoparametric curves).
    The poles and weights tables are modified, but the
    degree of this surface in the u and v parametric
    directions does not change.
    U1 can be greater than U2, and V1 can be greater
    than V2. In these cases, the corresponding
    parametric direction is inverted. The orientation of
    the surface is inverted if one (and only one)
    parametric direction is inverted.
void Geom_BezierSurface::SetPole ( const Standard_Integer  UIndex,
const Standard_Integer  VIndex,
const gp_Pnt P 
)

Modifies a pole value. <br>

If the surface is rational the weight of range (UIndex, VIndex)
is not modified.
Raised if UIndex < 1 or UIndex > NbUPoles or VIndex < 1
or VIndex > NbVPoles.

void Geom_BezierSurface::SetPole ( const Standard_Integer  UIndex,
const Standard_Integer  VIndex,
const gp_Pnt P,
const Standard_Real  Weight 
)

Substitutes the pole and the weight of range UIndex, VIndex.
If the surface <me> is not rational it can become rational.
if the surface was rational it can become non-rational.
raises if UIndex < 1 or UIndex > NbUPoles or VIndex < 1
or VIndex > NbVPoles.
//! Raised if Weight <= Resolution from package gp.

void Geom_BezierSurface::SetPoleCol ( const Standard_Integer  VIndex,
const TColgp_Array1OfPnt CPoles 
)

 Modifies a column of poles. <br>

The length of CPoles can be lower but not greater than NbUPoles
so you can modify just a part of the column.
//! Raised if VIndex < 1 or VIndex > NbVPoles
Raised if CPoles.Lower() < 1 or CPoles.Upper() > NbUPoles

void Geom_BezierSurface::SetPoleCol ( const Standard_Integer  VIndex,
const TColgp_Array1OfPnt CPoles,
const TColStd_Array1OfReal CPoleWeights 
)

 Modifies a column of poles. <br>

If the surface was rational it can become non-rational
If the surface was non-rational it can become rational.
The length of CPoles can be lower but not greater than NbUPoles
so you can modify just a part of the column.
//! Raised if VIndex < 1 or VIndex > NbVPoles
Raised if CPoles.Lower() < 1 or CPoles.Upper() > NbUPoles
Raised if CPoleWeights and CPoles have not the same bounds.
Raised if one of the weight value CPoleWeights (i) is lower
or equal to Resolution from package gp.

void Geom_BezierSurface::SetPoleRow ( const Standard_Integer  UIndex,
const TColgp_Array1OfPnt CPoles 
)

 Modifies a row of poles. <br>

The length of CPoles can be lower but not greater than NbVPoles
so you can modify just a part of the row.
//! Raised if UIndex < 1 or UIndex > NbUPoles
Raised if CPoles.Lower() < 1 or CPoles.Upper() > NbVPoles

void Geom_BezierSurface::SetPoleRow ( const Standard_Integer  UIndex,
const TColgp_Array1OfPnt CPoles,
const TColStd_Array1OfReal CPoleWeights 
)

 Modifies a row of poles and weights. <br>

If the surface was rational it can become non-rational.
If the surface was non-rational it can become rational.
The length of CPoles can be lower but not greater than NbVPoles
so you can modify just a part of the row.
//! Raised if UIndex < 1 or UIndex > NbUPoles
Raised if CPoles.Lower() < 1 or CPoles.Upper() > NbVPoles
Raised if CPoleWeights and CPoles have not the same bounds.
Raised if one of the weight value CPoleWeights (i) is lower
or equal to Resolution from gp.

void Geom_BezierSurface::SetWeight ( const Standard_Integer  UIndex,
const Standard_Integer  VIndex,
const Standard_Real  Weight 
)

Modifies the weight of the pole of range UIndex, VIndex.
If the surface was non-rational it can become rational.
If the surface was rational it can become non-rational.
Raised if UIndex < 1 or UIndex > NbUPoles or VIndex < 1 or
VIndex > NbVPoles.
//! Raised if Weight <= Resolution from package gp.

void Geom_BezierSurface::SetWeightCol ( const Standard_Integer  VIndex,
const TColStd_Array1OfReal CPoleWeights 
)

 Modifies a column of weights. <br>

If the surface was rational it can become non-rational.
If the surface was non-rational it can become rational.
The length of CPoleWeights can be lower but not greater than
NbUPoles.
//! Raised if VIndex < 1 or VIndex > NbVPoles
Raised if CPoleWeights.Lower() < 1 or CPoleWeights.Upper() >
NbUPoles
Raised if one of the weight value CPoleWeights (i) is lower
or equal to Resolution from package gp.

void Geom_BezierSurface::SetWeightRow ( const Standard_Integer  UIndex,
const TColStd_Array1OfReal CPoleWeights 
)

 Modifies a row of weights. <br>

If the surface was rational it can become non-rational.
If the surface was non-rational it can become rational.
The length of CPoleWeights can be lower but not greater than
NbVPoles.
//! Raised if UIndex < 1 or UIndex > NbUPoles
Raised if CPoleWeights.Lower() < 1 or CPoleWeights.Upper() >
NbVPoles
Raised if one of the weight value CPoleWeights (i) is lower
or equal to Resolution from package gp.

void Geom_BezierSurface::Transform ( const gp_Trsf T)
virtual

Applies the transformation T to this Bezier surface.

Implements Geom_Geometry.

Standard_Integer Geom_BezierSurface::UDegree ( ) const

Returns the degree of the surface in the U direction it is
NbUPoles - 1

Handle_Geom_Curve Geom_BezierSurface::UIso ( const Standard_Real  U) const
virtual

Computes the U isoparametric curve. For a Bezier surface the
UIso curve is a Bezier curve.

Implements Geom_Surface.

void Geom_BezierSurface::UReverse ( )
virtual

 Changes the orientation of this Bezier surface in the <br>

u parametric direction. The bounds of the
surface are not changed, but the given parametric
direction is reversed. Hence, the orientation of the surface is reversed.

Implements Geom_Surface.

Standard_Real Geom_BezierSurface::UReversedParameter ( const Standard_Real  U) const
virtual

 Computes the u (or v) parameter on the modified <br>

surface, produced by reversing its u (or v) parametric
direction, for any point of u parameter U (or of v
parameter V) on this Bezier surface.
In the case of a Bezier surface, these functions return respectively:

  • 1.-U, or 1.-V.

Implements Geom_Surface.

Standard_Integer Geom_BezierSurface::VDegree ( ) const

Returns the degree of the surface in the V direction it is
NbVPoles - 1

Handle_Geom_Curve Geom_BezierSurface::VIso ( const Standard_Real  V) const
virtual

Computes the V isoparametric curve. For a Bezier surface the
VIso curve is a Bezier curve.

Implements Geom_Surface.

void Geom_BezierSurface::VReverse ( )
virtual

 Changes the orientation of this Bezier surface in the <br>

v parametric direction. The bounds of the
surface are not changed, but the given parametric
direction is reversed. Hence, the orientation of the
surface is reversed.

Implements Geom_Surface.

Standard_Real Geom_BezierSurface::VReversedParameter ( const Standard_Real  V) const
virtual

 Computes the u (or v) parameter on the modified <br>

surface, produced by reversing its u (or v) parametric
direction, for any point of u parameter U (or of v
parameter V) on this Bezier surface.
In the case of a Bezier surface, these functions return respectively:

  • 1.-U, or 1.-V.

Implements Geom_Surface.

Standard_Real Geom_BezierSurface::Weight ( const Standard_Integer  UIndex,
const Standard_Integer  VIndex 
) const

Returns the weight of range UIndex, VIndex <br>

Raised if UIndex < 1 or UIndex > NbUPoles, or
VIndex < 1 or VIndex > NbVPoles.

void Geom_BezierSurface::Weights ( TColStd_Array2OfReal W) const

Returns the weights of the Bezier surface. <br>

Raised if the length of W in the U an V direction is not
equal to NbUPoles and NbVPoles.


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