mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-09 17:31:45 +00:00
Clarify Compound of Solids behaviour in create_solid_from_faces() #6780
This commit is contained in:
@@ -45,6 +45,8 @@ namespace IfcGeom {
|
||||
|
||||
bool is_nested_compound_of_solid(const TopoDS_Shape& s, int depth = 0);
|
||||
|
||||
// Creates a solid from a compound of faces. When there are multiple connected components,
|
||||
// a compound of solids is returned.
|
||||
bool create_solid_from_compound(const TopoDS_Shape& compound, TopoDS_Shape& solid, double tol);
|
||||
bool shape_to_face_list(const TopoDS_Shape& s, TopTools_ListOfShape& li);
|
||||
bool create_solid_from_faces(const TopTools_ListOfShape& face_list, TopoDS_Shape& solid, double tol, bool force_sewing = false);
|
||||
|
||||
@@ -1451,10 +1451,10 @@ TopoDS_Shape IfcGeom::util::ensure_fit_for_subtraction(const TopoDS_Shape& shape
|
||||
return shape;
|
||||
}
|
||||
|
||||
TopoDS_Solid solid;
|
||||
if (!create_solid_from_compound(shape, solid, tol)) {
|
||||
TopoDS_Shape solid_or_compound_of_solids;
|
||||
if (!create_solid_from_compound(shape, solid_or_compound_of_solids, tol)) {
|
||||
return shape;
|
||||
}
|
||||
|
||||
return solid;
|
||||
return solid_or_compound_of_solids;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user