From a26c9ebd557270bc95edaa79c8e67c59cee43cd7 Mon Sep 17 00:00:00 2001 From: mattijs <mattijs> Date: Mon, 10 Jun 2013 11:27:20 +0100 Subject: [PATCH] ENH: surfaceCheck: new self-intersection test --- .../surface/surfaceCheck/surfaceCheck.C | 30 +++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/applications/utilities/surface/surfaceCheck/surfaceCheck.C b/applications/utilities/surface/surfaceCheck/surfaceCheck.C index a0170559584..29707e303c5 100644 --- a/applications/utilities/surface/surfaceCheck/surfaceCheck.C +++ b/applications/utilities/surface/surfaceCheck/surfaceCheck.C @@ -653,6 +653,36 @@ int main(int argc, char *argv[]) Info<< "Checking self-intersection." << endl; triSurfaceSearch querySurf(surf); + + //{ + // OBJstream intStream("selfInter2.obj"); + // const indexedOctree<treeDataTriSurface>& tree = querySurf.tree(); + // forAll(surf.edges(), edgeI) + // { + // const edge& e = surf.edges()[edgeI]; + // + // pointIndexHit hitInfo + // ( + // tree.findLine + // ( + // surf.points()[surf.meshPoints()[e[0]]], + // surf.points()[surf.meshPoints()[e[1]]], + // treeDataTriSurface::findSelfIntersectOp + // ( + // tree, + // edgeI + // ) + // ) + // ); + // + // if (hitInfo.hit()) + // { + // Pout<< "Found hit:" << hitInfo.hitPoint() << endl; + // intStream.write(hitInfo.hitPoint()); + // } + // } + //} + surfaceIntersection inter(querySurf); if (inter.cutEdges().empty() && inter.cutPoints().empty()) -- GitLab