<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <meta content="text/html; charset=ISO-8859-15"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#ffffff" text="#003333">
    Found the problem, SetPosition was needing coordinated in pixel but
    SetPosition2 in normalized format.<br>
    So with this code now it works:<br>
    <br>
               
ImageActor-&gt;GetPositionCoordinate()-&gt;SetCoordinateSystemToNormalizedViewport();<br>
               
ImageActor-&gt;GetPosition2Coordinate()-&gt;SetCoordinateSystemToNormalizedViewport();<br>
                ImageActor-&gt;SetPosition(0.25,0.25);<br>
                ImageActor-&gt;SetWidth(0.5);<br>
                ImageActor-&gt;SetHeight(0.4);<br>
    <br>
    Regards<br>
    <br>
    <br>
    Il 02/03/2011 14:28, Matteo ha scritto:
    <blockquote cite="mid:4D6E45F8.2030600@yahoo.it" type="cite">
      <meta http-equiv="content-type" content="text/html;
        charset=ISO-8859-15">
      Hi<br>
      I need to display an image in a part of the screen.<br>
      I'm using the chain:<br>
vtkImageImport-&gt;vtkImageMapToColors-&gt;vtkImageMapper-&gt;vtkActor2D-&gt;vtkRenderer<br>
      <br>
      I have set Position and Position2 of vtkActor2D to set the image
      box.<br>
      <br>
      It looks is not enough...<br>
      <br>
      So I set vtkImageMapper::RenderToRectangleOn() hoping for a
      solution, but only Position2 is rightly imported, the image starts
      always from (0,0) (any 'Position' looks ignored)<br>
      <br>
      [I check into vtkImageMapper.cxx and the flag RenderToRectangle is
      never used...this is also strange...]<br>
      <br>
      Any help?<br>
      Thank you
      <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Powered by <a class="moz-txt-link-abbreviated" href="http://www.kitware.com">www.kitware.com</a>

Visit other Kitware open-source projects at <a class="moz-txt-link-freetext" href="http://www.kitware.com/opensource/opensource.html">http://www.kitware.com/opensource/opensource.html</a>

Please keep messages on-topic and check the VTK FAQ at: <a class="moz-txt-link-freetext" href="http://www.vtk.org/Wiki/VTK_FAQ">http://www.vtk.org/Wiki/VTK_FAQ</a>

Follow this link to subscribe/unsubscribe:
<a class="moz-txt-link-freetext" href="http://www.vtk.org/mailman/listinfo/vtkusers">http://www.vtk.org/mailman/listinfo/vtkusers</a>
</pre>
    </blockquote>
  </body>
</html>