Open CASCADE Technology  7.2.0
Public Member Functions
ShapeUpgrade_UnifySameDomain Class Reference

This tool tries to unify faces and edges of the shape which lies on the same geometry. Faces/edges considering as 'same-domain' if a group of neighbouring faces/edges lying on coincident surfaces/curves. In this case these faces/edges can be unified into one face/edge. ShapeUpgrade_UnifySameDomain initialized by the shape and the next optional parameters: UnifyFaces - tries to unify all possible faces UnifyEdges - tries to unify all possible edges ConcatBSplines - if this flag set to true then all neighbouring edges which lays on the BSpline or Bezier curves with C1 continuity on their common vertices will be merged into one common edge The output result of tool is an unified shape All the modifications of initial shape are recorded during unifying. Methods History are intended to:
More...

#include <ShapeUpgrade_UnifySameDomain.hxx>

Inheritance diagram for ShapeUpgrade_UnifySameDomain:
Inheritance graph
[legend]

Public Member Functions

 ShapeUpgrade_UnifySameDomain ()
 empty constructor More...
 
 ShapeUpgrade_UnifySameDomain (const TopoDS_Shape &aShape, const Standard_Boolean UnifyEdges=Standard_True, const Standard_Boolean UnifyFaces=Standard_True, const Standard_Boolean ConcatBSplines=Standard_False)
 
void Initialize (const TopoDS_Shape &aShape, const Standard_Boolean UnifyEdges=Standard_True, const Standard_Boolean UnifyFaces=Standard_True, const Standard_Boolean ConcatBSplines=Standard_False)
 Initializes with a shape. More...
 
void AllowInternalEdges (const Standard_Boolean theValue)
 Sets the flag defining whether it is allowed to create internal edges inside merged faces in the case of non-manifold topology. Without this flag merging through multi connected edge is forbidden. Default value is false. More...
 
void KeepShape (const TopoDS_Shape &theShape)
 Sets the shape for avoid merging of the faces in given places. This shape can be vertex or edge. If shape is vertex it forbids merging of connected edges. If shape is edge it forbids merging of connected faces. More...
 
void KeepShapes (const TopTools_MapOfShape &theShapes)
 Sets the map of shapes for avoid merging of the faces in given places These shapes can be vertexes or edges. If shape is vertex it forbids merging of connected edges. If shape is edge it forbids merging of connected faces. More...
 
void SetSafeInputMode (Standard_Boolean theValue)
 Sets the flag defining the behavior of the algorithm regarding modification of input shape. If this flag is equal to True then the input (original) shape can't be modified during modification process. Default value is true. More...
 
void SetLinearTolerance (const Standard_Real theValue)
 Sets the linear tolerance. Default value is Precision::Confusion(). More...
 
void SetAngularTolerance (const Standard_Real theValue)
 Sets the angular tolerance. Default value is Precision::Angular(). More...
 
void Build ()
 Builds the resulting shape. More...
 
const TopoDS_ShapeShape () const
 Gives the resulting shape. More...
 
void UnifyFaces ()
 this method makes if possible a common face from each group of faces lying on coincident surfaces More...
 
void UnifyEdges ()
 this method makes if possible a common edge from each group of edges connecting common couple of faces More...
 
void UnifyFacesAndEdges ()
 this method unifies same domain faces and edges More...
 
const Handle< BRepTools_History > & History () const
 Returns the history of the processed shapes. More...
 
Handle< BRepTools_History > & History ()
 Returns the history of the processed shapes. 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 Delete () const
 Memory deallocator for transient classes. More...
 
virtual const opencascade::handle< Standard_Type > & DynamicType () const
 Returns a type descriptor about this object. More...
 
