X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FConvolution.cxx;h=796a0597d1d20e4b397d9796e178008369ac0032;hb=refs%2Fheads%2Fvtk7itk4wx3;hp=adddb961ec87ce30c678d2d82bfa9d4b1c0101bd;hpb=73f77fd5de4f2a23dc595e8e7017dd9b586dddcc;p=creaRigidRegistration.git diff --git a/lib/Convolution.cxx b/lib/Convolution.cxx index adddb96..796a059 100644 --- a/lib/Convolution.cxx +++ b/lib/Convolution.cxx @@ -55,7 +55,12 @@ vtkImageData *Convolution::getImage() void Convolution::setImage(vtkImageData *image) { _image = image; +//EED 2017-01-01 Migration VTK7 +#if VTK_MAJOR_VERSION <= 5 _convolve->SetInput(_image); +#else + _convolve->SetInputData(_image); +#endif } void Convolution::setFactor(double factor) @@ -75,13 +80,23 @@ void Convolution::Run() double kernel[] = {0.0,1.0,0.0,1.0,-_factor,1.0,0.0,1.0,0.0}; _convolve->SetKernel3x3(kernel); _convolve->Update(); +//EED 2017-01-01 Migration VTK7 +#if VTK_MAJOR_VERSION <= 5 _cast->SetInput(_convolve->GetOutput()); +#else + _cast->SetInputData(_convolve->GetOutput()); +#endif //_cast->SetOutputScalarTypeToDouble(); _cast->Update(); } else { +//EED 2017-01-01 Migration VTK7 +#if VTK_MAJOR_VERSION <= 5 _cast->SetInput(_image); +#else + _cast->SetInputData(_image); +#endif _cast->SetOutputScalarType(_image->GetScalarType()); _cast->Update(); }