Hi everyone,<br>I have some problem. I would like to save *.mhd file from <span><span class="highlight"><span style="font-family: courier new,monospace;">QVTKWidget</span> component. I tried to seach on google, but any solution. <br>
<br><span style="font-family: courier new,monospace;">        qVTK3-&gt;setAutomaticImageCacheEnabled(true);</span><br style="font-family: courier new,monospace;"><span style="font-family: courier new,monospace;">        vtkSmartPointer&lt;vtkMetaImageWriter&gt; writer = vtkSmartPointer&lt;vtkMetaImageWriter&gt;::New();</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;">        qVTK3-&gt;saveImageToCache();</span><br style="font-family: courier new,monospace;"><span style="font-family: courier new,monospace;">        writer-&gt;SetInput(qVTK3-&gt;cachedImage());</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;">        writer-&gt;SetFileName(fileName);</span><br style="font-family: courier new,monospace;"><span style="font-family: courier new,monospace;">        std::string  str = fileName + &quot;.raw&quot;;</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;">        writer-&gt;SetRAWFileName(str.c_str());</span><br style="font-family: courier new,monospace;"><span style="font-family: courier new,monospace;">        writer-&gt;Write();<br>
<font face="arial,helvetica,sans-serif"><br><span style="font-family: courier new,monospace;">qVTK3</span> is </font></span></span></span><span><span class="highlight"><span style="font-family: courier new,monospace;">QVTKWidget</span></span></span><span><span class="highlight"><span style="font-family: courier new,monospace;"><font face="arial,helvetica,sans-serif">.<br>
<br>This code save empty files... <br>I have to recomend, that I loaded *.mha or *.mhd files.<br>I will be very happy for each help...<br>Thanks a lot<br></font></span></span></span>