Author: janehu Date: 2011-07-21 11:18:05 -0500 (Thu, 21 Jul 2011) New Revision: 5066 Modified: cgm/trunk/geom/OCC/OCCModifyEngine.cpp cgm/trunk/geom/OCC/OCCQueryEngine.cpp cgm/trunk/geom/OCC/OCCQueryEngine.hpp Log: Changed unite function to correctly check bounding box intersection, and supporting other code change. Improved rgg/assygen for 7.inp from 3173s to 104 seconds. Passed make check for cgm. Modified: cgm/trunk/geom/OCC/OCCModifyEngine.cpp =================================================================== --- cgm/trunk/geom/OCC/OCCModifyEngine.cpp 2011-07-19 17:57:32 UTC (rev 5065) +++ cgm/trunk/geom/OCC/OCCModifyEngine.cpp 2011-07-21 16:18:05 UTC (rev 5066) @@ -2195,6 +2195,7 @@ //indicate if there's more faces to be imprinted CubitBoolean more_face = CUBIT_TRUE; DLIList<TopoDS_Face*> list_for_delete; + CubitBoolean face_created = CUBIT_FALSE; //list of face on from_shape that has been imprinted DLIList<TopoDS_Face*> from_faces; @@ -2409,7 +2410,10 @@ face = (OCCSurface*)(OCCQueryEngine::instance()->OccToCGM->find(i))->second; } else + { + face_created = CUBIT_TRUE; face = OCCQueryEngine::instance()->populate_topology_bridge(from_face); + } OCCSurface* occ_face = CAST_TO(face, OCCSurface); DLIList<Curve*> common_curves; @@ -2494,6 +2498,7 @@ CubitVector point_on_surf; occ_face->closest_point_trimmed(p, point_on_surf); + if(p.distance_between(point_on_surf) > TOL) //edge not on from_face { skipped = CUBIT_TRUE; @@ -2553,7 +2558,7 @@ added = CUBIT_TRUE; curve_list.append(curve); } - } + } if(added) { topo_changed = CUBIT_TRUE; @@ -2591,7 +2596,12 @@ } } } - + + if(face_created) + { + OCCQueryEngine::instance()->delete_solid_model_entities(occ_face); + face_created = CUBIT_FALSE; + }
participants (1)
-
jiangtao_ma@yahoo.com