changes due to the fact that Tetra_3D has been remplaced by NETGEN_3D.

This commit is contained in:
nadir 2003-11-24 13:30:26 +00:00
parent 28a1583230
commit 5f6e315d29
4 changed files with 28 additions and 28 deletions

View File

@ -137,12 +137,12 @@ mefisto2D = hypothesis._narrow(SMESH.SMESH_MEFISTO_2D)
mefistoID = smeshgui.AddNewAlgorithms( salome.orb.object_to_string(mefisto2D) )
smeshgui.SetName(mefistoID, "MEFISTO_2D")
print "-------------------------- Tetra_3D"
print "-------------------------- NETGEN_3D"
hypothesis=gen.CreateHypothesis("Tetra_3D")
tetra3D = hypothesis._narrow(SMESH.SMESH_Tetra_3D)
tetraID = smeshgui.AddNewAlgorithms( salome.orb.object_to_string(tetra3D) )
smeshgui.SetName(tetraID, "Tetra_3D")
hypothesis=gen.CreateHypothesis("NETGEN_3D")
netgen3D = hypothesis._narrow(SMESH.SMESH_NETGEN_3D)
netgenID = smeshgui.AddNewAlgorithms( salome.orb.object_to_string(netgen3D) )
smeshgui.SetName(netgenID, "NETGEN_3D")
# ---- init a Mesh with the shell
@ -163,7 +163,7 @@ ret=mesh.AddHypothesis(shell,mefisto2D)
print ret
ret=mesh.AddHypothesis(shell,hypArea)
print ret
ret=mesh.AddHypothesis(shell,tetra3D)
ret=mesh.AddHypothesis(shell,netgen3D)
print ret
ret=mesh.AddHypothesis(shell,hypVolume)
print ret
@ -172,7 +172,7 @@ smeshgui.SetAlgorithms( idmesh, regularID)
smeshgui.SetHypothesis( idmesh, idseg )
smeshgui.SetAlgorithms( idmesh, mefistoID )
smeshgui.SetHypothesis( idmesh, idarea )
smeshgui.SetAlgorithms( idmesh, tetraID )
smeshgui.SetAlgorithms( idmesh, netgenID )
smeshgui.SetHypothesis( idmesh, idvolume )
sg.updateObjBrowser(1)

View File

@ -3,7 +3,7 @@
# one has a race in common with the two others.
# Hypothesis and algorithms for the mesh generation are global
#
>
import salome
from salome import sg
@ -149,12 +149,12 @@ mefisto2D = hypothesis._narrow(SMESH.SMESH_MEFISTO_2D)
mefistoID = smeshgui.AddNewAlgorithms( salome.orb.object_to_string(mefisto2D) )
smeshgui.SetName(mefistoID, "MEFISTO_2D")
print "-------------------------- Tetra_3D"
print "-------------------------- NETGEN_3D"
hypothesis=gen.CreateHypothesis("Tetra_3D")
tetra3D = hypothesis._narrow(SMESH.SMESH_Tetra_3D)
tetraID = smeshgui.AddNewAlgorithms( salome.orb.object_to_string(tetra3D) )
smeshgui.SetName(tetraID, "Tetra_3D")
hypothesis=gen.CreateHypothesis("NETGEN_3D")
netgen3D = hypothesis._narrow(SMESH.SMESH_NETGEN_3D)
netgenID = smeshgui.AddNewAlgorithms( salome.orb.object_to_string(netgen3D) )
smeshgui.SetName(netgenID, "NETGEN_3D")
# ---- init a Mesh with the shell
@ -175,7 +175,7 @@ ret=mesh.AddHypothesis(shell,mefisto2D)
print ret
ret=mesh.AddHypothesis(shell,hypArea)
print ret
ret=mesh.AddHypothesis(shell,tetra3D)
ret=mesh.AddHypothesis(shell,netgen3D)
print ret
ret=mesh.AddHypothesis(shell,hypVolume)
print ret
@ -184,7 +184,7 @@ smeshgui.SetAlgorithms( idmesh, regularID)
smeshgui.SetHypothesis( idmesh, idseg )
smeshgui.SetAlgorithms( idmesh, mefistoID )
smeshgui.SetHypothesis( idmesh, idarea )
smeshgui.SetAlgorithms( idmesh, tetraID )
smeshgui.SetAlgorithms( idmesh, netgenID )
smeshgui.SetHypothesis( idmesh, idvolume )
sg.updateObjBrowser(1)

