+ removed unneeded pure virtual method getFaces from PropertyComplexGeoData

+ extend interface of ComplexGeoData::getPoints to also return normals if available
This commit is contained in:
wmayer
2016-03-04 17:16:57 +01:00
parent 288841cf98
commit 0ea6a2ed0d
16 changed files with 24 additions and 56 deletions

View File

@@ -76,13 +76,6 @@ Base::BoundBox3d PropertyPointKernel::getBoundingBox() const
return box;
}
void PropertyPointKernel::getFaces(std::vector<Base::Vector3d> &Points,
std::vector<Data::ComplexGeoData::Facet> &Topo,
float Accuracy, uint16_t flags) const
{
_cPoints->getFaces(Points, Topo, Accuracy, flags);
}
PyObject *PropertyPointKernel::getPyObject(void)
{
PointsPy* points = new PointsPy(&*_cPoints);

View File

@@ -52,10 +52,6 @@ public:
//@{
/** Returns the bounding box around the underlying mesh kernel */
Base::BoundBox3d getBoundingBox() const;
/** Get faces from object with given accuracy */
virtual void getFaces(std::vector<Base::Vector3d> &Points,
std::vector<Data::ComplexGeoData::Facet> &Topo,
float Accuracy, uint16_t flags=0) const;
//@}
/** @name Python interface */

View File

@@ -195,7 +195,8 @@ void CmdPointsConvert::activated(int iMsg)
if (prop) {
const Data::ComplexGeoData* data = prop->getComplexData();
std::vector<Base::Vector3d> vertexes;
data->getPoints(vertexes, 0.0f);
std::vector<Base::Vector3d> normals;
data->getPoints(vertexes, normals, 0.0f);
if (!vertexes.empty()) {
App::Document* doc = (*it)->getDocument();
Points::Feature* fea = static_cast<Points::Feature*>(doc->addObject("Points::Feature", "Points"));