From d70f55488259f6eb18e16d8a96a2bee6615f10e2 Mon Sep 17 00:00:00 2001 From: Eduardo DAVILA Date: Mon, 14 Aug 2017 16:47:26 +0200 Subject: [PATCH] #3107 BBTK Bug New Normal - branch vtk7itk4 compilation with vtk7 --- packages/vtk/src/bbvtkImagePlanes.cxx | 2 +- packages/vtk/src/bbvtkRescaleSlopeIntercept.cxx | 7 +++++++ packages/wxvtk/src/bbwxvtkViewer2D.cxx | 3 ++- 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/packages/vtk/src/bbvtkImagePlanes.cxx b/packages/vtk/src/bbvtkImagePlanes.cxx index ab91a12..6f28082 100644 --- a/packages/vtk/src/bbvtkImagePlanes.cxx +++ b/packages/vtk/src/bbvtkImagePlanes.cxx @@ -515,7 +515,7 @@ namespace bbvtk _imageReslicer->GetOutput()->UpdateInformation(); #endif #if (VTK_MAJOR_VERSION >= 6) - // .. + _imageReslicer->Update(); #endif diff --git a/packages/vtk/src/bbvtkRescaleSlopeIntercept.cxx b/packages/vtk/src/bbvtkRescaleSlopeIntercept.cxx index 9262c50..e9cf56d 100644 --- a/packages/vtk/src/bbvtkRescaleSlopeIntercept.cxx +++ b/packages/vtk/src/bbvtkRescaleSlopeIntercept.cxx @@ -43,6 +43,7 @@ BBTK_BLACK_BOX_IMPLEMENTATION(RescaleSlopeIntercept,bbtk::AtomicBlackBox); //===== void RescaleSlopeIntercept::Process() { +printf("RescaleSlopeIntercept::Process Start\n"); // THE MAIN PROCESSING METHOD BODY // Here we simply set the input 'In' value to the output 'Out' @@ -142,12 +143,18 @@ void RescaleSlopeIntercept::Process() mchange->SetExtentTranslation( -ext[0], -ext[2], -ext[4] ); mchange->SetOutputSpacing (spc); + filter1->Update(); //important + filter2->Update(); //important mchange->Update(); //important bbSetOutputOut( mchange->GetOutput() ); +printf("RescaleSlopeIntercept::Process A\n"); } else { +printf("RescaleSlopeIntercept::Process B\n"); bbSetOutputOut( NULL ); } // if bbGetInputIn +printf("RescaleSlopeIntercept::Process End\n"); + } diff --git a/packages/wxvtk/src/bbwxvtkViewer2D.cxx b/packages/wxvtk/src/bbwxvtkViewer2D.cxx index 0ab9c25..bd675d5 100644 --- a/packages/wxvtk/src/bbwxvtkViewer2D.cxx +++ b/packages/wxvtk/src/bbwxvtkViewer2D.cxx @@ -132,6 +132,8 @@ namespace bbwxvtk mDefaultImage->SetScalarComponentFromFloat(i,dim[1]-i-1,1,0,255); } + mDefaultImage->Modified(); + backImageData = mDefaultImage; imageViewer->SetInput( backImageData ); mUpdateCamera = true; @@ -323,7 +325,6 @@ namespace bbwxvtk bbtkDebugMessage("Output",3,"Viewer2D : slice = "<SetSliceOrientation (orientation); imageViewer->SetSlice( z ); - } } -- 2.45.1