[vtkusers] VTK + ITK + DICOM + CT Slices wrong orientation.
John Drescher
drescherjm at gmail.com
Fri Jun 13 14:17:41 EDT 2008
On Sat, Jun 7, 2008 at 11:15 AM, Mathieu Malaterre
<mathieu.malaterre at gmail.com> wrote:
> Hi John,
>
> As far as I know CT Image Storage should be handled correctly in
> ITK, it is using the Image Orientation (Patient) to find out the
> orientation of the image (and thus how to present it). Could you
> either :
> 1. Use some public dataset and send me the link + screenshot of the
> image flipped upside down
> 2. Send me a copy of the image that is appearing upside down for you.
>
> ITK has some limited supported for the new Enhanced CT Image Storage
> class, but last time I checked it was working correctly.
>
I fixed my code by changing the camera orientation.
const double distanceToFocalPoint = 1000;
switch( m_Orientation )
{
case Saggital:
{
idx = 0;
position[0] += distanceToFocalPoint;
m_Camera->SetViewUp ( 0, 0, 1 );
break;
}
case Coronal:
{
idx = 1;
position[1] -= distanceToFocalPoint;
m_Camera->SetViewUp ( 0, 0, 1 );
break;
}
case Axial:
{
idx = 2;
position[2] -= distanceToFocalPoint;
m_Camera->SetViewUp ( 0, -1, 0 );
break;
}
}
I see I am going to have to fully read the books to better understand
why this is needed and different from the LiverTumorSegmentation
example. Two months ago I knew nothing of CMake, Qt, VTK or ITK so
there is quite a bit of reading for me to do. Good thing is that I am
90% through the Qt book.
John
More information about the vtkusers
mailing list