py3: Part: App: gathering commits relevant for Mod/Part/App
This commit is contained in:
@@ -225,7 +225,11 @@ PyObject* BSplineCurvePy::insertKnots(PyObject * args)
|
||||
TColStd_Array1OfInteger m(1,mults.size());
|
||||
index=1;
|
||||
for (Py::Sequence::iterator it = mults.begin(); it != mults.end(); ++it) {
|
||||
#if PY_MAJOR_VERSION >= 3
|
||||
Py::Long val(*it);
|
||||
#else
|
||||
Py::Int val(*it);
|
||||
#endif
|
||||
m(index++) = (int)val;
|
||||
}
|
||||
|
||||
@@ -672,7 +676,6 @@ PyObject* BSplineCurvePy::getMultiplicities(PyObject * args)
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
Py::Long BSplineCurvePy::getDegree(void) const
|
||||
{
|
||||
Handle_Geom_BSplineCurve curve = Handle_Geom_BSplineCurve::DownCast
|
||||
@@ -1211,7 +1214,11 @@ PyObject* BSplineCurvePy::buildFromPolesMultsKnots(PyObject *args, PyObject *key
|
||||
Py::Sequence multssq(mults);
|
||||
Standard_Integer index = 1;
|
||||
for (Py::Sequence::iterator it = multssq.begin(); it != multssq.end() && index <= occmults.Length(); ++it) {
|
||||
#if PY_MAJOR_VERSION >= 3
|
||||
Py::Long mult(*it);
|
||||
#else
|
||||
Py::Int mult(*it);
|
||||
#endif
|
||||
if (index < occmults.Length() || PyObject_Not(periodic)) {
|
||||
sum_of_mults += static_cast<int>(mult); //sum up the mults to compare them against the number of poles later
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user