X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=vv%2FvvSlicer.h;h=0bffd1f36abcc46f92d5b43a3c51aab519685e59;hb=0c56fa9705f9abdc98db8e0da1933ad3e5a3e192;hp=9a750e14d69a6db41596d143e4d3ff30c33b9fae;hpb=bc4b7eaef671605cb3e8077ce8a70eb7386890e5;p=clitk.git diff --git a/vv/vvSlicer.h b/vv/vvSlicer.h index 9a750e1..0bffd1f 100644 --- a/vv/vvSlicer.h +++ b/vv/vvSlicer.h @@ -20,15 +20,20 @@ #include #include +#include //TODO delete +#include + #include "vvLandmarks.h" #include "vvImage.h" #include "vvMesh.h" #include "vvMeshActor.h" +#include "vvClipPolyData.h" #include #include #include #include +#include class vtkActor; class vtkActor2D; @@ -76,7 +81,7 @@ public: vtkActor* GetVFActor() ; vtkCornerAnnotation* GetAnnotation(); - void SetFusion(vvImage::Pointer inputFusion); + void SetFusion(vvImage::Pointer inputFusion, int fusionSequenceCode = -1); vvImage::Pointer GetFusion() { return mFusion; } @@ -95,7 +100,10 @@ public: } void SetLandmarks(vvLandmarks* landmarks); - void SetTSlice(int t); + void SetTSlice(int t, bool updateLinkedImages = true); + + void SetFusionSequenceTSlice(int t); + void SetSliceOrientation(int orientation); void AdjustResliceToSliceOrientation(vtkImageReslice *reslice); int GetTSlice(); @@ -189,7 +197,7 @@ public: void EnableReducedExtent(bool b); void SetReducedExtent(int * ext); - void ClipDisplayedExtent(int extent[6], int refExtent[6]); + bool ClipDisplayedExtent(int extent[6], int refExtent[6]); int GetOrientation(); int * GetExtent(); @@ -198,6 +206,8 @@ public: } void SetVFColor(double r, double g, double b); + //necessary to flag the secondary sequence + void SetFusionSequenceCode(int code) {mFusionSequenceCode=code;} protected: vvSlicer(); ~vvSlicer(); @@ -210,6 +220,8 @@ protected: vvLandmarks* mLandmarks; + int mFusionSequenceCode; //-1: not involved in a fusion sequence, 0: main sequence (CT), 1: secondary sequence (US) + // __________ Image coordinates accounting for spacing and origin // Λ Λ // | | vvImage.GetTransform() @@ -244,9 +256,10 @@ protected: vtkSmartPointer mVFActor; vtkSmartPointer mLandGlyph; vtkSmartPointer mCross; - vtkSmartPointer mLandClipper; + vtkSmartPointer mLandClipper; vtkSmartPointer mLandMapper; vtkSmartPointer mLandActor; + std::vector > mLandLabelActors; vtkSmartPointer mClipBox; vtkSmartPointer legend; std::vector mSurfaceCutActors; @@ -276,6 +289,14 @@ private: ///Sets the surfaces to be cut on the image slice: update the vtkCutter void SetContourSlice(); - + // Visibility of the different elements that can be set from outside the object. + // Note that vvSlicer also check if the element is to be displayed according to + // the extent of the displayed object. + // These members have been introduced to fix Bug #1883. + bool mImageVisibility; + bool mOverlayVisibility; + bool mFusionVisibility; + bool mVFVisibility; + bool mFirstSetSliceOrientation; }; #endif