[Insight-users] Location of Origin

Luis Ibanez luis.ibanez at kitware.com
Mon Jul 9 12:21:32 EDT 2007


Hi Dan,

The origin is expected to be in the lower left corner of an image and it is
expected to be expressed in physical coordinates (not pixels),
e.g. millimeters or centimeters.

Note that the notion of "left / right" and "upper / lower" is
a *VISUALIZATION* notion.

What appears on your screen up or down, and left or right, depend on
what image viewer you are using..

We will strongly encourage you to use a viewer designed for medical
applications,
not a generic viewer such as the default fax viewer that you get on Windows,
or
the generic display from ImageMagick.


You will find a minimalistic viewer in the InsightApplications/ImageViewer
directory.
You can also download Windows binaries of this application from :

     http://public.kitware.com/pub/itk/InsightApplicationsBin/


In order to make sense of the conversions between indices and physical
coordinates
you must start by printing out the details of your image using

           image->Print( std::cout )

and gathering the information about:


   -          image origin
   -          pixel spacing


Note that some images may indeed have negative spacing,
and/or negative origin values.


Regards,


    Luis


-------------------------------------------------------------------------------------------
On 7/9/07, Dan Homerick <danhomerick at gmail.com> wrote:
>
> A hopefully very quick question -- should the origin be set to the
> physical coordinates of the upper left corner of the image, or the lower
> left corner?
>
> I would assume upper left, but the diagram in the Software Guide seems to
> indicate lower left. If it specifies in the text anywhere, I must be
> overlooking it.
>
> I keep getting negative numbers when I use
> image->TransformPhysicalPointToIndex, and while it's probably a bug
> somewhere upstream in my code, if anyone knows of a common mistake that will
> cause that, please let me know.
>
> Cheers,
>  - Dan
>
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://public.kitware.com/pipermail/insight-users/attachments/20070709/aafc1830/attachment.htm


More information about the Insight-users mailing list