Added center property to Path to deal with rendering rotational axis.

This commit is contained in:
Markus Lampert
2018-05-04 12:09:17 -07:00
committed by Yorik van Havre
parent 1f030de9ac
commit cbd5f297f3
5 changed files with 68 additions and 13 deletions

View File

@@ -29,6 +29,7 @@
#include "PathPy.h"
#include "PathPy.cpp"
#include "Base/GeometryPyCXX.h"
#include "CommandPy.h"
using namespace Path;
@@ -105,6 +106,16 @@ void PathPy::setCommands(Py::List list)
}
}
Py::Object PathPy::getCenter(void) const
{
return Py::Vector(getToolpathPtr()->getCenter());
}
void PathPy::setCenter(Py::Object obj)
{
getToolpathPtr()->setCenter(Py::Vector(obj).toVector());
}
// read-only attributes
Py::Float PathPy::getLength(void) const