<DIV>
<DIV>
<DIV>Hi,</DIV>
<DIV>&nbsp;</DIV>
<DIV>I read your code example and I think this could help me because this seems to be right.</DIV>
<DIV>&nbsp;</DIV>
<DIV>- When I display directly on screen, the image "essai.bmp" saved is the exact copy of what is rendered on screen: here is my code where everything is fine:&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>
<DIV><STRONG>// render to memory with&nbsp;m_pRenderWindow as a vtkWin32OpenGLRenderWindow.<BR>m_pRenderWindow-&gt;Render();<BR></STRONG></DIV>
<DIV><STRONG>vtkWindowToImageFilter* renSrc = vtkWindowToImageFilter::New();<BR>renSrc-&gt;SetInput(m_pRenderer);</STRONG></DIV>
<DIV><STRONG>vtkBMPWriter* writer = vtkBMPWriter::New();<BR>writer-&gt;SetInput(renSrc-&gt;GetOutput());<BR>writer-&gt;SetFileName("essai.bmp");</STRONG></DIV>
<DIV><STRONG>writer-&gt;Write();</STRONG></DIV></DIV>
<DIV>&nbsp;</DIV>
<DIV>- However, to avoid flickering on screen, I want to render off screen by double buffering. Here is the new code. Just is added the line <STRONG><BR></DIV>
<DIV></STRONG>// render to memory with&nbsp;m_pRenderWindow as a vtkWin32OpenGLRenderWindow.<BR><STRONG>int *size = m_pRenderWindow-&gt;GetSize();<BR>m_pRenderWindow-&gt;SetupMemoryRendering(size[0], size[1], GetDC() -&gt;GetSafeHdc());<BR></STRONG>m_pRenderWindow-&gt;Render();<BR></DIV>
<DIV>vtkWindowToImageFilter* renSrc = vtkWindowToImageFilter::New();<BR>renSrc-&gt;SetInput(m_pRenderer);</DIV>
<DIV>vtkBMPWriter* writer = vtkBMPWriter::New();<BR>writer-&gt;SetInput(renSrc-&gt;GetOutput());<BR>writer-&gt;SetFileName("essai.bmp");</DIV>
<DIV>writer-&gt;Write();</DIV>
<DIV><BR><STRONG>m_pRenderWindow-&gt;ResumeScreenRendering();</STRONG></DIV>
<DIV>&nbsp;</DIV>
<DIV><STRONG>Problem: The image saved in essai.bmp is white.</STRONG> How could this be? I really don't understand.I check class vtkWin32OpenGLRenderWindow and I am stuck on this problem for 3 days. </DIV>
<DIV>&nbsp;</DIV>
<DIV>Please help</DIV>
<DIV>Isa</DIV></DIV></DIV><p>
                <hr size=1> 
<b><font color=#FF0000>Appel audio GRATUIT</font> partout dans le monde</b> avec le nouveau Yahoo! Messenger<br> 
<a href="http://us.rd.yahoo.com/messenger/mail_taglines/default/*http://fr.messenger.yahoo.com">Téléchargez le ici !</a>