]> Creatis software - creaVtk.git/commitdiff
#3489 Bug exampleVoiMPR
authorEduardo DAVILA <davila@creatis.insa-lyon.fr>
Tue, 12 Jul 2022 09:37:35 +0000 (11:37 +0200)
committerEduardo DAVILA <davila@creatis.insa-lyon.fr>
Tue, 12 Jul 2022 09:37:35 +0000 (11:37 +0200)
bbtk_creaVtk_PKG/bbs/appli/exampleVoiMPR.bbg
bbtk_creaVtk_PKG/bbs/appli/exampleVoiMPR.bbs
bbtk_creaVtk_PKG/src/bbcreaVtkPointPicker.cxx
bbtk_creaVtk_PKG/src/bbcreaVtkPolyDataNormals.cxx

index 6a221e9c4397507641a020548d47d53d914c1a7e..03a6572b580cfd5de8de083d877cf88ca16a8091 100644 (file)
@@ -1,6 +1,6 @@
 # ----------------------------------
-# - BBTKGEditor v 1.4 BBG BlackBox Diagram file
-# - /home/davila/Creatis/C8/creatools_source/creaVtk/bbtk_creaVtk_PKG/bbs/appli/exampleVoiMPR.bbg
+# - BBTKGEditor v 1.5 BBG BlackBox Diagram file
+# - /Users/davila/Borrame/tmpMPR-VOI/exampleVoiMPR.bbg
 # ----------------------------------
 
 APP_START
@@ -9,34 +9,70 @@ DESCRIPTION:Description ??
 AUTHOR:Author ??
 COMPLEXBOX:FALSE
 COMPLEXINPUTS:0
-BOXES:4
+BOXES:9
 BOX
 creaVtk:VoiMPR-Widget:Box00
 ISEXEC:FALSE
--21.477436:-25.903727:-900.000000
-19.722564:-35.903727:-900.000000
+-8.107633:8.516154:-900.000000
+14.007367:6.016154:-900.000000
 FIN_BOX
 BOX
 vtk:LoadHola:Box01
 ISEXEC:FALSE
--31.631200:58.927159:-900.000000
-3.918800:48.927159:-900.000000
+-0.355957:31.529666:-900.000000
+21.194043:29.029666:-900.000000
 FIN_BOX
 BOX
 creaMaracasVisu:ViewerNV:Box02
 ISEXEC:FALSE
-17.822656:30.988942:-900.000000
-81.542656:20.988942:-900.000000
+16.224594:23.943328:-900.000000
+54.824594:21.443328:-900.000000
 FIN_BOX
 BOX
 wx:LayoutSplit:Box03
 ISEXEC:TRUE
-12.006697:-66.365397:-900.000000
-51.086697:-76.365397:-900.000000
+8.404688:-32.768923:-900.000000
+31.164688:-35.268923:-900.000000
 PORT
 Orientation:"H"
 FIN_BOX
-CONNECTIONS:10
+BOX
+wx:OutputText:Box06
+ISEXEC:FALSE
+-51.831434:-2.066196:-900.000000
+-30.161434:-4.566196:-900.000000
+PORT
+Title:"Voi"
+FIN_BOX
+BOX
+wx:LayoutSplit:Box07
+ISEXEC:FALSE
+-12.618871:-26.334476:-900.000000
+10.141129:-28.834476:-900.000000
+FIN_BOX
+BOX
+wx:LayoutLine:Box08
+ISEXEC:FALSE
+-39.262550:-18.560420:-900.000000
+-5.942550:-21.060420:-900.000000
+FIN_BOX
+BOX
+wx:OutputText:Box09
+ISEXEC:FALSE
+-36.513006:-5.799467:-900.000000
+-14.843006:-8.299467:-900.000000
+PORT
+Title:"Index"
+FIN_BOX
+BOX
+wx:OutputText:Box10
+ISEXEC:FALSE
+-21.971069:-9.692166:-900.000000
+-0.301069:-12.192166:-900.000000
+PORT
+Title:"Size"
+FIN_BOX
+CONNECTIONS:18
 CONNECTION
 Box01:Out:Box00:image
 NumberOfControlPoints:0
