From 84f24d4ef3aa0376ced29fe7f3a43127cc2d3aa4 Mon Sep 17 00:00:00 2001 From: "eduardo.davila@creatis.insa-lyon.fr" Date: Wed, 29 May 2024 10:35:53 +0200 Subject: [PATCH] #3525 Python descrition --- bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget.cxx | 7 +----- bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget.h | 2 +- .../src/bbcreaVtkBoxWidget_tool.cxx | 9 ++++--- .../src/bbcreaVtkBoxWidget_tool.h | 3 +-- .../src/bbcreaVtkClipPolyData.cxx | 21 ++++++---------- bbtk_creaVtk_PKG/src/bbcreaVtkClipPolyData.h | 2 +- .../src/bbcreaVtkConcatTransform.cxx | 2 +- .../src/bbcreaVtkConcatTransform.h | 2 +- .../src/bbcreaVtkNIFTIImageReader.cxx | 25 +++++++------------ .../src/bbcreaVtkNIFTIImageReader.h | 2 +- .../src/bbcreaVtkPolyDataNormals.h | 2 +- bbtk_creaVtk_PKG/src/bbcreaVtkStlReader.cxx | 25 +++++++------------ bbtk_creaVtk_PKG/src/bbcreaVtkStlReader.h | 6 ++--- 13 files changed, 42 insertions(+), 66 deletions(-) diff --git a/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget.cxx b/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget.cxx index 304e39d..d0c6050 100644 --- a/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget.cxx +++ b/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget.cxx @@ -112,13 +112,8 @@ void BoxWidget::Process() bbSetOutputTransformOut( transformOut ); } else { printf("EED Warnning! BoxWidget::Process vtkRenderer not set.\n"); - }// vtkRenderer != NULL - + }// vtkRenderer != NULL bbSetOutputBox_BoxWidget( this ); - - printf("EED BoxWidget::Process A\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) diff --git a/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget.h b/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget.h index 1659b76..9f5d104 100644 --- a/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget.h +++ b/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget.h @@ -53,7 +53,7 @@ class bbcreaVtk_EXPORT BoxWidget BBTK_BEGIN_DESCRIBE_BLACK_BOX(BoxWidget,bbtk::AtomicBlackBox); BBTK_NAME("BoxWidget"); BBTK_AUTHOR("InfoDev"); - BBTK_DESCRIPTION("No Description."); + BBTK_DESCRIPTION("(C++,Python) No Description."); BBTK_CATEGORY("empty"); BBTK_INPUT(BoxWidget,Active,"(default false) true/false",bool,""); diff --git a/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget_tool.cxx b/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget_tool.cxx index eb3be70..78e630a 100644 --- a/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget_tool.cxx +++ b/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget_tool.cxx @@ -29,10 +29,13 @@ void BoxWidget_tool::Process() // bbSetOutputOut( bbGetInputIn() ); // std::cout << "Output value = " <SetTransform( bbGetInputTransform() ); - } // _BoxWidget + if ( (bbGetInputBox_BoxWidget()!=NULL) && (bbGetInputTransform()!=NULL) ) + { + bbGetInputBox_BoxWidget()->SetTransform( bbGetInputTransform() ); + } // _BoxWidget + } // if Type } //===== diff --git a/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget_tool.h b/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget_tool.h index a3b9711..05f9c57 100644 --- a/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget_tool.h +++ b/bbtk_creaVtk_PKG/src/bbcreaVtkBoxWidget_tool.h @@ -25,7 +25,6 @@ class bbcreaVtk_EXPORT BoxWidget_tool BBTK_DECLARE_INPUT(Type,int); BBTK_DECLARE_INPUT(Transform,vtkLinearTransform*); BBTK_DECLARE_INPUT(Param01,std::vector); - BBTK_DECLARE_INPUT(Param02,std::vector); BBTK_DECLARE_INPUT(Box_BoxWidget,BoxWidget*); BBTK_PROCESS(Process); void Process(); @@ -37,7 +36,7 @@ class bbcreaVtk_EXPORT BoxWidget_tool BBTK_BEGIN_DESCRIBE_BLACK_BOX(BoxWidget_tool,bbtk::AtomicBlackBox); BBTK_NAME("BoxWidget_tool"); BBTK_AUTHOR("InfoDev"); - BBTK_DESCRIPTION("No Description."); + BBTK_DESCRIPTION("(C++,Python) No Description."); BBTK_CATEGORY("empty"); BBTK_INPUT(BoxWidget_tool,Type,"(default 0) 0:Nothing 1:SetTransform",int,""); BBTK_INPUT(BoxWidget_tool,Transform,"vtkTransform",vtkLinearTransform*,""); diff --git a/bbtk_creaVtk_PKG/src/bbcreaVtkClipPolyData.cxx b/bbtk_creaVtk_PKG/src/bbcreaVtkClipPolyData.cxx index ad46cbc..e5b5ebd 100644 --- a/bbtk_creaVtk_PKG/src/bbcreaVtkClipPolyData.cxx +++ b/bbtk_creaVtk_PKG/src/bbcreaVtkClipPolyData.cxx @@ -33,8 +33,6 @@ void ClipPolyData::Process() // bbSetOutputOut( bbGetInputIn() ); // std::cout << "Output value = " <GetOutput() ); } // for i } // Type 1 - } // if - if (lstImages.size()>=1) { bbSetOutputOut( lstImages[0] ); } else {bbSetOutputOut( NULL ); } bbSetOutputOutVector( lstImages ); - } -//===== + +//===== // 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) //===== void NIFTIImageReader::bbUserSetDefaultValues() { - // SET HERE THE DEFAULT INPUT/OUTPUT VALUES OF YOUR BOX // Here we initialize the input 'In' to 0 bbSetInputType(0); - } -//===== + +//===== // 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) //===== void NIFTIImageReader::bbUserInitializeProcessing() { - // THE INITIALIZATION METHOD BODY : // Here does nothing // but this is where you should allocate the internal/output pointers -// if any - - +// if any } -//===== + +//===== // 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) //===== void NIFTIImageReader::bbUserFinalizeProcessing() { - // THE FINALIZATION METHOD BODY : // Here does nothing // but this is where you should desallocate the internal/output pointers // if any - } -} -// EO namespace bbcreaVtk + +}// EO namespace bbcreaVtk diff --git a/bbtk_creaVtk_PKG/src/bbcreaVtkNIFTIImageReader.h b/bbtk_creaVtk_PKG/src/bbcreaVtkNIFTIImageReader.h index f32a71d..39bd847 100644 --- a/bbtk_creaVtk_PKG/src/bbcreaVtkNIFTIImageReader.h +++ b/bbtk_creaVtk_PKG/src/bbcreaVtkNIFTIImageReader.h @@ -35,7 +35,7 @@ class bbcreaVtk_EXPORT NIFTIImageReader BBTK_BEGIN_DESCRIBE_BLACK_BOX(NIFTIImageReader,bbtk::AtomicBlackBox); BBTK_NAME("NIFTIImageReader"); BBTK_AUTHOR("Info-Dev"); - BBTK_DESCRIPTION("No Description."); + BBTK_DESCRIPTION("(C++,Python) No Description."); BBTK_CATEGORY("empty"); BBTK_INPUT(NIFTIImageReader,Type,"(default 0) 0:Use FileNames by slice 1:Use FileNames by volumes",int,""); BBTK_INPUT(NIFTIImageReader,FileNames,"List of file names",std::vector,""); diff --git a/bbtk_creaVtk_PKG/src/bbcreaVtkPolyDataNormals.h b/bbtk_creaVtk_PKG/src/bbcreaVtkPolyDataNormals.h index 41dd924..773df44 100644 --- a/bbtk_creaVtk_PKG/src/bbcreaVtkPolyDataNormals.h +++ b/bbtk_creaVtk_PKG/src/bbcreaVtkPolyDataNormals.h @@ -38,7 +38,7 @@ class bbcreaVtk_EXPORT PolyDataNormals BBTK_BEGIN_DESCRIBE_BLACK_BOX(PolyDataNormals,bbtk::AtomicBlackBox); BBTK_NAME("PolyDataNormals"); BBTK_AUTHOR("InfoDev"); - BBTK_DESCRIPTION("No Description."); + BBTK_DESCRIPTION("(C++,Python) No Description."); BBTK_CATEGORY("empty"); BBTK_INPUT(PolyDataNormals,In,"Mesh input",vtkPolyData*,""); BBTK_INPUT(PolyDataNormals,ComputeType,"(0 default) 0:Cells 1:Points",int,""); diff --git a/bbtk_creaVtk_PKG/src/bbcreaVtkStlReader.cxx b/bbtk_creaVtk_PKG/src/bbcreaVtkStlReader.cxx index 11f4e19..61ace8a 100644 --- a/bbtk_creaVtk_PKG/src/bbcreaVtkStlReader.cxx +++ b/bbtk_creaVtk_PKG/src/bbcreaVtkStlReader.cxx @@ -16,7 +16,6 @@ BBTK_BLACK_BOX_IMPLEMENTATION(StlReader,bbtk::AtomicBlackBox); //===== void StlReader::Process() { - // THE MAIN PROCESSING METHOD BODY // Here we simply set the input 'In' value to the output 'Out' // And print out the output value @@ -28,50 +27,44 @@ void StlReader::Process() // (the one provided in the attribute 'name' of the tag 'input') // * TYPE is the C++ type of the input/output // (the one provided in the attribute 'type' of the tag 'input') - vtkSTLReader *reader = vtkSTLReader::New(); reader->SetFileName( bbGetInputFileName().c_str() ); reader->Update(); bbSetOutputOut( reader->GetOutput() ); - } -//===== + +//===== // 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) //===== void StlReader::bbUserSetDefaultValues() { - // SET HERE THE DEFAULT INPUT/OUTPUT VALUES OF YOUR BOX // Here we initialize the input 'In' to 0 bbSetOutputOut(NULL); - } -//===== + +//===== // 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) //===== void StlReader::bbUserInitializeProcessing() { - // THE INITIALIZATION METHOD BODY : // Here does nothing // but this is where you should allocate the internal/output pointers -// if any - - +// if any } -//===== + +//===== // 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) //===== void StlReader::bbUserFinalizeProcessing() { - // THE FINALIZATION METHOD BODY : // Here does nothing // but this is where you should desallocate the internal/output pointers // if any - } -} -// EO namespace bbcreaVtk + +}// EO namespace bbcreaVtk diff --git a/bbtk_creaVtk_PKG/src/bbcreaVtkStlReader.h b/bbtk_creaVtk_PKG/src/bbcreaVtkStlReader.h index e1405e1..cb2a102 100644 --- a/bbtk_creaVtk_PKG/src/bbcreaVtkStlReader.h +++ b/bbtk_creaVtk_PKG/src/bbcreaVtkStlReader.h @@ -33,7 +33,7 @@ class bbcreaVtk_EXPORT StlReader BBTK_BEGIN_DESCRIBE_BLACK_BOX(StlReader,bbtk::AtomicBlackBox); BBTK_NAME("StlReader"); BBTK_AUTHOR("InfoDev"); - BBTK_DESCRIPTION("No Description."); + BBTK_DESCRIPTION("(C++,Python) No Description."); BBTK_CATEGORY("empty"); BBTK_INPUT(StlReader,FileName,"File Name",std::string,""); BBTK_OUTPUT(StlReader,Out,"vtkPolyData",vtkPolyData*,""); @@ -41,8 +41,8 @@ BBTK_END_DESCRIBE_BLACK_BOX(StlReader); //===== // 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) //===== -} -// EO namespace bbcreaVtk + +}// EO namespace bbcreaVtk #endif // __bbcreaVtkStlReader_h_INCLUDED__ -- 2.45.1