const TopoDS_Vertex& theVertex) const
{
const gp_Pnt aPoint = BRep_Tool::Pnt(theVertex);
- const Standard_Real aTolerance = BRep_Tool::Tolerance(theVertex);
+ const Standard_Real aTolerance = BRep_Tool::Tolerance(theVertex) * 1.1;
return (thePoint.SquareDistance (aPoint) < aTolerance * aTolerance);
}
thePoint = myDiscretTool.Value (theIndex);
theParameter = myDiscretTool.Parameter (theIndex);
- /*if (!isInToleranceOfVertex(thePoint, myFirstVertex) &&
+ if (!isInToleranceOfVertex(thePoint, myFirstVertex) &&
!isInToleranceOfVertex(thePoint, myLastVertex))
- {*/
+ {
if (!myCurve.IsCurveOnSurface())
{
return Standard_True;
aSurface->D0(aUV.X(), aUV.Y(), aPntOnSurf);
return (thePoint.SquareDistance(aPntOnSurf) < myEdgeSqTol);
- /*}
+ }
- return Standard_False;*/
+ return Standard_False;
}
//=======================================================================
--- /dev/null
+puts "========"
+puts "0031395: Mesh - BRepMesh produces poor mesh on shape with hidden self-intersections"
+puts "========"
+puts ""
+
+restore [locate_data_file log368.brep] result
+
+tclean result
+incmesh result 0.2
+
+vinit
+vsetdispmode 1
+vdefaults -autoTriang 0
+
+checkview -display result -3d -path ${imagedir}/${test_image}.png
+
+set log [tricheck result]
+if { [llength $log] != 0 } {
+ puts "Error : Invalid mesh"
+} else {
+ puts "Mesh is OK"
+}