X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=doc%2Fsalome%2Fexamples%2Fcreating_meshes_ex07.py;h=4ddb69702ac8697566ef2d860b3353d0d890deec;hb=f513b3c72c0c9c1a0c68bae34813cb41ac6fdcd5;hp=65a4f742efcbc78d80f789f7c139e4aa9ee2f817;hpb=54182913fbb9df65a3f4cc96f55db3618835ecd8;p=modules%2Fsmesh.git diff --git a/doc/salome/examples/creating_meshes_ex07.py b/doc/salome/examples/creating_meshes_ex07.py index 65a4f742e..4ddb69702 100644 --- a/doc/salome/examples/creating_meshes_ex07.py +++ b/doc/salome/examples/creating_meshes_ex07.py @@ -1,5 +1,4 @@ # Building a compound of meshes -# Note: it is a copy of 'SMESH_BuildCompound.py' from SMESH_SWIG import salome salome.salome_init() @@ -69,11 +68,14 @@ Gsup2=Mesh_sup.Group(Fsup2, "Sup") Ginf2=Mesh_sup.Group(Finf2, "Inf") ## create compounds -# create a compound of two meshes with renaming groups with the same names and -# merging of elements with the given tolerance -Compound1 = smesh.Concatenate([Mesh_inf.GetMesh(), Mesh_sup.GetMesh()], 0, 1, 1e-05) -smesh.SetName(Compound1, 'Compound_with_RenamedGrps_and_MergeElems') -# create a compound of two meshes with uniting groups with the same names and +# create a compound of two meshes with renaming namesake groups and +# merging elements with the given tolerance +Compound1 = smesh.Concatenate([Mesh_inf, Mesh_sup], 0, 1, 1e-05, + name='Compound with RenamedGrps and MergeElems') +# create a compound of two meshes with uniting namesake groups and # creating groups of all elements -Compound2 = smesh.Concatenate([Mesh_inf.GetMesh(), Mesh_sup.GetMesh()], 1, 0, 1e-05, True) -smesh.SetName(Compound2, 'Compound_with_UniteGrps_and_GrpsOfAllElems') +Compound2 = smesh.Concatenate([Mesh_inf, Mesh_sup], 1, 0, 1e-05, True, + name='Compound with UniteGrps and GrpsOfAllElems') + +if salome.sg.hasDesktop(): + salome.sg.updateObjBrowser(True)