From: tbaudier Date: Tue, 22 Aug 2017 13:37:56 +0000 (+0200) Subject: Remove warnings with VTK8 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=d1dc57c5af88ff53c75904b1dd55722f9631a21e;p=clitk.git Remove warnings with VTK8 --- diff --git a/vv/vtkVOXImageWriter.cxx b/vv/vtkVOXImageWriter.cxx index 911091e..b703e96 100644 --- a/vv/vtkVOXImageWriter.cxx +++ b/vv/vtkVOXImageWriter.cxx @@ -144,7 +144,7 @@ void vtkVOXImageWriter::Write( ) ext[2], ext[3], ext[4], ext[5]); this->GetInput()->UpdateData(); -#elif VTK_MAJOR_VERSION >= 7 && VTK_MINOR_VERSION >= 1 +#elif VTK_MAJOR_VERSION >= 8 || (VTK_MAJOR_VERSION == 7 && VTK_MINOR_VERSION >= 1) this->UpdateExtent(ext); this->Update(); #else diff --git a/vv/vvAnimatedGIFWriter.cxx b/vv/vvAnimatedGIFWriter.cxx index 026ebe0..d72f253 100644 --- a/vv/vvAnimatedGIFWriter.cxx +++ b/vv/vvAnimatedGIFWriter.cxx @@ -47,7 +47,7 @@ void vvAnimatedGIFWriter::Write() int *wExtent = this->GetInput()->GetWholeExtent(); this->GetInput()->SetUpdateExtent(wExtent); this->GetInput()->Update(); -#elif VTK_MAJOR_VERSION >= 7 && VTK_MINOR_VERSION >= 1 +#elif VTK_MAJOR_VERSION >= 8 || (VTK_MAJOR_VERSION == 7 && VTK_MINOR_VERSION >= 1) this->UpdateInformation(); int *wExtent = this->GetInput()->GetInformation()->Get(vtkDataObject::DATA_EXTENT()); this->UpdateExtent(wExtent); diff --git a/vv/vvGlyph2D.cxx b/vv/vvGlyph2D.cxx index 9fde11d..ae1a6b1 100644 --- a/vv/vvGlyph2D.cxx +++ b/vv/vvGlyph2D.cxx @@ -175,7 +175,7 @@ int vvGlyph2D::RequestData( #if VTK_MAJOR_VERSION <= 5 defaultSource->SetUpdateExtent(0, 1, 0); this->SetSource(defaultSource); -#elif VTK_MAJOR_VERSION >= 7 && VTK_MINOR_VERSION >= 1 +#elif VTK_MAJOR_VERSION >= 8 || (VTK_MAJOR_VERSION == 7 && VTK_MINOR_VERSION >= 1) int extentTemp[3] = {0, 1, 0}; this->UpdateExtent(extentTemp); this->SetSourceData(defaultSource); diff --git a/vv/vvSlicer.cxx b/vv/vvSlicer.cxx index 8479095..10396a6 100644 --- a/vv/vvSlicer.cxx +++ b/vv/vvSlicer.cxx @@ -393,7 +393,7 @@ void vvSlicer::SetImage(vvImage::Pointer image) #if VTK_MAJOR_VERSION <= 5 mImageReslice->GetOutput()->SetUpdateExtent(extent); mImageReslice->GetOutput()->Update(); -#elif VTK_MAJOR_VERSION >= 7 && VTK_MINOR_VERSION >= 1 +#elif VTK_MAJOR_VERSION >= 8 || (VTK_MAJOR_VERSION == 7 && VTK_MINOR_VERSION >= 1) mImageReslice->UpdateExtent(extent); mImageReslice->Update(); #else @@ -1793,7 +1793,7 @@ void vvSlicer::Render() } #if VTK_MAJOR_VERSION <= 5 mOverlayMapper->GetOutput()->SetUpdateExtent(mOverlayActor->GetDisplayExtent()); -#elif VTK_MAJOR_VERSION >= 7 && VTK_MINOR_VERSION >= 1 +#elif VTK_MAJOR_VERSION >= 8 || (VTK_MAJOR_VERSION == 7 && VTK_MINOR_VERSION >= 1) mOverlayMapper->UpdateExtent(mOverlayActor->GetDisplayExtent()); #else mOverlayMapper->SetUpdateExtent(mOverlayActor->GetDisplayExtent()); @@ -1803,7 +1803,7 @@ void vvSlicer::Render() if (mFusion && mFusionActor->GetVisibility()) { #if VTK_MAJOR_VERSION <= 5 mFusionMapper->GetOutput()->SetUpdateExtent(mFusionActor->GetDisplayExtent()); -#elif VTK_MAJOR_VERSION >= 7 && VTK_MINOR_VERSION >= 1 +#elif VTK_MAJOR_VERSION >= 8 || (VTK_MAJOR_VERSION == 7 && VTK_MINOR_VERSION >= 1) mFusionMapper->UpdateExtent(mFusionActor->GetDisplayExtent()); #else mFusionMapper->SetUpdateExtent(mFusionActor->GetDisplayExtent()); diff --git a/vv/vvToolProfile.cxx b/vv/vvToolProfile.cxx index c6b44b6..baf34f8 100644 --- a/vv/vvToolProfile.cxx +++ b/vv/vvToolProfile.cxx @@ -615,7 +615,7 @@ void vvToolProfile::InitializeLine() unsigned char red[3] = { 255, 0, 0 }; vtkSmartPointer colors = vtkSmartPointer::New(); colors->SetNumberOfComponents(3); -#if VTK_MAJOR_VERSION >= 7 && VTK_MINOR_VERSION >= 1 +#if VTK_MAJOR_VERSION >= 8 || (VTK_MAJOR_VERSION == 7 && VTK_MINOR_VERSION >= 1) colors->InsertNextTypedTuple(red); #else colors->InsertNextTupleValue(red);