For the ones who do not know, just add reslice.AutoCropOutputOn() and you will get it done. Remember that The AutoCropOutputOn() will not work if you call SetOutputSpacing(),<div>SetOutputOrigin(), or SetOutputExtent(). Make sure that you do not call any of these three methods on your reslice object.</div>
<div><br></div><div>Thanks to David Gobbi for this info!</div><div><br></div><div><br></div><div>Joao</div><div><br></div><br><div class="gmail_quote">On 21 January 2013 09:23, Joćo Domingos <span dir="ltr"><<a href="mailto:joao.sousa.domingos@gmail.com" target="_blank">joao.sousa.domingos@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hey again,<div><br></div><div>Does anyone have any idea to this problem? I guess it is something simple..</div><div><br>
</div><div>Is this the answer <a href="http://vtk.1045678.n5.nabble.com/vtkImageReslice-axes-direction-based-on-a-vtkPlane-td4825775.html" target="_blank">http://vtk.1045678.n5.nabble.com/vtkImageReslice-axes-direction-based-on-a-vtkPlane-td4825775.html</a>? Meaning: VTK 5.10, that I guess includes <span style="font-size:13px;font-family:Verdana,Geneva,Helvetica,Arial,sans-serif">vtkImageResliceMapper,</span> and use of this class and method called SetSlicePlane() ?</div>
<div><br></div><div>Many thanks for your time,</div><div>Joao</div><div class="HOEnZb"><div class="h5"><div><br></div><div><br><div class="gmail_quote">On 17 January 2013 10:07, Joćo Domingos <span dir="ltr"><<a href="mailto:joao.sousa.domingos@gmail.com" target="_blank">joao.sousa.domingos@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Dear folks,<div><br></div><div>Given the following:</div><div><div><br></div><div> reslice = vtk.vtkImageReslice()</div>
<div> reslice.SetInputConnection(self.image_reader.GetOutputPort())</div><div> reslice.SetOutputDimensionality(2)</div>
<div> reslice.SetInterpolationModeToCubic()</div></div><div> reslice.SetResliceAxes(axes_matrix_from_vtkMatrix4x4)<span style="white-space:pre-wrap">        </span></div><div><br></div><div>I am able to extract the 2D slice I want from my 3D volume, but it is shortened on the sides and cuts both the right and left side of the volume (cone). The height of the resulting slice is fine and includes the whole cone. Imagining the volume is a cube, the resulting slice is a rectangle (shortened on the sides).</div>
<div><br></div><div>How can I choose the dimension of the resulting slice to include the whole cone, i.e. basically how can I slice the whole volume?</div><div><br></div><div><br></div><div>Many thanks in advance!</div><div>
<br></div><div>Joao</div><div><br></div><div><br></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br>