Commit 6b415c58 authored by Burlen Loring's avatar Burlen Loring

Expose ghost cells API in the Python data adaptor

parent dd0194f1
...@@ -12,6 +12,10 @@ ...@@ -12,6 +12,10 @@
%ignore sensei::DA::AddArray; %ignore sensei::DA::AddArray;
%ignore sensei::DA::GetNumberOfArrays; %ignore sensei::DA::GetNumberOfArrays;
%ignore sensei::DA::GetArrayName; %ignore sensei::DA::GetArrayName;
%ignore sensei::DA::GetMehsHasGhostNodes;
%ignore sensei::DA::GetMehsHasGhostCells;
%ignore sensei::DA::AddGhostNodesArray;
%ignore sensei::DA::AddGhostCellsArray;
%ignore sensei::DA::ReleaseData; %ignore sensei::DA::ReleaseData;
/* memory management */ /* memory management */
VTK_DERIVED(DA) VTK_DERIVED(DA)
......
...@@ -176,6 +176,44 @@ VTK_SWIG_INTEROP(vtkInformation) ...@@ -176,6 +176,44 @@ VTK_SWIG_INTEROP(vtkInformation)
return arrayName; return arrayName;
} }
// ------------------------------------------------------------------------
int GetMeshHasGhostCells(const std::string &meshName)
{
int nLayers = 0;
if (self->GetMeshHasGhostCells(meshName, nLayers))
{
SENSEI_ERROR("Failed to get number of ghost cells for mesh \""
<< meshName << "\"")
}
return nLayers;
}
// ------------------------------------------------------------------------
void AddGhostCellsArray(vtkDataObject* mesh, const std::string &meshName)
{
if (self->AddGhostCellsArray(mesh, meshName))
SENSEI_ERROR("Failed to add ghost cells to mesh \"" << meshName << "\"")
}
// ------------------------------------------------------------------------
int GetMeshHasGhostNodes(const std::string &meshName)
{
int nLayers = 0;
if (self->GetMeshHasGhostNodes(meshName, nLayers))
{
SENSEI_ERROR("Failed to get number of ghost nodes for mesh \""
<< meshName << "\"")
}
return nLayers;
}
// ------------------------------------------------------------------------
void AddGhostNodesArray(vtkDataObject* mesh, const std::string &meshName)
{
if (self->AddGhostNodesArray(mesh, meshName))
SENSEI_ERROR("Failed to add ghost nodes to mesh \"" << meshName << "\"")
}
// ------------------------------------------------------------------------ // ------------------------------------------------------------------------
void ReleaseData() void ReleaseData()
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment