From 09e59c70b9da521cf9f946913bd22dd2e7e62912 Mon Sep 17 00:00:00 2001 From: szy Date: Wed, 11 Dec 2013 14:46:21 +0000 Subject: [PATCH] 11.12.2013. Update Channel - 2d Shape. --- src/HYDROData/HYDROData_Channel.cxx | 47 +++++++++++++++++++++++++++-- src/HYDROGUI/HYDROGUI_Shape.cxx | 1 - 2 files changed, 45 insertions(+), 3 deletions(-) diff --git a/src/HYDROData/HYDROData_Channel.cxx b/src/HYDROData/HYDROData_Channel.cxx index 2640d5ef..bb60ed12 100644 --- a/src/HYDROData/HYDROData_Channel.cxx +++ b/src/HYDROData/HYDROData_Channel.cxx @@ -4,11 +4,15 @@ #include "HYDROData_Document.h" #include "HYDROData_Polyline3D.h" #include "HYDROData_Profile.h" +#include "HYDROData_PolylineXY.h" #include #include #include +#include #include +#include +#include //#define DEB_CHANNEL 1 #ifdef DEB_CHANNEL #include @@ -88,8 +92,8 @@ void HYDROData_Channel::Update() if ( aGuideLine.IsNull() || aProfile.IsNull() ) return; - // TODO - TopoDS_Wire aPathWire = TopoDS::Wire(aGuideLine->GetShape3D()); + // build 3d shape + TopoDS_Wire aPathWire = TopoDS::Wire(aGuideLine->GetShape3D()); if(aPathWire.IsNull()) return; TopoDS_Wire aProfileWire = TopoDS::Wire( aProfile->GetShape3D() ); @@ -115,6 +119,45 @@ void HYDROData_Channel::Update() #endif } } + + // build 2d shape -- temporary solution!! + //aMkSweep.Generated() - it seems doesn't work + //TopoDS_Vertex aV1,aV2; + //TopExp::Vertices (aProfileWire, aV1, aV2); + //const TopTools_ListOfShape& aList1 = aMkSweep.Generated(aV1); + //const TopTools_ListOfShape& aList2 = aMkSweep.Generated(aV2); + //cout <<"List1 = " << aList1.Extent() <GetShape(); setShape( aShape3D, false, false ); -- 2.39.2