diff --git a/MeshLib/Elements/Element.cpp b/MeshLib/Elements/Element.cpp index 66cb6195a038d9119bd45e7d48d85666143ff8fe..243cedd9746eb39b4bf469ba6e0590e33aaf5664 100644 --- a/MeshLib/Elements/Element.cpp +++ b/MeshLib/Elements/Element.cpp @@ -13,12 +13,12 @@ namespace MeshLib { Element::Element(Node** nodes, MshElemType::type type, size_t value) - : _nodes(nodes), _type(type), _value(value) + : _type(type), _nodes(nodes), _value(value) { } Element::Element(MshElemType::type type, size_t value) - : _type(type), _value(value) + : _type(type), _nodes(NULL), _value(value) { } @@ -33,7 +33,7 @@ const Node* Element::getNode(size_t i) const return _nodes[i]; } -size_t Element::getNodeIndex(size_t i) const +size_t Element::getNodeIndex(size_t i) const { assert(i<getNNodes() && "Error in MeshLib::Element - Index does not exist."); return _nodes[i]->getID(); diff --git a/MeshLib/Elements/Element.h b/MeshLib/Elements/Element.h index e84058b12552fb2c6fc7ad294033b2df498d87ff..ddb3b07f118fe307579f165f9eb3943bbfc8c567 100644 --- a/MeshLib/Elements/Element.h +++ b/MeshLib/Elements/Element.h @@ -60,8 +60,8 @@ protected: Node* getNode(size_t i); MshElemType::type _type; - size_t _value; Node** _nodes; + size_t _value; std::vector<Element*> _neighbors; private: