Slight improvement to the precision of the GMISC invsqrt() function.

ugfx_release_2.6
inmarket 2013-10-24 15:25:50 +10:00
parent e6f17baf61
commit 0ea2f54637
1 changed files with 1 additions and 1 deletions

View File

@ -167,7 +167,7 @@
#endif
// evil floating point bit level hacking
i = 0x5F3759DF - (i >> 1);
i = 0x5F375A86 - (i >> 1); // The quake code used 0x5F3759DF but this is better.
// Convert back to a float (no binary format conversion)
#if GDISP_INVSQRT_MIXED_ENDIAN