From 06d6cb727b421a62aba4ed31c7d7f17c3e7f2431 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?C=C3=A9cile=20Patte?= <cecile.patte@inria.fr>
Date: Wed, 28 Nov 2018 11:51:36 +0100
Subject: [PATCH] Need to instantiate before use, right?

---
 generated_image_expressions_cpp.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/generated_image_expressions_cpp.py b/generated_image_expressions_cpp.py
index e193a36..548e326 100644
--- a/generated_image_expressions_cpp.py
+++ b/generated_image_expressions_cpp.py
@@ -61,8 +61,8 @@ public:
         reader->SetFileName(filename);
         reader->Update();
 
-        image = reader->GetOutput();
         // image = vtkSmartPointer<vtkImageData>::New(); // MG20180913: another way to instantiate object
+        image = reader->GetOutput();
 
         static_scaling = getStaticScalingFactor(image->GetScalarTypeAsString());
 
-- 
GitLab