Standard_Boolean IsInstance (const opencascade::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 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. 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...
 
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. More...
 
Standard_Integer GetRefCount () const
 Get the reference counter of this object. More...
 
void IncrementRefCounter () const
 Increments the reference counter of this object. More...
 
Standard_Integer DecrementRefCounter () const
 Decrements the reference counter of this object; returns the decremented value. More...
 

Additional Inherited Members

- Public Types inherited from Standard_Transient
typedef void base_type
 Returns a type descriptor about this object. More...
 
- Static Public Member Functions inherited from Standard_Transient
static const char * get_type_name ()
 Returns a type descriptor about this object. More...
 
static const opencascade::handle< Standard_Type > & get_type_descriptor ()
 Returns type descriptor of Standard_Transient class. More...
 

Detailed Description

This tool tries to unify faces and edges of the shape which lies on the same geometry. Faces/edges considering as 'same-domain' if a group of neighbouring faces/edges lying on coincident surfaces/curves. In this case these faces/edges can be unified into one face/edge. ShapeUpgrade_UnifySameDomain initialized by the shape and the next optional parameters: UnifyFaces - tries to unify all possible faces UnifyEdges - tries to unify all possible edges ConcatBSplines - if this flag set to true then all neighbouring edges which lays on the BSpline or Bezier curves with C1 continuity on their common vertices will be merged into one common edge The output result of tool is an unified shape All the modifications of initial shape are recorded during unifying. Methods History are intended to:

Constructor & Destructor Documentation

◆ ShapeUpgrade_UnifySameDomain() [1/2]

ShapeUpgrade_UnifySameDomain::ShapeUpgrade_UnifySameDomain ( )

empty constructor

◆ ShapeUpgrade_UnifySameDomain() [2/2]

ShapeUpgrade_UnifySameDomain::ShapeUpgrade_UnifySameDomain ( const TopoDS_Shape aShape,
const Standard_Boolean  UnifyEdges = Standard_True,
const Standard_Boolean  UnifyFaces = Standard_True,
const Standard_Boolean  ConcatBSplines = Standard_False 
)

Member Function Documentation

◆ AllowInternalEdges()

void ShapeUpgrade_UnifySameDomain::AllowInternalEdges ( const Standard_Boolean  theValue)

Sets the flag defining whether it is allowed to create internal edges inside merged faces in the case of non-manifold topology. Without this flag merging through multi connected edge is forbidden. Default value is false.

◆ Build()

void ShapeUpgrade_UnifySameDomain::Build ( )

Builds the resulting shape.

◆ History() [1/2]

const Handle< BRepTools_History >& ShapeUpgrade_UnifySameDomain::History ( ) const
inline

Returns the history of the processed shapes.

◆ History() [2/2]

Handle< BRepTools_History >& ShapeUpgrade_UnifySameDomain::History ( )
inline

Returns the history of the processed shapes.

◆ Initialize()

void ShapeUpgrade_UnifySameDomain::Initialize ( const TopoDS_Shape aShape,
const Standard_Boolean  UnifyEdges = Standard_True,
const Standard_Boolean  UnifyFaces = Standard_True,
const Standard_Boolean  ConcatBSplines = Standard_False 
)

Initializes with a shape.

◆ KeepShape()

void ShapeUpgrade_UnifySameDomain::KeepShape ( const TopoDS_Shape theShape)

Sets the shape for avoid merging of the faces in given places. This shape can be vertex or edge. If shape is vertex it forbids merging of connected edges. If shape is edge it forbids merging of connected faces.

◆ KeepShapes()

void ShapeUpgrade_UnifySameDomain::KeepShapes ( const TopTools_MapOfShape theShapes)

Sets the map of shapes for avoid merging of the faces in given places These shapes can be vertexes or edges. If shape is vertex it forbids merging of connected edges. If shape is edge it forbids merging of connected faces.

◆ SetAngularTolerance()

void ShapeUpgrade_UnifySameDomain::SetAngularTolerance ( const Standard_Real  theValue)
inline

Sets the angular tolerance. Default value is Precision::Angular().

◆ SetLinearTolerance()

void ShapeUpgrade_UnifySameDomain::SetLinearTolerance ( const Standard_Real  theValue)
inline

Sets the linear tolerance. Default value is Precision::Confusion().

◆ SetSafeInputMode()

void ShapeUpgrade_UnifySameDomain::SetSafeInputMode ( Standard_Boolean  theValue)

Sets the flag defining the behavior of the algorithm regarding modification of input shape. If this flag is equal to True then the input (original) shape can't be modified during modification process. Default value is true.

◆ Shape()

const TopoDS_Shape& ShapeUpgrade_UnifySameDomain::Shape ( ) const
inline

Gives the resulting shape.

◆ UnifyEdges()

void ShapeUpgrade_UnifySameDomain::UnifyEdges ( )

this method makes if possible a common edge from each group of edges connecting common couple of faces

◆ UnifyFaces()

void ShapeUpgrade_UnifySameDomain::UnifyFaces ( )

this method makes if possible a common face from each group of faces lying on coincident surfaces

◆ UnifyFacesAndEdges()

void ShapeUpgrade_UnifySameDomain::UnifyFacesAndEdges ( )

this method unifies same domain faces and edges


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