Hello All,
>
Have you figured out FT_Fixed arithmetic? You still use floats in your
> code. I think you should convert to FT_Fixed first.
So, I have been trying to convert my code to FT_Fixed for a few days now without any success.
I did manage to use fixed point for shapes with only line segments, but because of small range
of 16.16 fixed point I have to use 26.6 for intermediate calculations and because of that it
the right and 26.6 fixed point representation on the left.
As for bezier curves, there is almost always an overflow because while solving polynomials some
large numbers are involved. I even tried using Newton's approximation, but it's too slow and still
not as accurate as floating points. I did not try using 64 bit integers because they are not portable
I guess and because of that I have to create separate implementations for 32 and 64 bit architecture.
So, after comparing both, I prefer floats over fixed points because they satisfy both range and precision.
I can try using 64 bit integers but I am not sure whether I will be able to finish the project on time or
not because of separate implementation. I have attached the code below, note that this is my first time
dealing with fixed points so there might be
something that I am not doing right.
see the important changes I have made.
Anuj