@@ -59,12 +95,36 @@ CONNECTION
 Box02:Renderer4:Box00:RenderXY
 NumberOfControlPoints:0
 CONNECTION
-Box02:wxVtkBaseView1:Box00:wxVtkBaseView
+Box02:Widget:Box03:Widget2
 NumberOfControlPoints:0
 CONNECTION
-Box02:Widget:Box03:Widget2
+Box00:Voi:Box06:In
+NumberOfControlPoints:0
+CONNECTION
+Box06:Widget:Box08:Widget1
+NumberOfControlPoints:0
+CONNECTION
+Box08:Widget:Box07:Widget2
+NumberOfControlPoints:0
+CONNECTION
+Box00:Widget:Box07:Widget1
+NumberOfControlPoints:0
+CONNECTION
+Box07:Widget:Box03:Widget1
+NumberOfControlPoints:0
+CONNECTION
+Box00:index:Box09:In
+NumberOfControlPoints:0
+CONNECTION
+Box00:boxchangeInterface:Box08:BoxExecute
+NumberOfControlPoints:0
+CONNECTION
+Box00:size:Box10:In
+NumberOfControlPoints:0
+CONNECTION
+Box10:Widget:Box08:Widget3
 NumberOfControlPoints:0
 CONNECTION
-Box00:Widget:Box03:Widget1
+Box09:Widget:Box08:Widget2
 NumberOfControlPoints:0
 APP_END
index 234dab1eb82288efecefcc8b05babcf7138179fb..0729ff830ea429c2ca07a12828e45e3523eb1898 100644 (file)
@@ -1,6 +1,6 @@
 # ----------------------------------
-# - BBTKGEditor v 1.4 BBS BlackBox Script
-# - /home/davila/Creatis/C8/creatools_source/creaVtk/bbtk_creaVtk_PKG/bbs/appli/exampleVoiMPR.bbs
+# - BBTKGEditor v 1.5 BBS BlackBox Script
+# - /Users/davila/Borrame/tmpMPR-VOI/exampleVoiMPR.bbs
 # ----------------------------------
 
 # BBTK GEditor Script
@@ -26,6 +26,19 @@ new creaMaracasVisu:ViewerNV Box02
 new wx:LayoutSplit Box03
   set Box03.Orientation "H"
 
+new wx:OutputText Box06
+  set Box06.Title "Voi"
+
+new wx:LayoutSplit Box07
+
+new wx:LayoutLine Box08
+
+new wx:OutputText Box09
+  set Box09.Title "Index"
+
+new wx:OutputText Box10
+  set Box10.Title "Size"
+
 
 connect Box01.Out Box00.image
 
@@ -41,11 +54,27 @@ connect Box02.Renderer3 Box00.RenderXZ
 
 connect Box02.Renderer4 Box00.RenderXY
 
-connect Box02.wxVtkBaseView1 Box00.wxVtkBaseView
-
 connect Box02.Widget Box03.Widget2
 
-connect Box00.Widget Box03.Widget1
+connect Box00.Voi Box06.In
+
+connect Box06.Widget Box08.Widget1
+
+connect Box08.Widget Box07.Widget2
+
+connect Box00.Widget Box07.Widget1
+
+connect Box07.Widget Box03.Widget1
+
+connect Box00.index Box09.In
+
+connect Box00.boxchangeInterface Box08.BoxExecute
+
+connect Box00.size Box10.In
+
+connect Box10.Widget Box08.Widget3
+
+connect Box09.Widget Box08.Widget2
 
 
 
