<DIV>
<DIV>&nbsp;Hi,</DIV>
<DIV>&nbsp;</DIV>
<DIV>Sorry to bother you again. </DIV>
<DIV>&nbsp;</DIV>
<DIV>I tried what you indicated me to scale my image into a window I passed.</DIV>
<DIV>&nbsp;</DIV>
<DIV><STRONG>I have no error at compilation. However, my image is not scaled at execution. </STRONG></DIV>
<DIV>&nbsp;</DIV>
<DIV>Is there any fault in this code:</DIV>
<DIV>&nbsp;</DIV>
<DIV>viewer-&gt;SetInput(reader-&gt;GetOutput());</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;<STRONG>vtkRenderer* ren1 = viewer-&gt;GetRenderer();<BR>&nbsp;ren1-&gt;GetActiveCamera()-&gt;ParallelProjectionOn();&nbsp;<BR>ren1-&gt;GetActiveCamera()-&gt;SetParallelScale(0.5);</STRONG></DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;//display the image in the frame<BR>&nbsp;viewer-&gt;SetParentId(this-&gt;m_hWnd);</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;//execute<BR>&nbsp;viewer-&gt;Render();&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>thanks in advance, </DIV>
<DIV>&nbsp;</DIV>
<DIV>Isabelle<BR><BR><BR><B><I>Goodwin Lawlor &lt;goodwin.lawlor@ucd.ie&gt;</I></B> a écrit:</DIV>
<BLOCKQUOTE class=replbq style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #1010ff 2px solid">Hi Isabelle,<BR><BR>Have a look at this example:<BR><BR>http://www.bioengineering-research.com/vtk/vhpreader.tcl<BR><BR>or<BR><BR>http://www.bioengineering-research.com/vtk/BackgroundImage.tcl<BR><BR><BR>here's the bit you need: (app is an image; numCol and numRow are the image<BR>dims)<BR><BR>vtkImageActor ia<BR>ia SetInput [app GetOutput]<BR>ia InterpolateOff<BR>vtkRenderer ren1<BR>ren1 AddActor ia<BR>ren1 SetBackground 1 1 1<BR>vtkRenderWindow renWin<BR>renWin AddRenderer ren1<BR>renWin SetSize [expr $numCol / 4] [expr $numRow / 4]<BR>vtkInteractorStyleImage istyle<BR>vtkRenderWindowInteractor iren<BR>iren SetRenderWindow renWin<BR>iren SetInteractorStyle istyle<BR>[ren1 GetActiveCamera] ParallelProjectionOn<BR>#fit the image to the render window<BR>[ren1 GetActiveCamera] SetParallelScale [expr $numRow / 2]<BR>renWin Render<BR><BR><BR>hth<BR><BR>Goodwin<BR><BR><BR>"Renaud Isabelle"
 <RENAUISA@YAHOO.FR>wrote in message<BR>news:20050525115733.8984.qmail@web26108.mail.ukl.yahoo.com...<BR>Hi everyone,<BR><BR>I made a 2D image displayed in a window by using<BR>vtkImageViewer-&gt;SetParentId(this-&gt;m_hWnd). It works well, but my image is<BR>still displayed with its own dimensions. What I would like to do is find a<BR>way to display it in order to fit the dimensions of my window, something<BR>which could stretch my image.<BR><BR>Could someone suggest me something? I am not sure if it is a VTK or ITK<BR>problem.<BR><BR>By the way, what is the difference between vtkImageViewer and<BR>vtkImageViewer2?<BR><BR>Thanks in advance,<BR><BR>Isabelle<BR><BR><BR>Découvrez le nouveau Yahoo! Mail : 1 Go d'espace de stockage pour vos mails,<BR>photos et vidéos !<BR>Créez votre Yahoo! Mail<BR><BR><BR><BR>_______________________________________________<BR>This is the private VTK discussion list.<BR>Please keep messages on-topic. Check the FAQ
 at:<BR>http://www.vtk.org/Wiki/VTK_FAQ<BR>Follow this link to subscribe/unsubscribe:<BR>http://www.vtk.org/mailman/listinfo/vtkusers<BR><BR><BR><BR>_______________________________________________<BR>This is the private VTK discussion list. <BR>Please keep messages on-topic. Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ<BR>Follow this link to subscribe/unsubscribe:<BR>http://www.vtk.org/mailman/listinfo/vtkusers<BR></BLOCKQUOTE></DIV><p>
                <hr size=1> 
Découvrez le nouveau Yahoo! Mail : <font color="red">1 Go d'espace</font> de stockage pour vos mails, photos et vidéos !<br><a href="http://us.rd.yahoo.com/mail_fr/mail_campaigns/splash/taglines_1go/default/*http://fr.promotions.yahoo.com/mail/creer28.html" target="_blank">Créez votre Yahoo! Mail</a>