Added '--strict-tolerance' option

This commit is contained in:
Jesse Vander Does
2021-02-06 10:26:17 -06:00
committed by Thomas Krijnen
parent 10f4bca5d2
commit 4ea95960a2
6 changed files with 22 additions and 5 deletions
+6 -1
View File
@@ -350,7 +350,7 @@ namespace IfcGeom {
if (any_precision_encountered) {
// Some arbitrary factor that has proven to work better for the models in the set of test files.
lowest_precision_encountered *= 10.;
lowest_precision_encountered *= kernel.getValue(IfcGeom::Kernel::GV_PRECISION_FACTOR);
lowest_precision_encountered *= unit_magnitude;
if (lowest_precision_encountered < 1.e-7) {
@@ -1008,6 +1008,11 @@ namespace IfcGeom {
? +1.0
: -1.0
);
kernel.setValue(IfcGeom::Kernel::GV_PRECISION_FACTOR,
settings.get(IteratorSettings::STRICT_TOLERANCE)
? 1.0
: 10.0
);
kernel.setValue(IfcGeom::Kernel::GV_DISABLE_BOOLEAN_RESULT,
settings.get(IteratorSettings::DISABLE_BOOLEAN_RESULT)