X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=vv%2FvvToolRigidReg.h;h=6dacdba3c9843b79f162318231d616c9b5093a38;hb=ff1d5b8af965e75ecdbc1b0cbff0dad6f3b3c511;hp=cce7aba3329a462e99b027a2707147045d48b302;hpb=9eefc9caddf768669a85880cb3bc91c104d3d529;p=clitk.git diff --git a/vv/vvToolRigidReg.h b/vv/vvToolRigidReg.h index cce7aba..6dacdba 100644 --- a/vv/vvToolRigidReg.h +++ b/vv/vvToolRigidReg.h @@ -1,7 +1,8 @@ + /*========================================================================= Program: vv http://www.creatis.insa-lyon.fr/rio/vv - Authors belong to: + Authors belong to: - University of LYON http://www.universite-lyon.fr/ - Léon Bérard cancer center http://oncora1.lyon.fnclcc.fr - CREATIS CNRS laboratory http://www.creatis.insa-lyon.fr @@ -25,18 +26,20 @@ #include "vvMainWindowBase.h" #include "vvMainWindow.h" #include "ui_vvToolRigidReg.h" +#include "vtkMatrix4x4.h" +#include "clitkAffineRegistration_ggo.h" //------------------------------------------------------------------------------ class vvToolRigidReg: - public vvToolWidgetBase, - public vvToolBase, - private Ui::vvToolRigidReg + public vvToolWidgetBase, + public vvToolBase, + private Ui::vvToolRigidReg { Q_OBJECT - public: +public: vvToolRigidReg(vvMainWindowBase * parent=0, Qt::WindowFlags f=0); ~vvToolRigidReg(); - virtual void InputIsSelected(std::vector & m); + virtual void InputIsSelected(std::vector & m); public slots: virtual void apply(); virtual bool close(); @@ -47,26 +50,52 @@ public slots: SetToolMenuName("Register"); SetToolIconFilename(":/common/icons/register.png"); SetToolTip("Register Image."); + SetToolExperimental(true); } - void SetXvalue(); - void SetYvalue(); - void SetZvalue(); - void UpdateXtranslider(); - void UpdateYtranslider(); - void UpdateZtranslider(); - void UpdateXrotslider(); - void UpdateYrotslider(); - void UpdateZrotslider(); - void SetOverlay(); + virtual void GetArgsInfoFromGUI(); + void SetOverlay(vvImage::Pointer Image); + void RemoveOverlay(); + void SetXvalue(); + void SetYvalue(); + void SetZvalue(); + void Render(); + void UpdateTextEditor(vtkMatrix4x4 *matrix,QTextEdit *textEdit); + void UpdateTransform_sliders(); + void UpdateTransform_sb(); + void UpdateTransform(bool slider_enabled); + void AutoRegister(); + void SaveFile(); + void ReadFile(bool matrix_given); + void LoadFile(); + void ResetTransform(); + void SetRotationCenter(); + void SetSliderRanges(); + void InitializeSliders(double xtrans,double ytrans, double ztrans, double xrot, double yrot, double zrot,bool sliders); + void TransformSelect(); + void OptimizerSelect(); + void InterpolatorSelect(); + void MetricSelect(); + void OutputSelect(); + void SaveTextEdit(); + void CmdlineParser(int override, int initialize); + void Presets(); + void UpdateTextEditor2(); + void CheckRigidReg(); //Deformable or Rigid + void CheckDeformableReg(); protected: Ui::vvToolRigidReg ui; vvSlicerManager * mInput1; vvSlicerManager * mInput2; vvMainWindow * mWindow; + std::string mConfigFile; bool mTwoInputs; - double * origin; + std::vector mImageSize; + args_info_clitkAffineRegistration mArgsInfo; + double mInitialMatrix[16]; + void SetTransform(double tX, double tY, double tZ, double aX, double aY, double aZ,bool update); + void SetTransform(vtkMatrix4x4 * matrix); }; // end class vvToolRigidReg //------------------------------------------------------------------------------ #endif - +