[cgma-dev] r4081 - cgm/trunk/geom/OCC
jiangtao_ma at yahoo.com
jiangtao_ma at yahoo.com
Wed Aug 11 12:50:09 CDT 2010
Author: janehu
Date: 2010-08-11 12:50:09 -0500 (Wed, 11 Aug 2010)
New Revision: 4081
Modified:
cgm/trunk/geom/OCC/OCCModifyEngine.cpp
Log:
make sure modify.cpp still works.
Modified: cgm/trunk/geom/OCC/OCCModifyEngine.cpp
===================================================================
--- cgm/trunk/geom/OCC/OCCModifyEngine.cpp 2010-08-11 17:43:49 UTC (rev 4080)
+++ cgm/trunk/geom/OCC/OCCModifyEngine.cpp 2010-08-11 17:50:09 UTC (rev 4081)
@@ -3508,17 +3508,18 @@
BRepAlgoAPI_Common intersector(*from_shape, *tool_shape);
TopTools_ListOfShape shapes;
shapes.Assign(intersector.Modified(*tool_shape));
- if (shapes.IsEmpty())
- {
- PRINT_INFO("The %d body did not have common part with the tool_body.\n", i+1);
- continue;
- }
+
if ( shapes.Extent() > 1)
{
PRINT_ERROR("Tool has multiple intersection with the shape, make it simpler. \n");
continue;
}
- TopoDS_Shape common_shape = shapes.First();
+ TopoDS_Shape common_shape;
+ if (shapes.IsEmpty())
+ common_shape = intersector.Shape();
+ else
+ common_shape = shapes.First();
+
if (is_volume[i] == CUBIT_TRUE &&
(common_shape.TShape()->ShapeType() == TopAbs_SHELL ||
common_shape.TShape()->ShapeType() == TopAbs_FACE ||
More information about the cgma-dev
mailing list