mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2025-03-01 13:05:36 +05:00
0020095: EDF 896 SMESH : Advanced Mesh info on a group
This commit is contained in:
parent
76756b1464
commit
f5ebc48243
@ -44,11 +44,6 @@ The following information will be displayed:
|
|||||||
|
|
||||||
\image html advanced_mesh_infos.png
|
\image html advanced_mesh_infos.png
|
||||||
|
|
||||||
In case you get Mesh Infos via a \ref tui_viewing_mesh_infos "TUI script",
|
|
||||||
the information is displayed in Python Console.
|
|
||||||
|
|
||||||
\image html b-mesh_infos.png
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
\anchor mesh_element_info_anchor
|
\anchor mesh_element_info_anchor
|
||||||
<h2>Mesh Element Info</h2>
|
<h2>Mesh Element Info</h2>
|
||||||
@ -61,4 +56,7 @@ the Viewer.
|
|||||||
|
|
||||||
\image html eleminfo2.png
|
\image html eleminfo2.png
|
||||||
|
|
||||||
|
In case you get Mesh Infos via a TUI script the information is displayed in Python Console.
|
||||||
|
<b>See the</b> \ref tui_viewing_mesh_infos "TUI Example",
|
||||||
|
|
||||||
*/
|
*/
|
@ -9,6 +9,7 @@
|
|||||||
\code
|
\code
|
||||||
import geompy
|
import geompy
|
||||||
import smesh
|
import smesh
|
||||||
|
import SMESH
|
||||||
|
|
||||||
# create a box
|
# create a box
|
||||||
box = geompy.MakeBox(0., 0., 0., 20., 20., 20.)
|
box = geompy.MakeBox(0., 0., 0., 20., 20., 20.)
|
||||||
@ -43,5 +44,39 @@ print " hexahedrons : ", tetra.NbHexas()
|
|||||||
print " prisms : ", tetra.NbPrisms()
|
print " prisms : ", tetra.NbPrisms()
|
||||||
print " pyramids : ", tetra.NbPyramids()
|
print " pyramids : ", tetra.NbPyramids()
|
||||||
print " polyhedrons : ", tetra.NbPolyhedrons()
|
print " polyhedrons : ", tetra.NbPolyhedrons()
|
||||||
|
|
||||||
|
# Get Information About Mesh by GetMeshInfo
|
||||||
|
print "\nInformation about mesh by GetMeshInfo:"
|
||||||
|
info = smesh.GetMeshInfo(tetra)
|
||||||
|
for i in info:
|
||||||
|
print " %s : %d" % ( i, info[i] )
|
||||||
|
pass
|
||||||
|
|
||||||
|
# Creation of group
|
||||||
|
group = tetra.CreateEmptyGroup( SMESH.FACE, 'Group' )
|
||||||
|
nbAdd = group.Add( [ 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76 ] )
|
||||||
|
|
||||||
|
# Get Information About Group by GetMeshInfo
|
||||||
|
print "\nInformation about group by GetMeshInfo:"
|
||||||
|
info = smesh.GetMeshInfo(group)
|
||||||
|
for i in info:
|
||||||
|
print " %s : %d" % ( i, info[i] )
|
||||||
|
pass
|
||||||
|
|
||||||
|
# Creation of SubMesh
|
||||||
|
Regular_1D_1_1 = tetra.Segment(geom=Face)
|
||||||
|
Nb_Segments_1 = Regular_1D_1_1.NumberOfSegments(5)
|
||||||
|
Nb_Segments_1.SetDistrType( 0 )
|
||||||
|
Quadrangle_2D = tetra.Quadrangle(geom=Face)
|
||||||
|
isDone = tetra.Compute()
|
||||||
|
submesh = Regular_1D_1_1.GetSubMesh()
|
||||||
|
|
||||||
|
# Get Information About SubMesh by GetMeshInfo
|
||||||
|
print "\nInformation about Submesh by GetMeshInfo:"
|
||||||
|
info = smesh.GetMeshInfo(submesh)
|
||||||
|
for i in info:
|
||||||
|
print " %s : %d" % ( i, info[i] )
|
||||||
|
pass
|
||||||
|
|
||||||
\endcode
|
\endcode
|
||||||
*/
|
*/
|
Loading…
Reference in New Issue
Block a user