View File

@ -110,12 +110,12 @@ mefisto2D = hypothesis._narrow(SMESH.SMESH_MEFISTO_2D)
mefistoID = smeshgui.AddNewAlgorithms( salome.orb.object_to_string(mefisto2D) )
smeshgui.SetName(mefistoID, "MEFISTO_2D")
print "-------------------------- Tetra_3D"
print "-------------------------- NETGEN_3D"
hypothesis=gen.CreateHypothesis("Tetra_3D")
tetra3D = hypothesis._narrow(SMESH.SMESH_Tetra_3D)
tetraID = smeshgui.AddNewAlgorithms( salome.orb.object_to_string(tetra3D) )
smeshgui.SetName(tetraID, "Tetra_3D")
hypothesis=gen.CreateHypothesis("NETGEN_3D")
netgen3D = hypothesis._narrow(SMESH.SMESH_NETGEN_3D)
netgenID = smeshgui.AddNewAlgorithms( salome.orb.object_to_string(netgen3D) )
smeshgui.SetName(netgenID, "NETGEN_3D")
# ---- init a Mesh with the boxe
@ -136,7 +136,7 @@ ret=mesh.AddHypothesis(box,mefisto2D)
print ret
ret=mesh.AddHypothesis(box,hypArea)
print ret
ret=mesh.AddHypothesis(box,tetra3D)
ret=mesh.AddHypothesis(box,netgen3D)
print ret
ret=mesh.AddHypothesis(box,hypVolume)
print ret
@ -145,7 +145,7 @@ smeshgui.SetAlgorithms( idmesh, regularID)
smeshgui.SetHypothesis( idmesh, idseg )
smeshgui.SetAlgorithms( idmesh, mefistoID )
smeshgui.SetHypothesis( idmesh, idarea )
smeshgui.SetAlgorithms( idmesh, tetraID )
smeshgui.SetAlgorithms( idmesh, netgenID )
smeshgui.SetHypothesis( idmesh, idvolume )
sg.updateObjBrowser(1)

View File

@ -203,19 +203,19 @@ print algoMef.GetId()
idMef = smeshgui.AddNewAlgorithms( salome.orb.object_to_string(algoMef) )
smeshgui.SetName( idMef, "MEFISTO_2D" )
print "-------------------------- Tetra_3D"
print "-------------------------- NETGEN_3D"
alg3D = gen.CreateHypothesis( "Tetra_3D" )
alg3D = gen.CreateHypothesis( "NETGEN_3D" )
algo3D = alg3D._narrow( SMESH.SMESH_Algo )
listHyp = algo3D.GetCompatibleHypothesis()
for hyp in listHyp:
print hyp
algoNg = alg3D._narrow( SMESH.SMESH_Tetra_3D )
algoNg = alg3D._narrow( SMESH.SMESH_NETGEN_3D )
print algoNg.GetName()
print algoNg.GetId()
idNg = smeshgui.AddNewAlgorithms( salome.orb.object_to_string(algoNg) )
smeshgui.SetName( idNg, "Tetra_2D" )
smeshgui.SetName( idNg, "NETGEN_2D" )
print "-------------------------- add hypothesis to main mechanic"
@ -226,7 +226,7 @@ ret = mesh.AddHypothesis( shape_mesh, algoReg1D ) # Regular 1D/wire discretisa
print ret
ret = mesh.AddHypothesis( shape_mesh, algoMef ) # MEFISTO 2D
print ret
ret = mesh.AddHypothesis( shape_mesh, algoNg ) # Tetra 3D
ret = mesh.AddHypothesis( shape_mesh, algoNg ) # NETGEN 3D
print ret
ret = mesh.AddHypothesis( shape_mesh, hypNbSeg ) # nb segments
print ret
@ -237,7 +237,7 @@ print ret
smeshgui.SetAlgorithms( idmesh, idReg1D ); # Regular 1D/wire discretisation
smeshgui.SetAlgorithms( idmesh, idMef ); # MEFISTO 2D
smeshgui.SetAlgorithms( idmesh, idNg ); # Tetra 3D
smeshgui.SetAlgorithms( idmesh, idNg ); # NETGEN 3D
smeshgui.SetHypothesis( idmesh, idSeg ); # nb segments
smeshgui.SetHypothesis( idmesh, idArea ); # max area
smeshgui.SetHypothesis( idmesh, idVolume ); # max volume