Skip to content
Snippets Groups Projects
Commit c5fe4723 authored by Bruno Seny's avatar Bruno Seny
Browse files

gmsh/Geo: temporary fix for bindingsGet....

parent aca534bd
No related branches found
No related tags found
No related merge requests found
......@@ -195,6 +195,26 @@ bool GModel::empty() const
return vertices.empty() && edges.empty() && faces.empty() && regions.empty();
}
std::vector<GRegion*> GModel::bindingsGetRegions()
{
return std::vector<GRegion*> (regions.begin(), regions.end());
}
std::vector<GFace*> GModel::bindingsGetFaces()
{
return std::vector<GFace*> (faces.begin(), faces.end());
}
std::vector<GEdge*> GModel::bindingsGetEdges()
{
return std::vector<GEdge*> (edges.begin(), edges.end());
}
std::vector<GVertex*> GModel::bindingsGetVertices()
{
return std::vector<GVertex*> (vertices.begin(), vertices.end());
}
GRegion *GModel::getRegionByTag(int n) const
{
GEntity tmp((GModel*)this, n);
......
......@@ -204,6 +204,12 @@ class GModel
GFace *getFaceByTag(int n) const;
GEdge *getEdgeByTag(int n) const;
GVertex *getVertexByTag(int n) const;
// for python, temporary solution while iterator are not binded
std::vector<GRegion*> bindingsGetRegions();
std::vector<GFace*> bindingsGetFaces();
std::vector<GEdge*> bindingsGetEdges();
std::vector<GVertex*> bindingsGetVertices();
// add/remove an entity in the model
void add(GRegion *r) { regions.insert(r); }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment