Salome HOME
0022104: EDF 2550 SMESH: 2D viscous layer, allow specifying edges with viscous layer
[modules/smesh.git] / src / StdMeshers_I / StdMeshers_ViscousLayers_i.cxx
index 99f7f1d6bf64a41813da0a06ed181e2062d76e9d..5ad82c7ecbb22ef1dd9b8a2c8d775b25ccc0f63c 100644 (file)
@@ -85,7 +85,7 @@ throw ( SALOME::SALOME_Exception )
   for ( unsigned i = 0; i < ids.size(); ++i )
     if (( ids[i] = faceIDs[i] ) < 1 )
       THROW_SALOME_CORBA_EXCEPTION( "Invalid face id", SALOME::BAD_PARAM );
-  GetImpl()->SetBndShapesToIgnore( ids );
+  GetImpl()->SetBndShapes( ids, /*toIgnore=*/true );
   SMESH::TPythonDump() << _this() << ".SetIgnoreFaces( " << faceIDs << " )";
 }
 
@@ -97,11 +97,14 @@ throw ( SALOME::SALOME_Exception )
 
 SMESH::long_array* StdMeshers_ViscousLayers_i::GetIgnoreFaces()
 {
-  vector<int> idsVec = GetImpl()->GetBndShapesToIgnore();
   SMESH::long_array_var ids = new SMESH::long_array;
-  ids->length( idsVec.size() );
-  for ( unsigned i = 0; i < idsVec.size(); ++i )
-    ids[i] = idsVec[i];
+  if ( GetImpl()->IsToIgnoreShapes() )
+  {
+    vector<int> idsVec = GetImpl()->GetBndShapes();
+    ids->length( idsVec.size() );
+    for ( unsigned i = 0; i < idsVec.size(); ++i )
+      ids[i] = idsVec[i];
+  }
   return ids._retn();
 }