Mesh: define the typenames FacetIndex and PointIndex to distinguish between facet and point related indexes

This commit is contained in:
wmayer
2021-09-14 23:01:29 +02:00
parent 9ce79bf3c7
commit 2295c4b9a3
91 changed files with 2057 additions and 2254 deletions

View File

@@ -31,14 +31,14 @@
using namespace Mesh;
Facet::Facet(const MeshCore::MeshFacet& face, MeshObject* obj, unsigned long index)
Facet::Facet(const MeshCore::MeshFacet& face, MeshObject* obj, MeshCore::FacetIndex index)
: Index(index), Mesh(obj)
{
for (int i=0; i<3; i++) {
PIndex[i] = face._aulPoints[i];
NIndex[i] = face._aulNeighbours[i];
}
if (Mesh.isValid() && index != ULONG_MAX) {
if (Mesh.isValid() && index != MeshCore::FACET_INDEX_MAX) {
for (int i=0; i<3; i++) {
Base::Vector3d vert = Mesh->getPoint(PIndex[i]);
_aclPoints[i].Set((float)vert.x, (float)vert.y, (float)vert.z);