Hi msx,

As I explained before and will try again, computational geometry
algorithms are implemented through a series of layering and folding
sequences. (for more info read topics regarding advanced principles
of software engineering - relating to computational science)

In many of these algorithms a problem known as proliferation occurs,
basically it means the output may require a higher resolution than
the input. Now in gaming you may decide you can round off the output
values (i.e.: rounding off the new x and y's that come out of a rotation
etc...)

The issue there is that you are rounding off the final answer not the
precision of the values in the intermediary steps - this is acceptable
to some degree because you can estimate and measure the potential error.

However If you were to go and replace the word double with some if-def'ed
type such as TMyNumeric or something like that, you would also be replacing
the types of the variables within the routines and not just the types of
the final output. This would lead to various types of inconsistencies
such as errors and different result on different types of processors etc,
depending on what the if-def'ed type is (i.e.: integer, cardinal etc)

For this reason I would not advise doing a "replace-all" of the type
double, but then in the end its up to you so do what you like.


As for quaternions and the transforms related to them, there are a
lot of libraries already dedicated to quaternion arithmetic they do
a much better job than I could ever manage, plus they all seem to
have very large support bases.
You may want to look at JEDI Math or SDL for starters.




Arash Partow

__________________________________________________
Be one who knows what they don't know,
Instead of being one who knows not what they don't know,
Thinking they know everything about all things.
http://www.partow.net