X-Git-Url: http://git.dev.opencascade.org/gitweb/?p=occt.git;a=blobdiff_plain;f=samples%2Focafsamples%2FTNaming_Sample.cxx;h=fbfcfbde093de2d091ec7b89f239a1e02a33001d;hp=0a0c077b5bc7307621b1cd6919eed7ab97d7da1f;hb=HEAD;hpb=480bf81e375613c9ffc4473fb976b0d0323f7e1d diff --git a/samples/ocafsamples/TNaming_Sample.cxx b/samples/ocafsamples/TNaming_Sample.cxx index 0a0c077b5b..1a6320be9d 100644 --- a/samples/ocafsamples/TNaming_Sample.cxx +++ b/samples/ocafsamples/TNaming_Sample.cxx @@ -26,12 +26,10 @@ #include #include -#include - #include #include -#include +#include #include #include @@ -305,10 +303,10 @@ void Sample() ToolSelector.Select(Tool, Tool); const TopoDS_Shape& TOOL = ToolSelector.NamedShape()->Get(); - BRepAlgo_Cut mkCUT (OBJECT, TOOL); + BRepAlgoAPI_Cut mkCUT (OBJECT, TOOL); if (!mkCUT.IsDone()) { - cout << "CUT: Algorithm failed" << endl; + std::cout << "CUT: Algorithm failed" << std::endl; return; } else { @@ -318,7 +316,7 @@ void Sample() if (!BRepAlgo::IsValid(Larg, mkCUT.Shape(), Standard_True, Standard_False)) { - cout << "CUT: Result is not valid" << endl; + std::cout << "CUT: Result is not valid" << std::endl; return; } else { @@ -365,8 +363,7 @@ void Sample() // push in the DF section edges TNaming_Builder IntersBuilder(Intersections); - Handle(TopOpeBRepBuild_HBuilder) build = mkCUT.Builder(); - TopTools_ListIteratorOfListOfShape its = build->Section(); + TopTools_ListIteratorOfListOfShape its(mkCUT.SectionEdges()); for (; its.More(); its.Next()) { // TNaming_Evolution == SELECTED IntersBuilder.Select(its.Value(),its.Value());