mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-20 04:04:00 +00:00
Merge remote-tracking branch 'origin/v0.8.0' into datamodel-v1.0
This commit is contained in:
@@ -28,6 +28,7 @@
|
||||
#include "boolean_utils.h"
|
||||
#include "base_utils.h"
|
||||
|
||||
#include <BOPAlgo_MakerVolume.hxx>
|
||||
#include <BRepPrimAPI_MakeRevol.hxx>
|
||||
|
||||
namespace {
|
||||
@@ -136,7 +137,20 @@ bool IfcGeom::OpenCascadeKernel::convert_openings(const express::Base& entity, c
|
||||
bool is_manifold = util::is_manifold(entity_part);
|
||||
|
||||
if (!is_manifold) {
|
||||
logger::warning("Non-manifold first operand");
|
||||
if (settings_.get<settings::MakeVolume>().get()) {
|
||||
BOPAlgo_MakerVolume mv;
|
||||
mv.AddArgument(entity_part);
|
||||
mv.Perform();
|
||||
if (mv.HasErrors()) {
|
||||
logger::warning("Non-manifold first operand, --make-volume failed");
|
||||
} else {
|
||||
entity_part = mv.Shape();
|
||||
is_manifold = util::is_manifold(entity_part);
|
||||
}
|
||||
}
|
||||
if (!is_manifold) {
|
||||
logger::warning("Non-manifold first operand, use --make-volume to try and make manifold");
|
||||
}
|
||||
}
|
||||
|
||||
TopoDS_Shape entity_part_result;
|
||||
@@ -1363,4 +1377,4 @@ bool IfcGeom::OpenCascadeKernel::convert_impl(const taxonomy::revolve::ptr r, If
|
||||
// if (IfcGeom::util::apply_layerset(r, const std::vector<ifcopenshell::geometry::taxonomy::style>&, ConversionResults& r2, double tol)) {
|
||||
// std::swap(r, r2)
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
Reference in New Issue
Block a user