<div dir="ltr"><div>Hi Manole,<br><br>Is the the 2KB PNG file valid and defines an empty/all black image ?<br><br></div>Joachim<br></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><div dir="ltr"><b>Joachim Pouderoux</b><br><blockquote style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><font size="1"><i>PhD, Technical Expert</i></font><br><b><font size="1"><a href="http://www.kitware.fr" target="_blank">Kitware SAS</a></font></b><br></blockquote>
</div></div></div>
<br><div class="gmail_quote">2015-07-22 16:47 GMT+02:00 Manole Buican <span dir="ltr"><<a href="mailto:manole.buican@terrasigna.com" target="_blank">manole.buican@terrasigna.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div>
<div style="direction:ltr;font-family:Tahoma;color:#000000;font-size:10pt">Hi all,
<br>
<br>
<span>Code like </span><br>
<br>
<span>void DlgResVis2D::saveTmpPicture(QString &filename) </span><br>
<span>{ </span><br>
<span> vtkNew<vtkWindowToImageFilter> windowToImageFilter; </span><br>
<span> vtkWindow* pRenderWindow = (vtkWindow *) m_pView->GetRenderWindow();
</span><br>
<br>
<span> windowToImageFilter->SetInput(pRenderWindow); </span><br>
<span> windowToImageFilter->SetMagnification(1); </span><br>
<span> windowToImageFilter->SetInputBufferTypeToRGBA(); </span><br>
<span> windowToImageFilter->Update(); </span><br>
<br>
<span> vtkSmartPointer <vtkPNGWriter> writer = vtkSmartPointer <vtkPNGWriter>::New();
</span><br>
<span> writer->SetFileName(filename.<span>toAscii</span>());
</span><br>
<span> writer->SetInputConnection(windowToImageFilter->GetOutputPort()); </span>
<br>
<span> writer->Write(); </span><br>
<span>} </span><br>
<br>
<span><span>exports</span> a picture in <span>
PNG</span> on 5 computers. On the sixth computer produce only a 2KB empty <span>
PNG</span> file (no error is prompted), while on each other 5 computers produce 35KB
<span>PNG</span> file with the same <span>
image</span>. </span><br>
<span>Does anybody encounter the same behavior? </span><br>
<br>
<span>Thx in advance, </span><br>
<span>Manole Buican </span><br>
</div>
</div>
<br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtk-developers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtk-developers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/vtk-developers" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/vtk-developers</a><br>
<br>
<br></blockquote></div><br></div>