Part: handle removal of function HLRBRep_PolyAlgo::Angle in OCC 7.5

This commit is contained in:
wmayer
2021-12-21 21:26:00 +01:00
parent 20f9aa42e7
commit 6e457c9ea8

View File

@@ -25,6 +25,7 @@
#ifndef _PreComp_
# include <gp_Ax2.hxx>
# include <gp_Pnt.hxx>
# include <Standard_Version.hxx>
# include <limits>
#endif
@@ -242,12 +243,20 @@ PyObject* HLRBRep_PolyAlgoPy::outLinedShape(PyObject *args)
Py::Float HLRBRep_PolyAlgoPy::getAngle() const
{
#if OCC_VERSION_HEX <= 0x070400
return Py::Float(getHLRBRep_PolyAlgoPtr()->Angle());
#else
throw Py::RuntimeError("Function has been removed with OCC 7.5");
#endif
}
void HLRBRep_PolyAlgoPy::setAngle(Py::Float arg)
{
#if OCC_VERSION_HEX <= 0x070400
getHLRBRep_PolyAlgoPtr()->Angle(static_cast<double>(arg));
#else
(void)arg;
#endif
}
Py::Float HLRBRep_PolyAlgoPy::getTolAngular() const