index 71fbe7ef000a4d14d5dc437c0d6a932bcadf4594..3d71c086809a59cfda0334da4ada5e4a2868acfa 100644 (file)
@@ -28,7 +28,6 @@ void creaVtkCallbackPointPicker::setBox(PointPicker *box)
 
 void creaVtkCallbackPointPicker::Execute(vtkObject *caller, unsigned long, void*)
 {
-    printf("EED creaVtkCallbackPointPicker::Execute Start\n");
        if (boxPointPicker!=NULL)
        {
                if (boxPointPicker->bbGetInputActive()==true)
@@ -54,7 +53,6 @@ void creaVtkCallbackPointPicker::Execute(vtkObject *caller, unsigned long, void*
                 boxPointPicker->bbSetOutputPoint( vecPoint );
                 boxPointPicker->bbSetOutputMesh( picker->GetProp3D() );
                 boxPointPicker->bbSetOutputPointId( picker->GetPointId() );
-                printf("EED creaVtkCallbackPointPicker::Execute PointId %ld\n", picker->GetPointId() );
 
                 boxPointPicker->bbSetOutputCellId( picker->GetCellId() );
                 vtkDataSet *dataset = picker->GetDataSet();
@@ -88,8 +86,6 @@ void creaVtkCallbackPointPicker::Execute(vtkObject *caller, unsigned long, void*
                } // if Active
        } // if boxPoiintPicker
 
-    printf("EED creaVtkCallbackPointPicker::Execute End\n");
-
     
 /*
 {
@@ -166,7 +162,6 @@ BBTK_BLACK_BOX_IMPLEMENTATION(PointPicker,bbtk::AtomicBlackBox);
 //===== 
 void PointPicker::Process()
 {
-    printf("EED PointPicker::Process Start \n");
 // THE MAIN PROCESSING METHOD BODY
 //   Here we simply set the input 'In' value to the output 'Out'
 //   And print out the output value
@@ -244,8 +239,6 @@ void PointPicker::Process()
 //  bbSetOutputCellId( -1 );
 //  bbSetOutputNormal( lstPoint );
     
-    printf("EED PointPicker::Process End \n");
-
 }
 
 //===== 
index 92cf8834597d385f009340c36c9211d871a53d80..f9676e5a4b9a3d49f83203df7eb0f0478448ce0e 100644 (file)
@@ -21,7 +21,6 @@ BBTK_BLACK_BOX_IMPLEMENTATION(PolyDataNormals,bbtk::AtomicBlackBox);
 //===== 
 void PolyDataNormals::Process()
 {
-    printf("EED PolyDataNormals::Process Start\n");
 // THE MAIN PROCESSING METHOD BODY
 //   Here we simply set the input 'In' value to the output 'Out'
 //   And print out the output value
@@ -98,15 +97,12 @@ void PolyDataNormals::Process()
             double meanNormalresult[3];
             double ang;
             double crossResult[3];
-            printf("EED PolyDataNormals::Process 1\n");
             meanN[0] = meanNormal[0];
             meanN[1] = meanNormal[1];
             meanN[2] = meanNormal[2];
-            printf("EED PolyDataNormals::Process 2\n");
             int i , size=dataarray->GetNumberOfTuples();
             for (i=0; i<size; i++)
             {
-                printf("EED PolyDataNormals::Process 3\n");
                 pValue  = dataarray->GetTuple3( i );
                 ang     = vtkMath::AngleBetweenVectors( pValue, meanN );
                 
@@ -115,7 +111,6 @@ void PolyDataNormals::Process()
                 wxyz[1] = crossResult[0];
                 wxyz[2] = crossResult[1];
                 wxyz[3] = crossResult[2];
-                printf("EED PolyDataNormals::Process 4\n");
                 vtkMath::RotateVectorByWXYZ(meanN, wxyz ,meanNormalresult);
                 dataarray->SetTuple3( i , meanNormalresult[0], meanNormalresult[1], meanNormalresult[2] );
             } // for
@@ -125,9 +120,6 @@ void PolyDataNormals::Process()
         bbSetOutputOut( normal->GetOutput() );
     } // if In
     
-    printf("EED PolyDataNormals::Process End\n");
-
-    
 }
 //===== 
 // Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)