[ITK] [ITK-users] Problem with itkImageToVTKImageFilter
SiavashK
siavashk at ece.ubc.ca
Thu Jul 9 15:26:07 EDT 2015
Hello,
I am having a bit of issue with itkImageToVTKImageFilter. My goal is simple,
I would like to convert an ITK image to a VTK image in order to display it
in a QVTKWidget. To this end, I have created an instance
itkImageToVTKImageFilter, to which I feed my ITK Image.
The issue is that the size/spacing of my images change depending on the
state of my GUI. As I have read through the mailing list, this is typically
handled by calling UpdateLargestPossibleRegion() instead of Update() on the
filter (for example see this
<http://www.itk.org/ITKExamples/src/Core/Common/ReRunPipelineWithChangingLargestPossibleRegion/Documentation.html>
).
My issue is that calling UpdateLargestPossibleRegion() does not seem to
produce any output.
I have attached a small working example to illustrate this. I would be happy
if anyone could tell me what I am doing wrong, or if there is a bug in this
filter.
Usage is:
>> imageToVTKImageTest.exe 1.png 2.png
CMakeLists.txt
<http://itk-insight-users.2283740.n2.nabble.com/file/n7587561/CMakeLists.txt>
imageToVTKImageTest.cxx
<http://itk-insight-users.2283740.n2.nabble.com/file/n7587561/imageToVTKImageTest.cxx>
1.png <http://itk-insight-users.2283740.n2.nabble.com/file/n7587561/1.png>
2.png <http://itk-insight-users.2283740.n2.nabble.com/file/n7587561/2.png>
--
View this message in context: http://itk-insight-users.2283740.n2.nabble.com/Problem-with-itkImageToVTKImageFilter-tp7587561.html
Sent from the ITK Insight Users mailing list archive at Nabble.com.
_____________________________________
Powered by www.kitware.com
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Kitware offers ITK Training Courses, for more information visit:
http://www.kitware.com/products/protraining.php
Please keep messages on-topic and check the ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ
Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/insight-users
More information about the Community
mailing list