<div dir="ltr">Can you post the code?</div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jun 29, 2016 at 10:39 AM, Doug Hoppes <span dir="ltr"><<a href="mailto:dhoppes@mbfbioscience.com" target="_blank">dhoppes@mbfbioscience.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div lang="EN-US" link="blue" vlink="purple">
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Sorry about that…. Here’s more information…<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">In VTK Version 6.2.0 using the OpenGL flag, this is what we see in all 4 viewports, we see that the vtkimageactor looks fine.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u><img width="432" height="360" src="cid:image003.png@01D1D1F1.8D2F5CF0"><u></u><u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">However, we just moved to VTK Version 7.0.0 using the OpenGL2 flag. This is what we now see:<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u><img width="432" height="360" src="cid:image004.png@01D1D1F2.8FB66080"><u></u><u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Notice the clipping. The upper two viewports show nothing, the bottom viewport is correct and the rightmost viewport is clipped in the center of the viewport.
If we resize the overall vtk window, the viewport is still clipped in the center. It seems that there is no display to the right-side of the viewport. In the main right viewport, we can actually move the objects around without a problem but the results are
still clipped. <u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">We have seen this issue with really large vtkvolumes but it doesn’t happen all of the time. Using the vtkimageactor, this happens consistently. This problem
does not present itself with any generic vtkactors. <u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">I’ll also check the vtkImageSliceMapper code to see if I can get any information from it.<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Doug<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> David Gobbi [mailto:<a href="mailto:david.gobbi@gmail.com" target="_blank">david.gobbi@gmail.com</a>]
<br>
<b>Sent:</b> Wednesday, June 29, 2016 9:03 AM<br>
<b>To:</b> Doug Hoppes<br>
<b>Subject:</b> Re: [vtkusers] Viewport clipping<u></u><u></u></span></p>
<p class="MsoNormal"><u></u> <u></u></p>
<div>
<p class="MsoNormal">Hi Doug,<u></u><u></u></p>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">Please keep the discussion on the list. It's possible that the near/far clipping planes are too tight. When you reset the focal point, you can try calling SetClippingRange(near, far) at the same time.<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">Also, I hate to be redundant, but what version of VTK are you using? Do you see this only with vtkImageActor, or also with vtkVolume? It helps me help you if you answer these questions...<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal"> - David<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
<div>
<p class="MsoNormal">On Wed, Jun 29, 2016 at 6:45 AM, Doug Hoppes <<a href="mailto:dhoppes@mbfbioscience.com" target="_blank">dhoppes@mbfbioscience.com</a>> wrote:<u></u><u></u></p>
<div>
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Hey David!</span><u></u><u></u></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span><u></u><u></u></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> Thanks for responding. Here’s what we are seeing:</span><u></u><u></u></p>
<p class="MsoNormal"><span style="color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span><u></u><u></u></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">I can move the image in the 3D area without any problem…. It’s just that the image is clipped. We
have seen it happen with a couple of large images and I noticed that it happens when I try to reset the camera focal point.</span><u></u><u></u></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span><u></u><u></u></p>
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> David Gobbi [mailto:<a href="mailto:david.gobbi@gmail.com" target="_blank">david.gobbi@gmail.com</a>]
<br>
<b>Sent:</b> Wednesday, June 29, 2016 8:25 AM<br>
<b>To:</b> Doug Hoppes<br>
<b>Cc:</b> <a href="mailto:vtkusers@vtk.org" target="_blank">vtkusers@vtk.org</a><br>
<b>Subject:</b> Re: [vtkusers] Viewport clipping</span><u></u><u></u></p><div><div class="h5">
<div>
<div>
<p class="MsoNormal"> <u></u><u></u></p>
<div>
<div>
<div>
<p class="MsoNormal">On Wed, Jun 29, 2016 at 6:10 AM, Doug Hoppes <<a href="mailto:dhoppes@mbfbioscience.com" target="_blank">dhoppes@mbfbioscience.com</a>> wrote:<u></u><u></u></p>
<div>
<div>
<p class="MsoNormal">Hey all,<u></u><u></u></p>
<p class="MsoNormal"> <u></u><u></u></p>
<p class="MsoNormal"> Running into a critical issue and not sure where to turn. We’ve been using vtkViewport for a while and never seem to have an issue with them. However, just updated
the software and moved to OpenGL2 and now running into an issue. Some of the viewports seem to be clipped. I can move my objects without a problem in them but, in one case, vtkImageActor, the display is clipped.
<u></u><u></u></p>
<p class="MsoNormal"> <u></u><u></u></p>
<p class="MsoNormal"> Is there a particular place I can look at in the code to see what is happening? The vtkViewport code seems to have the correct port size. Where is the display
rendering done? I’ve noticed that, if I use a sphere actor or any general surface actor, there doesn’t seem to be a problem. It only happens when I’m rendering a volume or an image actor.<u></u><u></u></p>
</div>
</div>
<div>
<p class="MsoNormal"> <u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Hmm... I haven't seen anything like this. By "clipped", do you mean that the actor/volume is limited to a rectangle that is smaller than the viewport? Is this rectangle always
in the upper left corner of the viewport, or is it somewhere else? When you say "rendering a volume", do you mean rendered with a vtkVolume? If so, what volume mapper was used? What version of VTK?<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> <u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">For OpenGL2 the vtkImageActor rendering is done by Rendering/OpenGL2/vtkOpenGLImageSliceMapper.cxx, which in turn uses vtkTexture and vtkPolyDataMapper.<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> <u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> - David<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> <u></u><u></u></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div></div></div>
</div>
</div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
</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>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" rel="noreferrer" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtkusers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/vtkusers" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/vtkusers</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">Unpaid intern in BillsBasement at noware dot com<br></div>
</div>