
Thu, 07/03/2025 - 10:11
Forums:
Does "solid" in OCC correspond to "body"?
If I traverse the Solids under a Shape, and then iterate through the Faces within each Solid, will that give me all the Faces?
I tried doing this, but the Faces I obtained were only a subset.
Thu, 07/03/2025 - 19:25
From Training: Topology -
TopoDS_Solid
is a collection ofTopoDS_Shell
, andTopoDS_Shell
is a collection ofTopoDS_Face
.The 'body' from other kernels might have different type - closed solid (can be roughly mapped to
TopoDS_Solid
), open sheet (can be mapped toTopoDS_Shell
, which is not inside of aTopoDS_Solid
), acorn (corresponds toTopoDS_Vertex
which is not part of anyTopoDS_Edge
).The simplest Solid like a sphere will consist of one Shell and 1+ Faces. The Solid with inner hole parts (imagine a small sphere cut from a larger box) will consists of one outer Shell and 1+ inner hole Shells.
There are different ways to traverse topology in OCCT. Please share some sample shape, code snippet and why you think you get unexpected result.
Mon, 07/07/2025 - 06:26
Thanks for your answer.
Here is my code snippet.
This TopoShape comes from a STEP file, maybe some problem about map in present code. I find that so many faces isn't in solids. I don't know how to correctly traverse and store these structures.
Mon, 07/07/2025 - 06:27
my data structrue is Body Face Loop Edge Vertex