Remove oldFuse funcion
oldFuse is deprecated since OCC 7.3
This commit is contained in:
@@ -1781,15 +1781,6 @@ TopoDS_Shape TopoShape::fuse(const std::vector<TopoDS_Shape>& shapes, Standard_R
|
||||
return makeShell(resShape);
|
||||
}
|
||||
|
||||
TopoDS_Shape TopoShape::oldFuse(TopoDS_Shape shape) const
|
||||
{
|
||||
if (this->_Shape.IsNull())
|
||||
Standard_Failure::Raise("Base shape is null");
|
||||
if (shape.IsNull())
|
||||
Standard_Failure::Raise("Tool shape is null");
|
||||
|
||||
throw Standard_Failure("BRepAlgo_Fuse is deprecated since OCCT 7.3");
|
||||
}
|
||||
|
||||
TopoDS_Shape TopoShape::section(TopoDS_Shape shape, Standard_Boolean approximate) const
|
||||
{
|
||||
|
||||
@@ -509,7 +509,6 @@ public:
|
||||
TopoDS_Shape common(const std::vector<TopoDS_Shape>&, Standard_Real tolerance = -1.0) const;
|
||||
TopoDS_Shape fuse(TopoDS_Shape) const;
|
||||
TopoDS_Shape fuse(const std::vector<TopoDS_Shape>&, Standard_Real tolerance = -1.0) const;
|
||||
TopoDS_Shape oldFuse(TopoDS_Shape) const;
|
||||
TopoDS_Shape section(TopoDS_Shape, Standard_Boolean approximate = Standard_False) const;
|
||||
TopoDS_Shape section(const std::vector<TopoDS_Shape>&,
|
||||
Standard_Real tolerance = -1.0,
|
||||
@@ -2455,20 +2454,7 @@ public:
|
||||
const BRepFillingParams ¶ms,
|
||||
const char *op=nullptr);
|
||||
|
||||
/** Make a solid using shells or CompSolid
|
||||
*
|
||||
* @param shapes: input shapes of either shells or CompSolid.
|
||||
* @param op: optional string to be encoded into topo naming for indicating
|
||||
* the operation
|
||||
*
|
||||
* @return The function produces a solid. The original content of this
|
||||
* TopoShape is discarded and replaced with the new shape. The
|
||||
* function returns the TopoShape itself as a self reference so
|
||||
* that multiple operations can be carried out for the same shape
|
||||
* in the same line of code.
|
||||
*/
|
||||
// TODO: This does not appear to be called, and the implementation seems impossible
|
||||
// TopoShape &makeElementSolid(const std::vector<TopoShape> &shapes, const char *op=nullptr);
|
||||
|
||||
/** Make a solid using shells or CompSolid
|
||||
*
|
||||
* @param shape: input shape of either a shell, a compound of shells, or a
|
||||
|
||||
@@ -272,14 +272,6 @@ class TopoShape(ComplexGeoData):
|
||||
"""
|
||||
...
|
||||
|
||||
@constmethod
|
||||
def oldFuse(self, tool: TopoShape) -> TopoShape:
|
||||
"""
|
||||
Union of this and a given topo shape (old algorithm).
|
||||
oldFuse(tool) -> Shape
|
||||
"""
|
||||
...
|
||||
|
||||
@constmethod
|
||||
def common(self, tools: Tuple[TopoShape, ...], tolerance: float = 0.0) -> TopoShape:
|
||||
"""
|
||||
|
||||
@@ -699,28 +699,6 @@ PyObject* TopoShapePy::multiFuse(PyObject *args) const
|
||||
return makeShape(Part::OpCodes::Fuse, *getTopoShapePtr(), args);
|
||||
}
|
||||
|
||||
PyObject* TopoShapePy::oldFuse(PyObject *args) const
|
||||
{
|
||||
PyObject *pcObj;
|
||||
if (!PyArg_ParseTuple(args, "O!", &(TopoShapePy::Type), &pcObj))
|
||||
return nullptr;
|
||||
|
||||
TopoDS_Shape shape = static_cast<TopoShapePy*>(pcObj)->getTopoShapePtr()->getShape();
|
||||
try {
|
||||
// Let's call algorithm computing a fuse operation:
|
||||
TopoDS_Shape fusShape = this->getTopoShapePtr()->oldFuse(shape);
|
||||
return new TopoShapePy(new TopoShape(fusShape));
|
||||
}
|
||||
catch (Standard_Failure& e) {
|
||||
PyErr_SetString(PartExceptionOCCError, e.GetMessageString());
|
||||
return nullptr;
|
||||
}
|
||||
catch (const std::exception& e) {
|
||||
PyErr_SetString(PartExceptionOCCError, e.what());
|
||||
return nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
PyObject* TopoShapePy::common(PyObject *args) const
|
||||
{
|
||||
return makeShape(Part::OpCodes::Common, *getTopoShapePtr(), args);
|
||||
|
||||
Reference in New Issue
Block a user