Skip to content

Commit

Permalink
do not mesh if incompatible
Browse files Browse the repository at this point in the history
  • Loading branch information
jginternational committed May 29, 2024
1 parent 413aa02 commit 51cb2c9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion kratos.gid/kratos.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,9 @@ proc Kratos::Event_BeforeMeshGeneration {elementsize} {
}

# Change the mesh settings depending on the element requirements
catch {Kratos::CheckMeshCriteria $elementsize}
if {[Kratos::CheckMeshCriteria $elementsize]<0} {
return "-cancel-"
}

# Maybe the current application needs to do some extra job
set ret [apps::ExecuteOnCurrentApp BeforeMeshGeneration $elementsize]
Expand Down
3 changes: 2 additions & 1 deletion kratos.gid/scripts/Utils.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,8 @@ proc Kratos::CheckMeshCriteria { elementsize } {
} else {
if {$forced_mesh_order ne $element_forces} {
# W "The element $element_id requires a different mesh order"
error "Incompatible mesh orders in elements"
W "Incompatible mesh orders in elements"
return -1
}
}
}
Expand Down

0 comments on commit 51cb2c9

Please sign in to comment.