<div dir="ltr"><div>Hi Enzo,</div><div><br></div><div>The artifact might be due to this bug, which was recently fixed in the master branch:</div><div><br></div><a href="https://gitlab.kitware.com/vtk/vtk/merge_requests/1279">https://gitlab.kitware.com/vtk/vtk/merge_requests/1279</a><div><br></div><div>Cubic interpolation is much faster than Sinc.<br></div><div><br></div><div> - David<br><div><br></div><div><br></div><div><br><div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Jun 23, 2016 at 7:34 AM, Enzo Matsumiya <span dir="ltr"><<a href="mailto:enzo.matsumiya@gmail.com" target="_blank">enzo.matsumiya@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div style="word-wrap:break-word">Hi,<div><br></div><div>I got the result I wanted (quality-wise) adding a vtkImageSincInterpolator to the image reslice within vtkResliceCursorRepresentation. I think the default was using the nearest neighbor algorithm.</div><div><div><br></div><div><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">But now I have 2 problems:</div><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><br></div><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">- The performance decrease was huge. Is there any way to improve that?</div><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">- Here are 2 images showing my second issue. There are artifacts *only* in orthogonal slices, and also only in coronal and sagittal. The artifacts are gone when I oblique reslice:</div><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><br></div><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><a href="http://oi65.tinypic.com/dcga2x.jpg" target="_blank">http://oi65.tinypic.com/dcga2x.jpg</a> - with artifacts</div><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><a href="http://oi64.tinypic.com/30cuoug.jpg" target="_blank">http://oi64.tinypic.com/30cuoug.jpg</a> - oblique reslicing, without artifacts</div><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word"><br></div><div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">I'm guessing it's a bug in the interpolator because it really looks like some mathematical bug, but I could be wrong of course.</div><div><br></div><div><br></div><div>Can anyone help me out?</div><br>
</div><div><div class="h5">
<br><div><blockquote type="cite"><div>On Jun 22, 2016, at 12:24, Enzo Matsumiya <<a href="mailto:enzo.matsumiya@gmail.com" target="_blank">enzo.matsumiya@gmail.com</a>> wrote:</div><br><div><div style="word-wrap:break-word">Hi Sankhesh,<div><br></div><div>Thanks for the reply.</div><div><br></div><div>By quality I mean that the first image looks crispy, while the second one looks very smooth.</div><div>But now that you said, I will see if I can find any data type inconsistency accross my code.</div><div><br></div><div>ManageWindowLevel is enabled on vtkResliceCursorWidget.</div><div><br></div><div><br></div><div>Thanks again,</div><div><br></div><div>Enzo<br><div><br>
</div>
<br><div><blockquote type="cite"><div>On Jun 22, 2016, at 11:59, Sankhesh Jhaveri <<a href="mailto:sankhesh.jhaveri@kitware.com" target="_blank">sankhesh.jhaveri@kitware.com</a>> wrote:</div><br><div><div dir="ltr"><div style="font-family:verdana,sans-serif;font-size:small;color:rgb(11,83,148)">Enzo,</div><div style="font-family:verdana,sans-serif;font-size:small;color:rgb(11,83,148)"><br></div><div style="font-family:verdana,sans-serif;font-size:small;color:rgb(11,83,148)">What do you mean by quality?</div><div style="font-family:verdana,sans-serif;font-size:small;color:rgb(11,83,148)"><br></div><div style="font-family:verdana,sans-serif;font-size:small;color:rgb(11,83,148)">Looking at the two images, the resolution looks the same to me. I see there is a difference in the range of pixel values between the two images. This could either be due to the data type differences in the output image or actual data value differences. Do you have ManageWindowLevel enabled for vtkResliceCursorWidget?</div><div class="gmail_extra"><div><div data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div><br></div><span style="color:rgb(11,83,148)"><span style="font-family:verdana,sans-serif">Sankhesh</span></span><div><b></b><br> </div></div></div></div></div></div></div></div></div></div></div></div></div></div></div>
<br><div class="gmail_quote">On Wed, Jun 22, 2016 at 10:49 AM, Enzo Matsumiya <span dir="ltr"><<a href="mailto:enzo.matsumiya@gmail.com" target="_blank">enzo.matsumiya@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex"><div style="word-wrap:break-word">Hi,<div><br></div><div>I'm using vtkResliceCursorWidget for oblique reslicing on a CT set.</div><div>But I'm getting really bad image quality. Here is an example from my app:</div><div><br></div><div><a href="http://oi68.tinypic.com/1z55cop.jpg" target="_blank">http://oi68.tinypic.com/1z55cop.jpg</a></div><div><br></div><div>And here is one (although non-oblique) from other software:</div><div><br></div><div><a href="http://oi68.tinypic.com/2lidi6p.jpg" target="_blank">http://oi68.tinypic.com/2lidi6p.jpg</a></div><div><br></div><div>I would like to know if there's a way to improve the quality on my app.</div><div><br></div><div><br></div><div>Thanks</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></div></div>
</div></blockquote></div><br></div></div></div></blockquote></div><br></div></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></div></div></div></div></div>