From 94e09a205dd9ad26567969ae5a3b03eb82d89deb Mon Sep 17 00:00:00 2001 From: "eduardo.davila@creatis.insa-lyon.fr" Date: Fri, 22 Dec 2023 10:36:11 +0100 Subject: [PATCH] #3520 ImageMaskDice --- .../src/bbcreaVtkImageMaskDice.cxx | 79 +++++++++++++++++++ bbtk_creaVtk_PKG/src/bbcreaVtkImageMaskDice.h | 50 ++++++++++++ 2 files changed, 129 insertions(+) create mode 100644 bbtk_creaVtk_PKG/src/bbcreaVtkImageMaskDice.cxx create mode 100644 bbtk_creaVtk_PKG/src/bbcreaVtkImageMaskDice.h diff --git a/bbtk_creaVtk_PKG/src/bbcreaVtkImageMaskDice.cxx b/bbtk_creaVtk_PKG/src/bbcreaVtkImageMaskDice.cxx new file mode 100644 index 0000000..23b4330 --- /dev/null +++ b/bbtk_creaVtk_PKG/src/bbcreaVtkImageMaskDice.cxx @@ -0,0 +1,79 @@ +//===== +// 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) +//===== +#include "bbcreaVtkImageMaskDice.h" +#include "bbcreaVtkPackage.h" +namespace bbcreaVtk +{ + +BBTK_ADD_BLACK_BOX_TO_PACKAGE(creaVtk,ImageMaskDice) +BBTK_BLACK_BOX_IMPLEMENTATION(ImageMaskDice,bbtk::AtomicBlackBox); +//===== +// 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 ImageMaskDice::Process() +{ + +// THE MAIN PROCESSING METHOD BODY +// Here we simply set the input 'In' value to the output 'Out' +// And print out the output value +// INPUT/OUTPUT ACCESSORS ARE OF THE FORM : +// void bbSet{Input|Output}NAME(const TYPE&) +// const TYPE& bbGet{Input|Output}NAME() const +// Where : +// * NAME is the name of the input/output +// (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') + + + printf("EED ImageMaskDice::Process Error, this method is not implemented \n"); + printf("EED ImageMaskDice::Process Error, this method is not implemented \n"); + printf("EED ImageMaskDice::Process Error, this method is not implemented \n"); + printf("EED ImageMaskDice::Process Error, this method is not implemented \n"); + printf("EED ImageMaskDice::Process Error, this method is not implemented \n"); + printf("EED ImageMaskDice::Process Error, this method is not implemented \n"); + + bbSetOutputOut( -1 ); +} +//===== +// 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 ImageMaskDice::bbUserSetDefaultValues() +{ + +// SET HERE THE DEFAULT INPUT/OUTPUT VALUES OF YOUR BOX +// Here we initialize the input 'In' to 0 + bbSetInputIn1(NULL); + bbSetInputIn2(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 ImageMaskDice::bbUserInitializeProcessing() +{ + +// THE INITIALIZATION METHOD BODY : +// Here does nothing +// but this is where you should allocate the internal/output pointers +// 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 ImageMaskDice::bbUserFinalizeProcessing() +{ + +// THE FINALIZATION METHOD BODY : +// Here does nothing +// but this is where you should desallocate the internal/output pointers +// if any + +} +} +// EO namespace bbcreaVtk + + diff --git a/bbtk_creaVtk_PKG/src/bbcreaVtkImageMaskDice.h b/bbtk_creaVtk_PKG/src/bbcreaVtkImageMaskDice.h new file mode 100644 index 0000000..5caeea7 --- /dev/null +++ b/bbtk_creaVtk_PKG/src/bbcreaVtkImageMaskDice.h @@ -0,0 +1,50 @@ +//===== +// 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) +//===== +#ifndef __bbcreaVtkImageMaskDice_h_INCLUDED__ +#define __bbcreaVtkImageMaskDice_h_INCLUDED__ + +#include "bbcreaVtk_EXPORT.h" +#include "bbtkAtomicBlackBox.h" +#include "iostream" + +#include "vtkImageData.h" + +namespace bbcreaVtk +{ + +class bbcreaVtk_EXPORT ImageMaskDice + : + public bbtk::AtomicBlackBox +{ + BBTK_BLACK_BOX_INTERFACE(ImageMaskDice,bbtk::AtomicBlackBox); +//===== +// 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) +//===== + BBTK_DECLARE_INPUT(In1,vtkImageData*); + BBTK_DECLARE_INPUT(In2,vtkImageData*); + BBTK_DECLARE_OUTPUT(Out,double); + BBTK_PROCESS(Process); + void Process(); +//===== +// 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) +//===== +}; + +BBTK_BEGIN_DESCRIBE_BLACK_BOX(ImageMaskDice,bbtk::AtomicBlackBox); + BBTK_NAME("ImageMaskDice"); + BBTK_AUTHOR("InfoDev"); + BBTK_DESCRIPTION("(C++?????,Python)"); + BBTK_CATEGORY("empty"); + BBTK_INPUT(ImageMaskDice,In1,"Image 1",vtkImageData*,""); + BBTK_INPUT(ImageMaskDice,In2,"Image 2",vtkImageData*,""); + BBTK_OUTPUT(ImageMaskDice,Out,"Dice",double,""); +BBTK_END_DESCRIBE_BLACK_BOX(ImageMaskDice); +//===== +// 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 + +#endif // __bbcreaVtkImageMaskDice_h_INCLUDED__ + -- 2.47.1