[clitk-commits-list] Clitk branch master updated. v1.2.0-606-g3c2462e

root root at tux.creatis.insa-lyon.fr
Fri Dec 16 11:56:07 CET 2011


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Clitk".

The branch, master has been updated
       via  3c2462eafabcf428b4d2775c414a7b5f62511d3f (commit)
      from  fd4a7d9e81f324f028ba735bdc88f51f4ede5df3 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.creatis.insa-lyon.fr/pubgit/?p=clitk.git;a=commitdiff;h=3c2462eafabcf428b4d2775c414a7b5f62511d3f

commit 3c2462eafabcf428b4d2775c414a7b5f62511d3f
Author: Romulo Pinho <romulo.pinho at lyon.unicancer.fr>
Date:   Fri Dec 16 11:55:00 2011 +0100

    dicom structure in cmd line
    
    - --contour <FILE>
    - in the same way as overlay/fusion/vf

diff --git a/vv/vv.cxx b/vv/vv.cxx
index 1fb357e..f3011e6 100644
--- a/vv/vv.cxx
+++ b/vv/vv.cxx
@@ -134,6 +134,10 @@ int main( int argc, char** argv )
           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]);
diff --git a/vv/vvMainWindow.cxx b/vv/vvMainWindow.cxx
index 5bdc978..b102e62 100644
--- a/vv/vvMainWindow.cxx
+++ b/vv/vvMainWindow.cxx
@@ -491,15 +491,8 @@ void vvMainWindow::OpenVTKContour()
 
 
 //------------------------------------------------------------------------------
-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;
@@ -519,6 +512,19 @@ void vvMainWindow::OpenDCStructContour()
         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);
   }
 }
 //------------------------------------------------------------------------------
diff --git a/vv/vvMainWindow.h b/vv/vvMainWindow.h
index 12aaaf1..23ee6f4 100644
--- a/vv/vvMainWindow.h
+++ b/vv/vvMainWindow.h
@@ -73,6 +73,7 @@ class vvMainWindow: public vvMainWindowBase,
 
 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();

-----------------------------------------------------------------------

Summary of changes:
 vv/vv.cxx           |    4 ++++
 vv/vvMainWindow.cxx |   22 ++++++++++++++--------
 vv/vvMainWindow.h   |    1 +
 3 files changed, 19 insertions(+), 8 deletions(-)


hooks/post-receive
-- 
Clitk


More information about the Clitk-commits-list mailing list