[vtkusers] non-square image "cropped" after rotate 90º

David Gobbi david.gobbi at gmail.com
Wed Sep 16 16:49:58 EDT 2015


On Wed, Sep 16, 2015 at 1:46 PM, Siavash Khallaghi <siavashk at ece.ubc.ca>
wrote:

> Hi Marcos,
>
> Can you compare the extent of the output of vtkImageReslice against its
> input? My gut feeling is that they are not equal.
>

I suggest to use SetResliceAxes() (using transform->GetMatrix()) instead of
SetResliceTransform.  Here is why:

When you use SetResliceAxes(), vtkImageReslice will transform the input
sampling (i.e. the extent and spacing) so that the output extent is rotated
as
compared to the input extent.

Another option is to manually set the output extent, with
reslice->SetOutputExtent().

 - David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20150916/02b3f061/attachment.html>


More information about the vtkusers mailing list