diff --git a/libsrc/meshing/adfront2.cpp b/libsrc/meshing/adfront2.cpp index 5a9b6cab..a915d71f 100644 --- a/libsrc/meshing/adfront2.cpp +++ b/libsrc/meshing/adfront2.cpp @@ -282,7 +282,7 @@ namespace netgen NgArray & lindex, double xh) { - static Timer timer("adfront2::GetLocals"); RegionTimer reg (timer); + // static Timer timer("adfront2::GetLocals"); RegionTimer reg (timer); int pstind; Point<3> midp, p0; diff --git a/libsrc/meshing/adfront2.hpp b/libsrc/meshing/adfront2.hpp index a6364827..497580ca 100644 --- a/libsrc/meshing/adfront2.hpp +++ b/libsrc/meshing/adfront2.hpp @@ -171,21 +171,21 @@ class AdFront2 { /// - NgArray points; /// front points - NgArray lines; /// front lines + Array points; /// front points + Array lines; /// front lines Box3d boundingbox; BoxTree<3> linesearchtree; /// search tree for lines Point3dTree pointsearchtree; /// search tree for points Point3dTree cpointsearchtree; /// search tree for cone points (not used ???) - NgArray delpointl; /// list of deleted front points - NgArray dellinel; /// list of deleted front lines + Array delpointl; /// list of deleted front points + Array dellinel; /// list of deleted front lines int nfl; /// number of front lines; INDEX_2_HASHTABLE * allflines; /// all front lines ever have been - NgArray invpindex; + Array invpindex; int minval; int starti; diff --git a/libsrc/meshing/adfront3.hpp b/libsrc/meshing/adfront3.hpp index b0acff20..021c364f 100644 --- a/libsrc/meshing/adfront3.hpp +++ b/libsrc/meshing/adfront3.hpp @@ -184,7 +184,8 @@ class AdFront3 { /// // NgArray points; - Array points; + Array points +; /// NgArray faces; /// diff --git a/libsrc/meshing/meshing2.cpp b/libsrc/meshing/meshing2.cpp index 69aeffac..02f53d7e 100644 --- a/libsrc/meshing/meshing2.cpp +++ b/libsrc/meshing/meshing2.cpp @@ -246,8 +246,8 @@ namespace netgen { static Timer timer("surface meshing"); RegionTimer reg(timer); - static int timer1 = NgProfiler::CreateTimer ("surface meshing1"); - static int timer2 = NgProfiler::CreateTimer ("surface meshing2"); + static Timer timer1("surface meshing1"); + static Timer timer2("surface meshing2"); static int timer3 = NgProfiler::CreateTimer ("surface meshing3"); static int ts1 = NgProfiler::CreateTimer ("surface meshing start 1"); @@ -408,7 +408,7 @@ namespace netgen RegionTimer rloop(tloop); while (!adfront.Empty() && !multithread.terminate) { - NgProfiler::RegionTimer reg1 (timer1); + // RegionTimer reg1 (timer1); if (multithread.terminate) throw NgException ("Meshing stopped"); @@ -487,8 +487,7 @@ namespace netgen pindex, lindex, 2*hinner); // tgetlocals.Stop(); - NgProfiler::RegionTimer reg2 (timer2); - + // RegionTimer reg2 (timer2); //(*testout) << "h for locals: " << 2*hinner << endl; @@ -557,7 +556,7 @@ namespace netgen oldnl = loclines.Size(); UpdateVisSurfaceMeshData(oldnl); - + if (debugflag) (*testout) << "define new transformation" << endl; @@ -574,15 +573,16 @@ namespace netgen *testout << "3d points: " << endl << locpoints << endl; } - - for (size_t i = 0; i < locpoints.Size(); i++) - { - Point<2> pp; - TransformToPlain (locpoints[i], mpgeominfo[i], - pp, h, plainzones[i]); - plainpoints[i] = pp; - } - + { + // RegionTimer reg2 (timer2); + for (size_t i = 0; i < locpoints.Size(); i++) + { + Point<2> pp; + TransformToPlain (locpoints[i], mpgeominfo[i], + pp, h, plainzones[i]); + plainpoints[i] = pp; + } + } /* for (int i = 1; i <= locpoints.Size(); i++) { @@ -633,7 +633,6 @@ namespace netgen // plainpoints.Elem(i) = Point2d (1e4, 1e4); */ - for (int i = 2; i <= loclines.Size(); i++) // don't remove first line { diff --git a/libsrc/meshing/paralleltop.hpp b/libsrc/meshing/paralleltop.hpp index b0ea76ba..8c180176 100644 --- a/libsrc/meshing/paralleltop.hpp +++ b/libsrc/meshing/paralleltop.hpp @@ -102,30 +102,30 @@ namespace netgen - [[deprecated("Use GetDistantPNums(locnum).Size() instead!")]] + // [[deprecated("Use GetDistantPNums(locnum).Size() instead!")]] int GetNDistantPNums (int locpnum) const { return loc2distvert[locpnum-1].Size(); } - [[deprecated("Use GetDistantFaceNums(locnum).Size() instead!")]] + // [[deprecated("Use GetDistantFaceNums(locnum).Size() instead!")]] int GetNDistantFaceNums (int locfacenum) const { return loc2distface[locfacenum-1].Size(); } - [[deprecated("Use GetDistantEdgeNums(locnum).Size() instead!")]] + // [[deprecated("Use GetDistantEdgeNums(locnum).Size() instead!")]] int GetNDistantEdgeNums ( int locedgenum) const { return loc2distedge[locedgenum-1].Size(); } - [[deprecated("Use GetDistantPNums(locnum) -> FlatArray instead!")]] + // [[deprecated("Use GetDistantPNums(locnum) -> FlatArray instead!")]] void GetDistantPNums (int locpnum, int * distpnums ) const { for (int i = 0; i < loc2distvert[locpnum-1].Size(); i++ ) distpnums[i] = loc2distvert[locpnum-1][i]; } - [[deprecated("Use GetDistantFaceNums(locnum) -> FlatArray instead!")]] + // [[deprecated("Use GetDistantFaceNums(locnum) -> FlatArray instead!")]] void GetDistantFaceNums (int locfacenum, int * distfacenums ) const { for ( int i = 0; i < loc2distface[locfacenum-1].Size(); i++ ) distfacenums[i] = loc2distface[locfacenum-1][i]; } - [[deprecated("Use GetDistantFaceNums(locnum) -> FlatArray instead!")]] + // [[deprecated("Use GetDistantFaceNums(locnum) -> FlatArray instead!")]] void GetDistantFaceNums (int locfacenum, NgArray & distfacenums ) const { // distfacenums = loc2distface[locfacenum-1]; @@ -135,14 +135,14 @@ namespace netgen distfacenums[i] = loc[i]; } - [[deprecated("Use GetDistantEdgeNums(locnum) -> FlatArray instead!")]] + // [[deprecated("Use GetDistantEdgeNums(locnum) -> FlatArray instead!")]] void GetDistantEdgeNums (int locedgenum, int * distedgenums ) const { for (int i = 0; i < loc2distedge[locedgenum-1].Size(); i++ ) distedgenums[i] = loc2distedge[locedgenum-1][i]; } - [[deprecated("Use GetDistantEdgeNums(locnum) -> FlatArray instead!")]] + // [[deprecated("Use GetDistantEdgeNums(locnum) -> FlatArray instead!")]] void GetDistantEdgeNums (int locedgenum, NgArray & distedgenums ) const { // distedgenums = loc2distedge[locedgenum-1]; diff --git a/libsrc/occ/occmeshsurf.cpp b/libsrc/occ/occmeshsurf.cpp index 812ef03c..37f23cfc 100644 --- a/libsrc/occ/occmeshsurf.cpp +++ b/libsrc/occ/occmeshsurf.cpp @@ -296,6 +296,8 @@ namespace netgen Point<2> & pplane, double h, int & zone) const { + // static Timer t("ToPlane"); RegionTimer reg(t); + if (projecttype == PLANESPACE) { Vec<3> p1p, n; @@ -338,7 +340,7 @@ namespace netgen PointGeomInfo & gi, double h) { - static Timer t("FromPlane"); RegionTimer reg(t); + // static Timer t("FromPlane"); RegionTimer reg(t); if (projecttype == PLANESPACE) { @@ -364,8 +366,8 @@ namespace netgen void OCCSurface :: Project (Point<3> & ap, PointGeomInfo & gi) { - static Timer t("OccSurface::Project"); RegionTimer reg(t); - static Timer t2("OccSurface::Project actual"); + // static Timer t("OccSurface::Project"); RegionTimer reg(t); + // static Timer t2("OccSurface::Project actual"); // try Newton's method ... @@ -470,13 +472,14 @@ namespace netgen */ // double u,v; + // JS : shouldn't we move these 2 lines to the constructor ? Handle( ShapeAnalysis_Surface ) su = new ShapeAnalysis_Surface( occface ); auto toltool = BRep_Tool::Tolerance( topods_face ); // gp_Pnt2d suval = su->ValueOfUV ( pnt, toltool); - t2.Start(); + // t2.Start(); gp_Pnt2d suval = su->NextValueOfUV (gp_Pnt2d(u,v), pnt, toltool); - t2.Stop(); + // t2.Stop(); suval.Coord( u, v); pnt = occface->Value( u, v );