Part: fix build failures with OCC >= 7.6

This commit is contained in:
wmayer
2022-08-10 00:59:45 +02:00
committed by Uwe
parent 7f8c5bcd85
commit 3c8404fd09
8 changed files with 42 additions and 13 deletions
@@ -107,7 +107,11 @@ void BRepOffsetAPI_MakeOffsetFix::Perform (const Standard_Real Offset, const Sta
mkOffset.Perform(Offset, Alt);
}
#if OCC_VERSION_HEX >= 0x070600
void BRepOffsetAPI_MakeOffsetFix::Build(const Message_ProgressRange&)
#else
void BRepOffsetAPI_MakeOffsetFix::Build()
#endif
{
mkOffset.Build();
}
@@ -27,8 +27,7 @@
#include <Mod/Part/PartGlobal.h>
#include <BRepOffsetAPI_MakeOffset.hxx>
#include <GeomAbs_CurveType.hxx>
#include <list>
#include <map>
#include <Standard_Version.hxx>
namespace Part {
/*!
@@ -54,7 +53,11 @@ public:
void Perform (const Standard_Real Offset, const Standard_Real Alt = 0.0);
//! Builds the resulting shape (redefined from MakeShape).
void Build();
#if OCC_VERSION_HEX >= 0x070600
void Build(const Message_ProgressRange& theRange = Message_ProgressRange()) override;
#else
void Build() override;
#endif
//! Initializes the algorithm to construct parallels to the spine Spine.
//! Join defines the type of parallel generated by the
+4
View File
@@ -83,7 +83,11 @@ const TopoDS_Face& Part::FaceMaker::Face()
return TopoDS::Face(sh);
}
#if OCC_VERSION_HEX >= 0x070600
void Part::FaceMaker::Build(const Message_ProgressRange&)
#else
void Part::FaceMaker::Build()
#endif
{
this->NotDone();
this->myShapesToReturn.clear();
+6 -2
View File
@@ -24,7 +24,7 @@
#define PART_FACEMAKER_H
#include <BRepBuilderAPI_MakeShape.hxx>
#include <Base/BaseClass.h>
#include <Standard_Version.hxx>
#include <TopoDS_Compound.hxx>
#include <TopoDS_Face.hxx>
#include <TopoDS_Wire.hxx>
@@ -74,7 +74,11 @@ public:
*/
virtual const TopoDS_Face& Face();
virtual void Build();
#if OCC_VERSION_HEX >= 0x070600
void Build(const Message_ProgressRange& theRange = Message_ProgressRange()) override;
#else
void Build() override;
#endif
//fails to compile, huh!
//virtual const TopTools_ListOfShape& Generated(const TopoDS_Shape &S) override {throwNotImplemented();}
+4
View File
@@ -344,7 +344,11 @@ std::string FaceMakerExtrusion::getBriefExplanation() const
return std::string(QT_TRANSLATE_NOOP("Part_FaceMaker", "Supports making faces with holes, does not support nesting."));
}
#if OCC_VERSION_HEX >= 0x070600
void FaceMakerExtrusion::Build(const Message_ProgressRange&)
#else
void FaceMakerExtrusion::Build()
#endif
{
this->NotDone();
this->myGenerated.Clear();
+6 -1
View File
@@ -136,7 +136,12 @@ public:
virtual std::string getUserFriendlyName() const override;
virtual std::string getBriefExplanation() const override;
virtual void Build() override;
#if OCC_VERSION_HEX >= 0x070600
void Build(const Message_ProgressRange& theRange = Message_ProgressRange()) override;
#else
void Build() override;
#endif
protected:
virtual void Build_Essence() override {}
};
+4
View File
@@ -1223,7 +1223,11 @@ Part::BRepBuilderAPI_RefineModel::BRepBuilderAPI_RefineModel(const TopoDS_Shape&
Build();
}
#if OCC_VERSION_HEX >= 0x070600
void Part::BRepBuilderAPI_RefineModel::Build(const Message_ProgressRange&)
#else
void Part::BRepBuilderAPI_RefineModel::Build()
#endif
{
if (myShape.IsNull())
Standard_Failure::Raise("Cannot remove splitter from empty shape");
+8 -7
View File
@@ -28,10 +28,7 @@
#include <map>
#include <list>
#include <GeomAbs_SurfaceType.hxx>
#include <TopoDS_Shell.hxx>
#include <TopoDS_Face.hxx>
#include <TopoDS_Solid.hxx>
#include <TopoDS_Wire.hxx>
#include <Standard_Version.hxx>
#include <TopoDS_Edge.hxx>
#include <TopTools_DataMapOfShapeListOfShape.hxx>
#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
@@ -198,9 +195,13 @@ class PartExport BRepBuilderAPI_RefineModel : public BRepBuilderAPI_MakeShape
{
public:
BRepBuilderAPI_RefineModel(const TopoDS_Shape&);
void Build();
const TopTools_ListOfShape& Modified(const TopoDS_Shape& S);
Standard_Boolean IsDeleted(const TopoDS_Shape& S);
#if OCC_VERSION_HEX >= 0x070600
void Build(const Message_ProgressRange& theRange = Message_ProgressRange()) override;
#else
void Build() override;
#endif
const TopTools_ListOfShape& Modified(const TopoDS_Shape& S) override;
Standard_Boolean IsDeleted(const TopoDS_Shape& S) override;
private:
void LogModifications(const ModelRefine::FaceUniter& uniter);