diff options
author | inmarket <andrewh@inmarket.com.au> | 2013-09-24 16:10:15 +1000 |
---|---|---|
committer | inmarket <andrewh@inmarket.com.au> | 2013-09-24 16:10:15 +1000 |
commit | 973e34089e33f06cfd9ed560db968870e22c2b8a (patch) | |
tree | 1acfcb855bf0865f3d3c9aa1208c9caac8678d5b /include/gmisc | |
parent | 40ec5a4e522450458fac6f4c5c9011623b9fa328 (diff) | |
download | uGFX-973e34089e33f06cfd9ed560db968870e22c2b8a.tar.gz uGFX-973e34089e33f06cfd9ed560db968870e22c2b8a.tar.bz2 uGFX-973e34089e33f06cfd9ed560db968870e22c2b8a.zip |
GDISP streaming bug fixes
Win32 bitmap support
Win32 Rotation is back to front. Need to check touch and other drivers.
Diffstat (limited to 'include/gmisc')
-rw-r--r-- | include/gmisc/gmisc.h | 17 | ||||
-rw-r--r-- | include/gmisc/options.h | 12 |
2 files changed, 23 insertions, 6 deletions
diff --git a/include/gmisc/gmisc.h b/include/gmisc/gmisc.h index 5943e642..ff3d0c76 100644 --- a/include/gmisc/gmisc.h +++ b/include/gmisc/gmisc.h @@ -184,6 +184,23 @@ extern "C" { /** @} */ #endif +#if GMISC_NEED_INVSQRT + /** + * @brief Fast inverse square root function (x^-1/2) + * @return The approximate inverse square root + * + * @param[in] n The number to find the inverse square root of + * + * @note This function generates an approximate result. Higher accuracy (at the expense + * of speed) can be obtained by modifying the source code (the necessary line + * is already there - just commented out). + * @note This function relies on the internal machine format of a float and a long. + * If your machine architecture is very unusual this function may not work. + * + * @api + */ + float invsqrt(float n); +#endif #ifdef __cplusplus } #endif diff --git a/include/gmisc/options.h b/include/gmisc/options.h index d5cf5898..73b41800 100644 --- a/include/gmisc/options.h +++ b/include/gmisc/options.h @@ -28,18 +28,18 @@ #define GMISC_NEED_ARRAYOPS FALSE
#endif
/**
- * @brief Include fast array based trig functions (sin, cos)
+ * @brief Include fast fixed point trig functions (sin, cos)
* @details Defaults to FALSE
*/
- #ifndef GMISC_NEED_FASTTRIG
- #define GMISC_NEED_FASTTRIG FALSE
+ #ifndef GMISC_NEED_FIXEDTRIG
+ #define GMISC_NEED_FIXEDTRIG FALSE
#endif
/**
- * @brief Include fast fixed point trig functions (sin, cos)
+ * @brief Include fast inverse square root (x^-1/2)
* @details Defaults to FALSE
*/
- #ifndef GMISC_NEED_FIXEDTRIG
- #define GMISC_NEED_FIXEDTRIG FALSE
+ #ifndef GMISC_NEED_INVSQRT
+ #define GMISC_NEED_INVSQRT FALSE
#endif
/**
* @}
|