[Insight-developers] Problems with the vnl library

Will Schroeder will.schroeder@kitware.com
Fri, 15 Dec 2000 14:56:47 -0500


Hi Paul-

At 01:41 PM 12/15/00 -0500, you wrote

>I would recommend that the Origin and Spacing of the Image class be
>converted from float to double.  The space penalty is negligible
>compared to the space taken up by the image data, and the time
>penalty is negligible, if not negative, on modern workstations.
>Can anyone see a compelling reason not to convert these to double?


>More generally, I would recommend that we make double rather than
>float the standard within Insight, except where there is a compelling
>reason for float.  Even there, I would make double the default and
>float an option available to the user.  Examples:  Voxel data should
>be either float or double, at the user's option.  Point coordinates
>(e.g. the Point class) should be either double only, or double/float
>at the user's option.  I would argue double only, but there is a case
>to be made for allowing the option.  For things like origin/spacing,
>moments, etc, I can't see any advantage to using anything other than
>double; there's not enough data there that the space savings are worth
>anything.



The PointCoordinates are templated on type TCoordRep (class itkPoint), so 
you can
change the type as desired (see itkMeshTypeDefault). The image spacing and
origin could be changed to double, there's probably no reason for a 
template parameter
for this.

Will