<div dir="ltr"><div>Try,<br>ResetCameraClippingRange()<br></div>on your renderer.<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Sat, Apr 20, 2013 at 11:08 AM, Marc Huber <span dir="ltr">&lt;<a href="mailto:marchuber.hft@gmx.de" target="_blank">marchuber.hft@gmx.de</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Sorry to start this again.<br>
Reseting the camera solves the problem but then I am at the original point of the camera again.<br>
What I wanted was to transform the camera and stay at this place to take screenshots.<br>
When I repaint my RendererWindow not all content is redrawn. After I move the mousewheel it&#39;s correctly displayed.<br>
The problem doesn&#39;t occur always. Just with some objects with specific transformations.<br>
I have attached a screenshot what the problem is. The upper window is how it is created and the lower is after I moved the mouse wheel.<br>
I tried to just perform a zoom event and it doesn&#39;t help.<br>
<br>
Best regards<br>
Marc<br>
<br>
Am 4/16/2013 2:28 PM, schrieb Marc Huber:<div class="HOEnZb"><div class="h5"><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
thx! Reset the camera again after its movement solved the problem.<br>
<br>
Am 4/16/2013 1:58 PM, schrieb David Doria:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Tue, Apr 16, 2013 at 7:34 AM, Marc Huber &lt;<a href="mailto:marchuber.hft@gmx.de" target="_blank">marchuber.hft@gmx.de</a>&gt; wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi,<br>
<br>
i have the problem, that if i load polydata to a renderer window depending<br>
on the dataset sometimes the object is shown directly and sometimes i have<br>
to move the mousewheel one time and then the object gets visible.<br>
For each object my camera is set depending on the center point of my<br>
polydata.<br>
I do a repaint but it doesn&#39;t help me.<br>
<br>
Has anyone an idea what the problem might be?<br>
Or can someone just tell me how i perform a simple event zooming in or out<br>
one time?<br>
<br>
My Code:<br>
     double cent[3], bounds[6], lenX, lenY, lenZ, max;<br>
     stlActor-&gt;GetMapper()-&gt;<u></u>GetCenter(cent);<br>
     stlActor-&gt;GetMapper()-&gt;<u></u>GetBounds(bounds);<br>
     lenX=bounds[1]-bounds[0];<br>
     lenY=bounds[3]-bounds[2];<br>
     lenZ=bounds[5]-bounds[4];<br>
     max=lenX;<br>
     if (lenY &gt; max) {max=lenY;}<br>
     if (lenZ &gt; max) {max=lenZ;}<br>
<br>
     cam-&gt;SetFocalPoint(cent[0],<u></u>cent[1],cent[2]);<br>
     cam-&gt;SetViewUp(0,0,1);<br>
     cam-&gt;SetPosition(-2*max,0,0);<br>
     if (direction==0)  //azimuth<br>
     {<br>
         cam-&gt;Azimuth(degree);<br>
     }<br>
     else if (direction==1) //elevation<br>
     {<br>
         cam-&gt;Elevation(degree);<br>
     }<br>
     renderer-&gt;SetActiveCamera(cam)<u></u>;<br>
     ui.qvtkWidget-&gt;repaint();<br>
</blockquote>
<br>
Did you try renderer-&gt;ResetCamera()? Otherwise, please post compilable<br>
code that demonstrates the problem. The code should be as simple as<br>
possible (remove the Qt dependency, hard code data to view, etc.)<br>
<br>
David<br>
<br>
</blockquote>
<br>
<br>
</blockquote>
<br>
<br>
-- <br>
Best regards / Mit freundlichen Grüßen<br>
Marc Huber<br>
<br>
</div></div><br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Unpaid intern in BillsBasement at noware dot com<br>
</div>