]> Creatis software - clitk.git/blobdiff - common/vvImage.txx
Copy macro files for log
[clitk.git] / common / vvImage.txx
index 90eeb02338e21408be4854687b1ab5969ef1febc..a6d37c8cbbd8f0447f69c990235fa0963afedb53 100644 (file)
@@ -47,7 +47,13 @@ void vvImage::AddItkImage(TItkImageType *input)
     (*matrix)[i][3] += input->GetOrigin()[i];
   }
 
-  mTransform->SetMatrix(matrix);
+  // GetDirection provides the forward transform, vtkImageReslice wants the inverse
+  matrix->Invert();
+
+  mTransform.push_back(vtkSmartPointer<vtkTransform>::New());
+  mTransform.back()->SetMatrix(matrix);
+  //META DATA
+  mDictionary.push_back(&(input->GetMetaDataDictionary()));
 }
 //--------------------------------------------------------------------