Archived issue #0031421

OCCT:Mesh: SelfIntersectingWire Failure.

Open CASCADEOCCT:Meshfeedback3 public notes

Search issues

Description

Attempt to save a valid face using Draw command 'writestl' gives the next error message:
"** Error **: Mesh writing has been failed."

The face contains 2 wires: bounding wire and one internal wire (it gives the face
with a hole).
Minimal distance between wires = 0.40121902464126269

Steps to reproduce

pload ALL
stepread simplified_part.stp s *
## Transferrable Roots : Nb entities selected : 1
## Transfer entity n0 601 OK -> DRAW Shape: s_1

nexplode s_1 F
checkshape s_1_241
writestl s_1_241 f241
** Error **: Mesh writing has been failed.
## additional check with incmesh
incmesh s_1_241 0.1
## Incremental Mesh, multi-threading OFF
## Meshing statuses: SelfIntersectingWire Failure


Public activity

3 archived notes

Participants are labeled by their role within this record.

01Commenter 1
Hi Sergey,

thank you for the case with self-intersections, it would be useful for #0024084.
However, reported issue is not a case in context of BRepMesh.

writestl is actually not a part of TKMesh component which OCCT:Mesh category is related to, but OCCT:DataExchange as far as it uses TKSTL API directly from that package.

Here, I would like to suggest to split this issue on two (or probably three) issues:

- First, to fix initial problem, report new issue (or move existing one) in OCCT:DataExchange category so TKSTL could produce *.stl files despite of existence of faces with corrupted triangulations (e.g. only for faces where tricheck reports no error, or for all faces that have triangulation even totally corrupted, with gaps, isolated nodes, cross-face errors, etc.);

- Second, report new issue for OCCT:Mesh in order to improve BRepMesh so it would handle issues with self-intersections (while even fixshape would not fix it);

- Third (optionally), report new issue in OCCT:ShapeHealing category to investigate possibility of resolving cases leading to self-intersections on discrete model, e.g. notched edges, possibly real self-intersections (that could be replaced by simplified geometry within defined tolerance) covered by huge tolerance ~ 3 while max size of BB is ~ 387. Note that bopargcheck raises "Faulties, that can not be treated by BOP, are detected." while checkshape says "This shape seems to be valid".

Here is the detail report of bopargcheck:
Faulties for FIRST shape found : 888
---------------------------------
Shapes are not suppotrted by BOP: NO
Self-Intersections : YES Cases(7) Total shapes(14)
Check for SI has been aborted : NO
Too small edges : NO
Bad faces : NO
Too close vertices : DISABLED
Too close edges : DISABLED
Shapes with Continuity C0 : YES Cases(257) Total shapes(257)
Invalid Curve on Surface : YES Cases(624) Total shapes(1248)

02Commenter 2
In fact it is mesher problem.
Meshing statuses: SelfIntersectingWire Failure.
See the attached archive Attachment 1 (7Z) with picture.
03Commenter 1
In fact, it is not.
Please read my previous message carefully.

The cause of the problem is self-intersecting wire, which is not the matter to be solved by BRepMesh if it could not have been solved by fixshape.

Related records