- BSD See included LICENSE.txt file
- CeCILL-B http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
======================================================================-====*/
+
+// vv
#include "vvToolRigidReg.h"
-#include <QComboBox>
-#include <QCursor>
-#include <QApplication>
+#include "vvImageReader.h"
+#include "vvSlicer.h"
+
+// vtk
#include <vtkImageData.h>
#include <vtkSmartPointer.h>
#include <vtkTransform.h>
-#include <vvImageReader.h>
-#include "vvImage.h"
-#include "vvSlicer.h"
-#include <QFile>
+
+// clitk
#include "clitkTransformUtilities.h"
-#include <QString>
+
+// qt
#include <QMessageBox>
-#include <vvMainWindow.h>
#include <QFileDialog>
#include <QTextStream>
+#include <QComboBox>
+#include <QCursor>
+
//------------------------------------------------------------------------------
// Create the tool and automagically (I like this word) insert it in
// the main window menu.
{
// GUI Initialization
Ui_vvToolRigidReg::setupUi(mToolWidget);
- QSize qsize;
- qsize.setHeight(470);
- qsize.setWidth(850);
- mToolWidget->setFixedSize(qsize);
+ // QSize qsize;
+// qsize.setHeight(470);
+// qsize.setWidth(850);
+// mToolWidget->setFixedSize(qsize);
// Set how many inputs are needed for this tool
}
//------------------------------------------------------------------------------
+
//------------------------------------------------------------------------------
void vvToolRigidReg::SaveFile()
{
//Write the Transformation Matrix
QString f1 = QFileDialog::getSaveFileName(this, tr("Save Transformation Matrix File"),
- "/home",
- tr("Text (*.mat *.txt *.doc *.rtf)"));
+ mMainWindow->GetInputPathName(),
+ tr("Text (*.mat *.txt *.doc *.rtf)"));
QFile file1(f1);
std::vector<QString> transparameters;
QString line1;
QString file1 = QFileDialog::getOpenFileName(
this,
"Choose the Transformation Parameters file",
- "/home",
+ mMainWindow->GetInputPathName(),
"Text (*.mat *.txt *.rtf *.doc)");
if (file1.isEmpty())
return;
//In the Order or Y X Z //
//now postmultiply for the rotations
- SetTransform(0,0,0,0,0,-round(orientations[2]),false);
- SetTransform(0,0,0,-round(orientations[0]),0,0,false);
- SetTransform(0,0,0,0,-round(orientations[1]),0,false);
+ SetTransform(0,0,0,0,0,-rint(orientations[2]),false);
+ SetTransform(0,0,0,-rint(orientations[0]),0,0,false);
+ SetTransform(0,0,0,0,-rint(orientations[1]),0,false);
transform->GetPosition(translations);
transform->Identity();