mirror of
https://github.com/NGSolve/netgen.git
synced 2025-01-11 21:50:34 +05:00
Merge branch 'new_interface_zero_based_access' into 'master'
zero based access to identification pairs in new interface See merge request jschoeberl/netgen!91
This commit is contained in:
commit
0a01392d80
@ -300,6 +300,8 @@ namespace netgen
|
||||
int GetParentElement (int ei) const;
|
||||
int GetParentSElement (int ei) const;
|
||||
|
||||
int GetNIdentifications() const;
|
||||
int GetIdentificationType(int idnr) const;
|
||||
Ng_Buffer<int[2]> GetPeriodicVertices(int idnr) const;
|
||||
|
||||
// Find element of point, returns local coordinates
|
||||
|
@ -300,7 +300,7 @@ template <> NGX_INLINE DLL_HEADER const Ng_Node<2> Ngx_Mesh :: GetNode<2> (int n
|
||||
NGX_INLINE DLL_HEADER Ng_Buffer<int[2]> Ngx_Mesh :: GetPeriodicVertices(int idnr) const
|
||||
{
|
||||
Array<INDEX_2> apairs;
|
||||
mesh->GetIdentifications().GetPairs (idnr, apairs);
|
||||
mesh->GetIdentifications().GetPairs (idnr+1, apairs);
|
||||
for(auto& ind : apairs)
|
||||
{
|
||||
ind.I1()--;
|
||||
|
@ -720,6 +720,16 @@ namespace netgen
|
||||
return -1;
|
||||
}
|
||||
|
||||
int Ngx_Mesh :: GetNIdentifications () const
|
||||
{
|
||||
return mesh->GetIdentifications().GetMaxNr();
|
||||
}
|
||||
|
||||
int Ngx_Mesh :: GetIdentificationType(int idnr) const
|
||||
{
|
||||
return mesh->GetIdentifications().GetType(idnr+1);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user