Use a precise bnd box to find the shape diagonal
${CAS_TKG2d}
${CAS_TKCDF}
${GEOM_NMTTools}
${CAS_TKG2d}
${CAS_TKCDF}
${GEOM_NMTTools}
${Boost_LIBRARIES}
SMESHDS
SMESHControls
${Boost_LIBRARIES}
SMESHDS
SMESHControls
#include "DriverCGNS_Write.hxx"
#endif
#include "DriverCGNS_Write.hxx"
#endif
+#include <GEOMUtils.hxx>
+
#undef _Precision_HeaderFile
#undef _Precision_HeaderFile
-#include <BRepBndLib.hxx>
+//#include <BRepBndLib.hxx>
#include <BRepPrimAPI_MakeBox.hxx>
#include <Bnd_Box.hxx>
#include <TColStd_MapOfInteger.hxx>
#include <BRepPrimAPI_MakeBox.hxx>
#include <Bnd_Box.hxx>
#include <TColStd_MapOfInteger.hxx>
{
if ( !aShape.IsNull() ) {
Bnd_Box Box;
{
if ( !aShape.IsNull() ) {
Bnd_Box Box;
- BRepBndLib::Add(aShape, Box);
+ GEOMUtils::PreciseBoundingBox(aShape, Box);
return sqrt( Box.SquareExtent() );
}
return 0;
return sqrt( Box.SquareExtent() );
}
return 0;
// get worse?
if ( nbOkAfter < nbOkBefore )
continue;
// get worse?
if ( nbOkAfter < nbOkBefore )
continue;
- if (( isConcaveFace ) &&
+ if (( isConcaveFace || findBest ) &&
( nbOkAfter == nbOkBefore ) &&
//( iFun > -1 || nbOkAfter < _simplices.size() ) &&
( minVolAfter <= minVolBefore ))
( nbOkAfter == nbOkBefore ) &&
//( iFun > -1 || nbOkAfter < _simplices.size() ) &&
( minVolAfter <= minVolBefore ))