[vtkusers] change-over to double

Samson Timoner samson at bwh.harvard.edu
Tue Dec 9 20:05:38 EST 2003


I'm currently in the process of changing many thousands of "float"
declarations to "double" declarations in code based on the cvs version of
vtk.

At this point in time, VTK has been around for long enough and is used by
so many people, that making such drastic changes are horribly annoying to
many people, including myself.

Now, I understand that VTK is still evolving. And, I understand that
drastic changes will still happen from time to time. However, given the
large number of users of VTK, when such large changes do occur, attempts at
backwards compatibility should be given huge importance.

In this case, backwards compatibility could have been achieved using a
typedef. We could have changed from float to VTKPrecision, where
VTKPrecision could be typedef-ed to double by default. This way, I would
know that changing over would need to be done eventually, but that I would
not have to do it immediately.

 Why wasn't a typedef used?

You might recall that a few months ago, a similar thing happened. The API
of vtkVoidArray was changed for no particularly good reason. Again,
backwards compatibility was ignored for no particularly good reason.

It is my request to vtk developers to remember that backwards compatibility
for a library used by many, many people is very important. The more drastic
changes you make, the more old code that is sitting around that is not
working and the most annoyances you cause users like myself.

 Please keep that in mind,

-- Samson



More information about the vtkusers mailing list