if (!n_image_loaded) load_image_first_error();
window.AddROI(n_image_loaded-1,argv[i+1]);
i++; //skip roi name
+ } else if (current=="--contour") {
+ if (!n_image_loaded) load_image_first_error();
+ window.AddDCStructContour(n_image_loaded-1,argv[i+1]);
+ i++; //skip roi name
} else if (current=="--fusion") {
if (!n_image_loaded) load_image_first_error();
window.AddFusionImage(n_image_loaded-1,argv[i+1]);
//------------------------------------------------------------------------------
-void vvMainWindow::OpenDCStructContour()
+void vvMainWindow::AddDCStructContour(int index, QString file)
{
- if (mSlicerManagers.size() > 0) {
- QString Extensions = "Dicom Files ( *.dcm RS*)";
- Extensions += ";;All Files (*)";
- QString file = QFileDialog::getOpenFileName(this,tr("Merge Images"),mInputPathName,Extensions);
- if (file.isNull())
- return;
- int index = GetSlicerIndexFromItem(DataTree->selectedItems()[0]);
vvMeshReader reader;
reader.SetFilename(file.toStdString());
vvStructSelector selector;
AddContour(index,*i,selector.PropagationEnabled());
QApplication::restoreOverrideCursor();
}
+}
+
+//------------------------------------------------------------------------------
+void vvMainWindow::OpenDCStructContour()
+{
+ if (mSlicerManagers.size() > 0) {
+ QString Extensions = "Dicom Files ( *.dcm RS*)";
+ Extensions += ";;All Files (*)";
+ QString file = QFileDialog::getOpenFileName(this,tr("Merge Images"),mInputPathName,Extensions);
+ if (file.isNull())
+ return;
+ int index = GetSlicerIndexFromItem(DataTree->selectedItems()[0]);
+ AddDCStructContour(index, file);
}
}
//------------------------------------------------------------------------------
public slots:
///Allows the user to open and select various surfaces contained in a dicom-struct file
+ void AddDCStructContour(int index, QString file);
void OpenDCStructContour();
///Computes the midposition image of a 4D sequence with a VF and displays it
void ComputeMidPosition();