From: eduardo.davila@creatis.insa-lyon.fr Date: Thu, 17 Apr 2025 14:50:53 +0000 (+0200) Subject: #3535 RescaleSlopeIntercept recreate filter X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=791ea07207d247c328f57139fa1170e4f9f0f948;p=bbtk.git #3535 RescaleSlopeIntercept recreate filter --- diff --git a/packages/vtk/src/bbvtkRescaleSlopeIntercept.cxx b/packages/vtk/src/bbvtkRescaleSlopeIntercept.cxx index 5c7eb64..3b5535c 100644 --- a/packages/vtk/src/bbvtkRescaleSlopeIntercept.cxx +++ b/packages/vtk/src/bbvtkRescaleSlopeIntercept.cxx @@ -63,8 +63,19 @@ void RescaleSlopeIntercept::Process() double A=bbGetInputA(); double B=bbGetInputB(); - if (bbGetInputIn()!=0) + if (bbGetInputIn()!=NULL) { + + if (filter1!=NULL){ + mchange->Delete(); + filter1->Delete(); + filter2->Delete(); + filter1 = vtkImageShiftScale::New(); + filter2 = vtkImageShiftScale::New(); + mchange = vtkImageChangeInformation::New(); + } + + int outputformat = bbtkStaticLecture::GetTypeFormat( bbGetInputOutputFormat() , bbGetInputIn() ); bbGetInputIn()->GetScalarRange(range); bbGetInputIn()->GetSpacing(spc); diff --git a/packages/wx/src/bbwxLayoutSplit.h b/packages/wx/src/bbwxLayoutSplit.h index 02ac02c..39c23e3 100644 --- a/packages/wx/src/bbwxLayoutSplit.h +++ b/packages/wx/src/bbwxLayoutSplit.h @@ -88,7 +88,7 @@ namespace bbwx BBTK_BEGIN_DESCRIBE_BLACK_BOX(LayoutSplit,bbtk::WxBlackBox); BBTK_NAME("LayoutSplit"); BBTK_AUTHOR("laurent.guigues@creatis.insa-lyon.fr"); - BBTK_DESCRIPTION("(C++,Python) Widget which splits a window in two fixed size parts (wxSplitterWindow)"); + BBTK_DESCRIPTION("(C++,Python,JavaScript) Widget which splits a window in two fixed size parts (wxSplitterWindow)"); // Already inserted for any WxBlackBox BBTK_CATEGORY("widget"); BBTK_INPUT(LayoutSplit,Widget1,"Upper or left widget",wxWindow*,""); BBTK_INPUT(LayoutSplit,Widget2,"Lower or right widget",wxWindow*,""); diff --git a/packages/wx/src/bbwxLayoutTab.h b/packages/wx/src/bbwxLayoutTab.h index f00c62e..157a3e6 100644 --- a/packages/wx/src/bbwxLayoutTab.h +++ b/packages/wx/src/bbwxLayoutTab.h @@ -93,7 +93,7 @@ namespace bbwx BBTK_BEGIN_DESCRIBE_BLACK_BOX(LayoutTab,bbtk::WxBlackBox); BBTK_NAME("LayoutTab"); BBTK_AUTHOR("eduardo.davila@creatis.insa-lyon.fr"); - BBTK_DESCRIPTION("(C++, Python) LayoutTab widget (wxNotebook) The label of each 'note book' will be the name of the object it contains"); + BBTK_DESCRIPTION("(C++,Python,JavaScript) LayoutTab widget (wxNotebook) The label of each 'note book' will be the name of the object it contains"); // Already inserted for any WxBlackBox BBTK_CATEGORY("widget"); BBTK_INPUT(LayoutTab,Widget1,"widget 1",wxWindow*,""); BBTK_INPUT(LayoutTab,Widget2,"widget 2",wxWindow*,"");