1Extra Math Functions/Macros 2=========================== 3 4.. code:: 5 6 #include <graphics/math-extra.h> 7 8Helper functions/macros for graphics math. 9 10.. function:: RAD(val) 11 12 Macro that converts a floating point degrees value to radians. 13 14.. function:: DEG(val) 15 16 Macro that converts a floating point radians value to degrees. 17 18**LARGE_EPSILON** 1e-2f 19 20 Large epsilon value. 21 22**EPSILON** 1e-4f 23 24 Epsilon value. 25 26**TINY_EPSILON** 1e-5f 27 28 Tiny Epsilon value. 29 30**M_INFINITE** 3.4e38f 31 32 Infinite value 33 34--------------------- 35 36.. function:: float rand_float(int positive_only) 37 38 Generates a random floating point value (from -1.0f..1.0f, or 39 0.0f..1.0f if *positive_only* is set). 40