It now keeps more resolution and is less prone to overflows (unless of
course the result overflows). The code is aimed at an ARM v7 so might be
slow on platforms that do not support an instruction for:
32-bit signed * 32-bit signed = 64-bit signed
The alternative was to write code like for the division, but that would
be more code and slower on platforms with fast 64-bit multiplication
result.
The output of the titlescreen image now looks less dark as before this
modification.
This code can use several fixed point formats or a double to emulate
floating point code. The code is still work in progress. The intention
is to replace the current fixed point code and use it in more
areas. Hopefully this makes Wesnoth run snappier on devices with slow
floating point hardware, read the Pandora.
By default it uses doubles, so when used in existing code there should
be no differences, between the existing code and the new code.