Fem: Enable checkbox for references mesh groups - fixes #10071 (#12437)

This commit is contained in:
marioalexis84
2024-02-24 13:29:00 -03:00
committed by GitHub
parent 628bad452a
commit 4932f17dc5
2 changed files with 8 additions and 6 deletions

View File

@@ -273,13 +273,13 @@
<item row="0" column="0">
<widget class="Gui::PrefCheckBox" name="cb_analysis_group_meshing">
<property name="enabled">
<bool>false</bool>
<bool>true</bool>
</property>
<property name="text">
<string>Create mesh groups for analysis reference shapes (highly experimental)</string>
</property>
<property name="checked">
<bool>true</bool>
<bool>false</bool>
</property>
<property name="prefEntry" stdset="0">
<cstring>AnalysisGroupMeshing</cstring>

View File

@@ -1666,10 +1666,12 @@ def get_pressure_obj_faces(
# How to find the orientation of a FEM mesh face?
# https://forum.freecad.org/viewtopic.php?f=18&t=51898
else:
FreeCAD.Console.PrintError(
"Pressure on shell mesh at the moment only "
"supported for meshes with appropriate group data.\n"
)
for sh, elems in femobj["Object"].References:
for e in elems:
meshfaces = femmesh.getFacesByFace(sh.getSubObject(e))
for mf in meshfaces:
pressure_faces.append([mf, -1])
return pressure_faces