X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=common%2FvvImage.h;h=ec01a1ffbe40d67f0f8b6a095f8cd56a80edacef;hb=29c90b5fbd7ecd5d8375e02b7a03734c4fdbc806;hp=cc0ce76028dd3734eeeb342aa80c9de996846d05;hpb=f181e8fc01dec00bc6b0c82e0e273e1bb0d292c5;p=clitk.git diff --git a/common/vvImage.h b/common/vvImage.h index cc0ce76..ec01a1f 100644 --- a/common/vvImage.h +++ b/common/vvImage.h @@ -3,7 +3,7 @@ Authors belong to: - University of LYON http://www.universite-lyon.fr/ - - Léon Bérard cancer center http://oncora1.lyon.fnclcc.fr + - Léon Bérard cancer center http://www.centreleonberard.fr - CREATIS CNRS laboratory http://www.creatis.insa-lyon.fr This software is distributed WITHOUT ANY WARRANTY; without even @@ -14,7 +14,7 @@ - BSD See included LICENSE.txt file - CeCILL-B http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html -======================================================================-====*/ +===========================================================================**/ #ifndef VVIMAGE_H #define VVIMAGE_H @@ -22,11 +22,11 @@ #include #include #include + #include +#include class vtkImageData; -class vtkImageReslice; -class vtkTransform; //------------------------------------------------------------------------------ class vvImage : public itk::LightObject @@ -40,6 +40,7 @@ public : void Init(); void Reset(); template void AddItkImage(TItkImageType *input); + void AddVtkImage(vtkImageData* input); const std::vector& GetVTKImages(); vtkImageData* GetFirstVTKImageData(); int GetNumberOfDimensions() const; @@ -52,13 +53,13 @@ public : std::string GetScalarTypeAsITKString(); int GetNumberOfScalarComponents(); int GetScalarSize(); - bool IsTimeSequence(); + bool IsTimeSequence() const; bool IsScalarTypeInteger(); bool IsScalarTypeInteger(int t); vtkSmartPointer GetTransform(); void SetTimeSpacing(double s) { mTimeSpacing = s; } void SetTimeOrigin(double o) { mTimeOrigin = o; } - void UpdateReslice(); + bool HaveSameSizeAndSpacingThan(vvImage * other); private: vvImage(); @@ -66,10 +67,11 @@ private: std::vector< ConverterPointer > mItkToVtkConverters; std::vector mVtkImages; - std::vector< vtkSmartPointer > mVtkImageReslice; vtkSmartPointer mTransform; + double mTimeOrigin; double mTimeSpacing; + unsigned int mImageDimension; }; //------------------------------------------------------------------------------